strokeRect() doesn't support gradients in Canvas.
Created attachment 21972 [details] Gradients for strokeRect() Transformed the Rectangle to a path and let stroke() render the content of strokeRect().
(In reply to comment #1) > Created an attachment (id=21972) [edit] > Gradients for strokeRect() > > Transformed the Rectangle to a path and let stroke() render the content of > strokeRect(). > I'm unsure about lineWidth. If we let stroke() render rectangles, do we still need strokeRect(float, float, float, float, float) (5 floats)? I believe it was used to let the rect render by GraphicsContext and isn't usefull anymore with the changes above. Otherwise we need to call setLineWidth().
Created attachment 21984 [details] strokeRect() with gradients I spoke with olliej and we were agreed to clean up canvas first before fixing strokeRect() and look if the code could be reused later.
*** Bug 18463 has been marked as a duplicate of this bug. ***
This still fails for CG in the latest nightly: r35993.dmg">http://builds.nightly.webkit.org/files/trunk/mac/WebKit-SVN-r35993.dmg
Created attachment 25786 [details] strokeRect support for Cg This should add patter and gradient-strokes for strokeRect(). I'll run layouttest and set the review-flag afterwards.
Created attachment 25812 [details] strokeRect support for Cg Added a LayoutTest.
landed in r39080.