Bug 15645

Summary: WebKit fails to render <use> example in SVG 1.1 spec
Product: WebKit Reporter: Eric Seidel (no email) <eric>
Component: SVGAssignee: Nikolas Zimmermann <zimmermann>
Status: RESOLVED FIXED    
Severity: Normal CC: zimmermann
Priority: P2 Keywords: NeedsReduction
Version: 523.x (Safari 3)   
Hardware: Mac   
OS: OS X 10.4   
URL: http://www.w3.org/TR/SVG/images/struct/Use04.svg
Attachments:
Description Flags
Initial patch hyatt: review+

Eric Seidel (no email)
Reported 2007-10-23 16:53:21 PDT
WebKit fails to render <use> example in SVG 1.1 spec http://www.w3.org/TR/SVG/images/struct/Use04.svg is the file http://www.w3.org/TR/SVG/struct.html#UseElement explains the file I haven't looked at why we fail yet.
Attachments
Initial patch (2.45 KB, patch)
2007-12-02 17:00 PST, Nikolas Zimmermann
hyatt: review+
Nikolas Zimmermann
Comment 1 2007-11-25 05:09:43 PST
Removing rule 8, makes it work as expected: /* rule 8 */ g > path { visibility: hidden } Investigating soon.
Nikolas Zimmermann
Comment 2 2007-11-25 05:15:57 PST
Ok, found the culprit: <path> is referenced by the <use> element. In our generated tree the <path> will be a direct child element of <g> (which replaces the <use> in the generated tree). Though the spec cleary states: Rules 7 and 8: CSS selectors only apply to the formal document tree, not on the generated tree; thus, these selectors will not yield a match. We need to support this. (while reminding ourselves that class & id selectors etc. still need to work within the generated subtree)
Nikolas Zimmermann
Comment 3 2007-12-02 17:00:31 PST
Created attachment 17657 [details] Initial patch
Eric Seidel (no email)
Comment 4 2007-12-02 21:48:48 PST
Comment on attachment 17657 [details] Initial patch This needs to include landing the test case. I think this is otherwise right, but hyatt really should have a look.
Dave Hyatt
Comment 5 2007-12-02 21:50:04 PST
Comment on attachment 17657 [details] Initial patch r=me
Nikolas Zimmermann
Comment 6 2007-12-03 10:58:54 PST
Landed in r28357.
Note You need to log in before you can comment on or make changes to this bug.