Issue metadata
Sign in to add a comment
|
CSS Paint API: shadowBlur doesn't scale with page zoom |
||||||||||||||||||||||
Issue descriptioneg. http://jsbin.com/hilocahawu/edit?html,js,output When the page is zoomed the shadow remains the same physical size.
,
Dec 7 2016
> What needs to be enabled to verify this? "Experimental web platform features", not shipped yet. > Is this a Paint team bug or a CSS custom paint bug? I think both. > In particular, does a shadow on a basic declarative page scale properly? Yes, I think so. For example a CSS box-shadow will scale.
,
Dec 8 2016
,
Sep 12 2017
Hi xidachen@, ccing you as an FYI
,
Sep 25 2017
,
Jan 11 2018
,
Jan 11 2018
How hard is it to fix this bug?
,
Jan 12 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/037f13946d29591fe1c1f6eeae6187645674aad0 commit 037f13946d29591fe1c1f6eeae6187645674aad0 Author: Xida Chen <xidachen@chromium.org> Date: Fri Jan 12 17:07:05 2018 [PaintWorklet] Fix shadow blur size when page zooms When the page zooms, for example, to 200%, the size of the shadow blur remains the same as when the page scale is 100%. The problem here is that whenever we zoom the page, we queue a paint call back. Then the new paint call back will set the shadow blur with the size that doesn't account for the page zoom. The fix is to override the BaseRenderingContext2d::setShadowBlur() method with the zoom. Note that when we created the PaintRenderingContext2d object, the |zoom| parameter includes the page zoom and device scale factor. This CL also includes a layout test to verify the correctness of the fix. TBR=junov@chromium.org Bug: 671849 Change-Id: I8b00dbf4f79e2430c424c762dbf008ac27706f54 Reviewed-on: https://chromium-review.googlesource.com/862525 Commit-Queue: Xida Chen <xidachen@chromium.org> Reviewed-by: Tien-Ren Chen <trchen@chromium.org> Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org> Cr-Commit-Position: refs/heads/master@{#528974} [add] https://crrev.com/037f13946d29591fe1c1f6eeae6187645674aad0/third_party/WebKit/LayoutTests/http/tests/csspaint/shadow-blur-scale-with-page-zoom-expected.html [add] https://crrev.com/037f13946d29591fe1c1f6eeae6187645674aad0/third_party/WebKit/LayoutTests/http/tests/csspaint/shadow-blur-scale-with-page-zoom.html [modify] https://crrev.com/037f13946d29591fe1c1f6eeae6187645674aad0/third_party/WebKit/Source/modules/canvas/canvas2d/BaseRenderingContext2D.h [modify] https://crrev.com/037f13946d29591fe1c1f6eeae6187645674aad0/third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.cpp [modify] https://crrev.com/037f13946d29591fe1c1f6eeae6187645674aad0/third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.h
,
Jan 12 2018
|
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by schenney@chromium.org
, Dec 7 2016NextAction: 2016-12-21