Bug 21888

Summary: REGRESSION: [Canvas] Transparent fillStyle stops line rendering
Product: WebKit Reporter: Marcus Cobden <bugs>
Component: DOMAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal Keywords: Regression
Priority: P1    
Version: 528+ (Nightly build)   
Hardware: Mac (Intel)   
OS: OS X 10.5   
URL: http://www.marcuscobden.co.uk/stuff/2008-10/webkit-canvas-fillstyle/
Attachments:
Description Flags
fixed strokePath()
eric: review-
strokPath() fix with LayoutTest darin: review+

Marcus Cobden
Reported 2008-10-25 15:05:00 PDT
If the fillStyle of the 2d context is set to a fully transparent colour, lines will not render, if it is set to anything else, the line renders correctly. Lines should (iirc) be affected by strokeStyle rather than fillStyle. This is a regression, as the testcase works in Safari 3.1. See the provided link for a testcase. (Also, apologies if I've selected the wrong component.)
Attachments
fixed strokePath() (1.25 KB, patch)
2008-10-25 23:55 PDT, Dirk Schulze
eric: review-
strokPath() fix with LayoutTest (4.10 KB, patch)
2008-10-29 03:15 PDT, Dirk Schulze
darin: review+
Alexey Proskuryakov
Comment 1 2008-10-25 15:08:06 PDT
Confirmed with r37887.
Dirk Schulze
Comment 2 2008-10-25 23:55:50 PDT
Created attachment 24680 [details] fixed strokePath() fixed strokePath() in GraphicsContextCg.
Darin Adler
Comment 3 2008-10-27 14:23:50 PDT
Comment on attachment 24680 [details] fixed strokePath() Great fix, but we also need a regression test!
Eric Seidel (no email)
Comment 4 2008-10-28 23:07:44 PDT
Comment on attachment 24680 [details] fixed strokePath() LGTM.
Eric Seidel (no email)
Comment 5 2008-10-28 23:12:24 PDT
Comment on attachment 24680 [details] fixed strokePath() Ah true... we do need a regression test. You can make one with getImageData so it doesn't need pixel tests.
Dirk Schulze
Comment 6 2008-10-29 03:15:31 PDT
Created attachment 24742 [details] strokPath() fix with LayoutTest added a LayoutTest to the patch.
Darin Adler
Comment 7 2008-10-29 09:12:25 PDT
Comment on attachment 24742 [details] strokPath() fix with LayoutTest Excellent! r=me
Dirk Schulze
Comment 8 2008-11-12 23:20:01 PST
landed in r38364.
Note You need to log in before you can comment on or make changes to this bug.