Closed
Bug 416762
Opened 16 years ago
Closed 16 years ago
OBJECTBOUNDINGBOX units should include a translation by the boundingbox origin
Categories
(Core :: SVG, defect)
Core
SVG
Tracking
()
RESOLVED
FIXED
People
(Reporter: roc, Assigned: roc)
Details
Attachments
(1 file, 1 obsolete file)
354 bytes,
image/svg+xml
|
Details |
In two places we use nsSVGUtils::ObjectSpace to interpret x/y/width/height coordinates according to objectBoundingBox units, without using the bounding-box origin as a translation: Patterns: http://mxr.mozilla.org/seamonkey/source/layout/svg/base/src/nsSVGPatternFrame.cpp#643 Filter primitive subregions: http://mxr.mozilla.org/seamonkey/source/layout/svg/base/src/nsSVGFilterFrame.cpp#451 These are both bugs, right? The spec says http://www.w3.org/TR/SVG/coords.html#ObjectBoundingBox > Then, coordinate (0,0) in the new user coordinate system is mapped to the > (minx,miny) corner of the tight bounding box within the user coordinate system > of the applicable element which is of course what authors would expect too.
Assignee | ||
Comment 1•16 years ago
|
||
This testcase shows the problem. It doesn't display anything on trunk. It should display a green rectangle. I've fixed this for filter subregions in my patch for bug 414784. Still probably need a fix for patterns, although I don't have a testcase for that.
Comment 2•16 years ago
|
||
Didn't I do patterns in bug 338596, although that patch wasn't quite right and I had to fix it in bug 261693?
Comment 3•16 years ago
|
||
s/261693/377263/
Assignee | ||
Comment 4•16 years ago
|
||
OK cool. Would you mind manufacturing a reftest for that and checking it in? Then I'll close this bug :-).
Comment 5•16 years ago
|
||
Comment 6•16 years ago
|
||
Checked in pattern reftests: http://lxr.mozilla.org/seamonkey/source/layout/reftests/svg/objectBoundingBox-and-pattern-01a.svg http://lxr.mozilla.org/seamonkey/source/layout/reftests/svg/objectBoundingBox-and-pattern-01b.svg http://lxr.mozilla.org/seamonkey/source/layout/reftests/svg/objectBoundingBox-and-pattern-01c.svg
Comment 7•16 years ago
|
||
FWIW the pattern translation code is here http://mxr.mozilla.org/seamonkey/source/layout/svg/base/src/nsSVGPatternFrame.cpp#735
Assignee | ||
Comment 8•16 years ago
|
||
Cool, I'll close this down now. The filter stuff will be fixed in bug 414784.
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Assignee | ||
Updated•16 years ago
|
Flags: in-testsuite+
Updated•16 years ago
|
Attachment #302544 -
Attachment is obsolete: true
You need to log in
before you can comment on or make changes to this bug.
Description
•