Bug 15289 - WebKit does not respect clip paths of a 0x0 rect
Summary: WebKit does not respect clip paths of a 0x0 rect
Alias: None
Product: WebKit
Classification: Unclassified
Component: SVG (show other bugs)
Version: 523.x (Safari 3)
Hardware: Mac OS X 10.4
: P2 Normal
Assignee: Nobody
Depends on:
Reported: 2007-09-26 14:11 PDT by Eric Seidel (no email)
Modified: 2007-12-05 23:42 PST (History)
0 users

See Also:

simple test case (283 bytes, image/svg+xml)
2007-09-26 14:12 PDT, Eric Seidel (no email)
no flags Details
First attempt (291.78 KB, patch)
2007-12-05 13:17 PST, Rob Buis
mitz: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Seidel (no email) 2007-09-26 14:11:27 PDT
WebKit does not respect clip paths of a 0x0 rect

I'm not certain what the proper behavior here is.  Likely given a 0x0 rect as the clip path the clip should be completely empty (that's what firefox seems to do, and that's what the test I created expects).
Comment 1 Eric Seidel (no email) 2007-09-26 14:12:08 PDT
Created attachment 16402 [details]
simple test case
Comment 2 Rob Buis 2007-12-05 13:17:08 PST
Created attachment 17724 [details]
First attempt

This patch implements the clipping of empty clip paths just like FF and Opera do it. The changed test results are because text clipping does not work yet (I assume), as text probably doesnt do toPathData yet, so the behaviour is the same as just having an empty clip path.

Comment 3 mitz 2007-12-05 13:34:33 PST
Comment on attachment 17724 [details]
First attempt

+        pathData.addRect(FloatRect( 0, 0, 0, 0 ));

I think just FloatRect() should work.

Make sure it also does the right thing for for a 0 x n rect.

Comment 4 Rob Buis 2007-12-05 23:42:00 PST
Landed in r28483.