On Feb 2, 2008, at 16:13, [EMAIL PROTECTED] wrote:
Author: adelmelle
Date: Sat Feb 2 07:13:40 2008
New Revision: 617812
URL: http://svn.apache.org/viewvc?rev=617812&view=rev
Log:
Further cleanup/refinement of FixedLength:
* improve consistency in use of the PropertyCache
remove public constructor -> replaced by getInstance() in a
handful of classes
* added a sourceResolution parameter to getInstance() and the private
constructor to allow better handling of device-dependent units (px)
Just some details that caught my eye last night, after having looked
into bug 44343.
Concerning the resolution question, I'm not sure whether I succeeded
in reducing the fishy-ness of the convert() method, or even
addressing the actual problem implied in the TODO which I have now
removed/changed.
IIUC, it was only problematic in the sense that it always silently
converted pixel-values to millipoint-values using an assumed ratio of
1. So, it could happen that we modified the source-resolution in the
FOUserAgent, and still internally, we would assume a resolution of
72dpi for the interpretation of pixel-values...
Modifying the signature to allow passing in that ratio seemed like a
fine solution, albeit only partial. All that remains now is to make
sure that this ratio gets correctly passed into
FixedLength.getInstance() where applicable. I'll have a closer look
at that later.
Cheers
Andreas