RESOLVED FIXED 44603
shadowSize parameter is used to pass shadow offset in the GraphicsContext::setShadow and getShadow functions
https://bugs.webkit.org/show_bug.cgi?id=44603
Summary shadowSize parameter is used to pass shadow offset in the GraphicsContext::se...
Alejandro G. Castro
Reported 2010-08-25 05:44:01 PDT
Currently the shadowSize parameter of the setShadow and getShadow functions of GraphicsContext is used to pass the offset of the shadow specified in the style of the elements.
Attachments
Proposed patch (29.41 KB, patch)
2010-08-25 05:46 PDT, Alejandro G. Castro
no flags
Proposed patch (28.06 KB, patch)
2010-08-25 07:59 PDT, Alejandro G. Castro
mitz: review+
Alejandro G. Castro
Comment 1 2010-08-25 05:46:59 PDT
Created attachment 65404 [details] Proposed patch Replace the names in the APIs and the locations where the functions are used.
Alejandro G. Castro
Comment 2 2010-08-25 05:58:51 PDT
After changing the names I've realized that this condition could be wrong but the old name could make it seem correct: + drawIntoBitmap = !offset.isEmpty() || blur; It is in this file: WebCore/platform/graphics/win/FontCGWin.cpp static void drawGDIGlyphs Could someone check if in Windows negative offsets of the text actually work, or no offsets but blurring. We could open a new bug in this case.
Early Warning System Bot
Comment 3 2010-08-25 06:03:00 PDT
Alejandro G. Castro
Comment 4 2010-08-25 07:59:56 PDT
Created attachment 65419 [details] Proposed patch
mitz
Comment 5 2010-08-25 09:30:34 PDT
(In reply to comment #2) > After changing the names I've realized that this condition could be wrong but the old name could make it seem correct: > > + drawIntoBitmap = !offset.isEmpty() || blur; > > It is in this file: WebCore/platform/graphics/win/FontCGWin.cpp static void drawGDIGlyphs > > Could someone check if in Windows negative offsets of the text actually work, or no offsets but blurring. We could open a new bug in this case. I’ve asked someone to check, and indeed in <data:text/html,%3Cdiv%20style=%22-webkit-font-smoothing:%20none%22%3E%3Cdiv%20style=%22text-shadow:%202px%202px%20red%22%3Etest%3C/div%3E%3Cdiv%20style=%22text-shadow:%20-2px%20-2px%20red%22%3Etest%3C/div%3E%3C/div%3E> the bottom line is missing the shadow. Good catch!
Alejandro G. Castro
Comment 6 2010-08-25 10:16:24 PDT
Thanks for the test :). Opened a bug for the other issue: bug 44619. I'll land this patch tomorrow.
Alejandro G. Castro
Comment 7 2010-08-26 00:24:50 PDT
Note You need to log in before you can comment on or make changes to this bug.