You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by bu...@apache.org on 2009/04/14 12:06:41 UTC

DO NOT REPLY [Bug 47027] New: [PATCH] Proposed correction for resolution handling

https://issues.apache.org/bugzilla/show_bug.cgi?id=47027

           Summary: [PATCH] Proposed correction for resolution handling
           Product: Fop
           Version: 1.0dev
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: PatchAvailable
          Severity: regression
          Priority: P2
         Component: fo tree
        AssignedTo: fop-dev@xmlgraphics.apache.org
        ReportedBy: jeremias@apache.org


Created an attachment (id=23489)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=23489)
my proposed patch

Hi Andreas,

in your revision http://svn.apache.org/viewvc?rev=764317&view=rev you intended
to fix the conversion from pixels to internal millipoints. I'm afraid you seem
to have misunderstood the intention of the source and target resolution. When I
introduced the two resolutions the intention was that the source resolution
specifies the resolution at which pixel lengths are interpreted on the source
side (pixel lengths in FO, pixel lengths for bitmaps that don't have resolution
information etc.). The target resolution OTOH specifies the resolution at which
the output device operates. For example, if you target a 300 dpi printer, you
specify 300 dpis. For the screen you'd specify 96 dpi (most probably). This
value controls the number of pixels generated for a bitmap that is generated
from a vector graphic image that is rendered to a pixel-based output format
(like PCL or PNG).

FO     src res    layout engine.    tgt res     Output
<px>   ------->       <mpt>         ------->    <px>

The attached patch demonstrates how I would fix this. An example of the result:
Specify a table column with 72px and you get 72000mpt as before at default
settings (72dpi). At a higher resolution, the pixels get smaller as you have
more pixels per inch. So at 144dpi, you have twice as many pixels in the same
space per dimension. The pixel length is half the previous length. 72px are now
36000mpt.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

DO NOT REPLY [Bug 47027] [PATCH] Proposed correction for resolution handling

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47027





--- Comment #1 from Andreas L. Delmelle <ad...@apache.org>  2009-04-15 11:18:44 PST ---
OK, indeed seems I misunderstood the intentions.

Patch looks fine to me (as far as I understand... my using the 'magic number'
72.0f should definitely be abandoned)

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

DO NOT REPLY [Bug 47027] [PATCH] Proposed correction for resolution handling

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47027


Andreas L. Delmelle <ad...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #23489|0                           |1
        is obsolete|                            |




--- Comment #2 from Andreas L. Delmelle <ad...@apache.org>  2009-04-17 09:27:47 PST ---
Created an attachment (id=23506)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=23506)
same patch, but including another change in FOTreeTester

Just wanted to go ahead and commit the changes, then noticed I had made an
additional change to FOTreeTester and ResultCollector a while back, which I'd
like to post for review first.

The one difference is that I made the distinction between a fatal error that
arises during parsing, and a failed assertion in a test that was successfully
parsed. If this makes sense, I'll commit the attached patch later this weekend
(or early next week).

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

DO NOT REPLY [Bug 47027] [PATCH] Proposed correction for resolution handling

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47027


Andreas L. Delmelle <ad...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #23506|0                           |1
        is obsolete|                            |




--- Comment #3 from Andreas L. Delmelle <ad...@apache.org>  2009-04-17 09:34:04 PST ---
Created an attachment (id=23507)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=23507)
correction: added missing file

Forgot to include the affected AssertElement.java in the previous attachment

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

DO NOT REPLY [Bug 47027] [PATCH] Proposed correction for resolution handling

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47027


Andreas L. Delmelle <ad...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED




--- Comment #4 from Andreas L. Delmelle <ad...@apache.org>  2009-04-19 10:55:15 PST ---

No feedback in the meantime, so I've committed the changes: see r766492 ( https://svn.apache.org/viewcvs.cgi?view=rev&rev=766492 )
Thanks for the feedback!

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

DO NOT REPLY [Bug 47027] [PATCH] Proposed correction for resolution handling

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=47027

Glenn Adams <gl...@skynav.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |CLOSED

--- Comment #5 from Glenn Adams <gl...@skynav.com> 2012-04-01 06:32:17 UTC ---
batch transition pre-FOP1.0 resolved+fixed bugs to closed+fixed

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.