DO NOT REPLY [Bug 47993] New: <path> elements with empty path data (i.e. d="") are *not* ignored for bounds calculations

View: New views
2 Messages — Rating Filter:   Alert me  

DO NOT REPLY [Bug 47993] New: <path> elements with empty path data (i.e. d="") are *not* ignored for bounds calculations

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

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

           Summary: <path> elements with empty path data (i.e. d="") are
                    *not* ignored for bounds calculations
           Product: Batik
           Version: 1.8
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Bridge
        AssignedTo: batik-dev@...
        ReportedBy: thomas.behr@...


Created an attachment (id=24376)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=24376)
test case

Up to and including BATIK v 1.6,
org.apache.batik.bridge.SVGPathElementBridge.buildShape ignored path elements
with empty d attributes (see revision 385978 in the SVG trunk branch for
SVGPathElementBridge.java).
Since BATIK v 1.7 this is no longer the case (see revision 426986 and later)
which results in bad bounds for org.apache.batik.gvt.GraphicsNode instances
corresponding to SVG documents that use <path d="" .../> but would not normally
include the origin of the coordinate system in their bounds.

To illustrate this issue, see the attached test case
Run against BATIK 1.6, this prints
  rectWithoutEmptyPath.bounds = [x=100.0;y=100.0;w=100.0;h=100.0]
     rectWithEmptyPath.bounds = [x=100.0;y=100.0;w=100.0;h=100.0]
but
  rectWithoutEmptyPath.bounds = [x=100.0;y=100.0;w=100.0;h=100.0]
     rectWithEmptyPath.bounds = [x=0.0;y=0.0;w=200.0;h=200.0]
when run against BATIK 1.7 or later.

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

---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@...
For additional commands, e-mail: batik-dev-help@...


DO NOT REPLY [Bug 47993] <path> elements with empty path data (i.e. d="") are *not* ignored for bounds calculations

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

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

Helder Magalhães <helder.magalhaes@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |regression

--- Comment #1 from Helder Magalhães <helder.magalhaes@...> 2009-10-15 02:37:40 UTC ---
Yes, the SVG 1.1 and Tiny 1.2 specifications seem to point towards the original
behavior:

"Note that the BNF allows the path 'd' attribute to be empty. This is not an
error, instead it disables rendering of the path." [1] [2]

I've confirmed the apparently unexpected behavior with SVN revision 820114
(latest as of this writing):

rectWithoutEmptyPath.bounds = [x=100.0;y=100.0;w=100.0;h=100.0]
   rectWithEmptyPath.bounds = [x=0.0;y=0.0;w=200.0;h=200.0]

According to the information provided, I'm marking this as a regression.

[1] http://www.w3.org/TR/SVG11/paths.html#PathDataBNF
[2] http://www.w3.org/TR/SVGTiny12/paths.html#PathDataBNF

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@...
For additional commands, e-mail: batik-dev-help@...