Summary: | <clipPath> with <use> not respected | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Eric Seidel (no email) <eric> | ||||||
Component: | SVG | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | drj | ||||||
Priority: | P2 | Keywords: | HasReduction | ||||||
Version: | 523.x (Safari 3) | ||||||||
Hardware: | Mac | ||||||||
OS: | OS X 10.4 | ||||||||
URL: | http://www.carto.net/neumann/cartography/papermaps/japan.svgz | ||||||||
Attachments: |
|
Description
Eric Seidel (no email)
2007-10-14 16:06:32 PDT
These have the same issue: http://www.carto.net/neumann/cartography/papermaps/korea.svgz http://www.carto.net/neumann/cartography/papermaps/china.svgz Turn out this is a problem with our <clipPath> and <use> support. Created attachment 16675 [details]
test case
Created attachment 18107 [details]
First attempt
I fixed the bug but also tried to look at the functionality of using <use> from a clip path a bit more, particularly the part that describes indirect references are disallowed. The second testcase tests this, Opera and Firefox do allow that clip path, so either I am misunderstanding the spec or they are wrong.
Cheers,
Rob.
You are the most wonderful bug sniper ever! All these old little bugs slowly getting picked off by Rob... one at a time... :) I'll actually review your patch after all the xmas celebration (assuming no one else beats me to it). Comment on attachment 18107 [details]
First attempt
A few comments.
1. You might mention the section of the spec, or even the text, indicating the direct reference requirement:
14.3.5 Establishing a new clipping path
A 'clipPath' element can contain 'path' elements, 'text' elements, basic shapes (such as 'circle') or a 'use' element. If a 'use' element is a child of a 'clipPath' element, it must directly reference 'path', 'text' or basic shape elements.
Single line ifs (including those with comments) do no use { } according to the webkit style guidelines.
Otherwise looks great. I assume that both test cases show 100x100 green rects on TOT?
r=me, assuming you fix the spec comment and style issue.
|