Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(93)

Issue 1321613002: Refactor ObjectPainter::paintOutline to take a paintOffset (Closed)

Created:
5 years, 3 months ago by pdr.
Modified:
5 years, 3 months ago
Reviewers:
chrishtr, Xianzhu, fs, trchen
CC:
blink-reviews, blink-reviews-paint_chromium.org, dshwang, slimming-paint-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Refactor ObjectPainter::paintOutline to take a paintOffset This patch refactors ObjectPainter::paintOutline to take a visual overflow rect and layout size (w/o paint offset), plus a paint offset. This cleans up the callsites so each doesn't need to compute a moved visual overflow rect, and prepares the paint code for paint offset caching. This has been split off from https://codereview.chromium.org/1315993004. A TODO has been added above outlineRectForSVG because the function should not exist. paintInvalidationRectInLocalCoordinates should be fixed to contain the outline extent. BUG=508383 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=201326

Patch Set 1 #

Total comments: 5

Patch Set 2 : Remove ObjectPainter::outlineRectForSVG #

Unified diffs Side-by-side diffs Delta from patch set Stats (+41 lines, -58 lines) Patch
M Source/core/layout/svg/LayoutSVGModelObject.h View 1 1 chunk +4 lines, -0 lines 0 comments Download
M Source/core/layout/svg/LayoutSVGModelObject.cpp View 1 1 chunk +8 lines, -0 lines 0 comments Download
M Source/core/paint/BlockPainter.cpp View 3 chunks +4 lines, -11 lines 0 comments Download
M Source/core/paint/ObjectPainter.h View 1 2 chunks +2 lines, -3 lines 0 comments Download
M Source/core/paint/ObjectPainter.cpp View 1 4 chunks +6 lines, -10 lines 0 comments Download
M Source/core/paint/PartPainter.cpp View 1 chunk +1 line, -4 lines 0 comments Download
M Source/core/paint/ReplacedPainter.cpp View 4 chunks +4 lines, -9 lines 0 comments Download
M Source/core/paint/SVGContainerPainter.cpp View 1 1 chunk +3 lines, -2 lines 0 comments Download
M Source/core/paint/SVGImagePainter.cpp View 1 1 chunk +1 line, -2 lines 0 comments Download
M Source/core/paint/SVGShapePainter.cpp View 1 1 chunk +2 lines, -3 lines 0 comments Download
M Source/core/paint/TablePainter.cpp View 1 chunk +2 lines, -5 lines 0 comments Download
M Source/core/paint/TableRowPainter.cpp View 1 chunk +2 lines, -4 lines 0 comments Download
M Source/core/paint/TableSectionPainter.cpp View 1 chunk +2 lines, -5 lines 0 comments Download

Messages

Total messages: 16 (4 generated)
pdr.
5 years, 3 months ago (2015-08-27 03:40:46 UTC) #3
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1321613002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1321613002/1
5 years, 3 months ago (2015-08-27 03:40:48 UTC) #4
chrishtr
https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/BlockPainter.cpp File Source/core/paint/BlockPainter.cpp (left): https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/BlockPainter.cpp#oldcode167 Source/core/paint/BlockPainter.cpp:167: if (!RuntimeEnabledFeatures::slimmingPaintEnabled()) This flag conditional is not needed any ...
5 years, 3 months ago (2015-08-27 04:20:41 UTC) #5
pdr.
https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/BlockPainter.cpp File Source/core/paint/BlockPainter.cpp (left): https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/BlockPainter.cpp#oldcode167 Source/core/paint/BlockPainter.cpp:167: if (!RuntimeEnabledFeatures::slimmingPaintEnabled()) On 2015/08/27 at 04:20:41, chrishtr wrote: > ...
5 years, 3 months ago (2015-08-27 05:00:17 UTC) #7
fs
lgtm https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/ObjectPainter.cpp File Source/core/paint/ObjectPainter.cpp (right): https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/ObjectPainter.cpp#newcode20 Source/core/paint/ObjectPainter.cpp:20: LayoutRect ObjectPainter::outlineRectForSVG(const LayoutSize& size, const ComputedStyle& style) On ...
5 years, 3 months ago (2015-08-27 10:23:17 UTC) #8
Xianzhu
lgtm. This remembers me about my *low-priority* CLs: https://codereview.chromium.org/1278543002/ and https://codereview.chromium.org/1224933002/. Will appreciate if you ...
5 years, 3 months ago (2015-08-27 15:59:39 UTC) #9
pdr.
On 2015/08/27 at 10:23:17, fs wrote: > lgtm > > https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/ObjectPainter.cpp > File Source/core/paint/ObjectPainter.cpp (right): ...
5 years, 3 months ago (2015-08-27 17:42:36 UTC) #10
pdr.
On 2015/08/27 at 15:59:39, wangxianzhu wrote: > lgtm. > > This remembers me about my ...
5 years, 3 months ago (2015-08-27 17:44:10 UTC) #11
chrishtr
On 2015/08/27 at 17:42:36, pdr wrote: > On 2015/08/27 at 10:23:17, fs wrote: > > ...
5 years, 3 months ago (2015-08-27 17:44:18 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1321613002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1321613002/20001
5 years, 3 months ago (2015-08-27 17:44:32 UTC) #14
commit-bot: I haz the power
Committed patchset #2 (id:20001) as https://src.chromium.org/viewvc/blink?view=rev&revision=201326
5 years, 3 months ago (2015-08-27 19:12:23 UTC) #15
pdr.
5 years, 3 months ago (2015-08-27 23:37:05 UTC) #16
Message was sent while issue was closed.
On 2015/08/27 at 10:23:17, fs wrote:
> lgtm
> 
>
https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/ObjectPai...
> File Source/core/paint/ObjectPainter.cpp (right):
> 
>
https://codereview.chromium.org/1321613002/diff/1/Source/core/paint/ObjectPai...
> Source/core/paint/ObjectPainter.cpp:20: LayoutRect
ObjectPainter::outlineRectForSVG(const LayoutSize& size, const ComputedStyle&
style)
> On 2015/08/27 05:00:17, pdr wrote:
> > On 2015/08/27 at 04:20:41, chrishtr wrote:
> > > This seems like an odd method to have, even temporarily. Why not just
define
> > it on the root SVG object class or something?
> > > Also I don't think it should be in
paintInvalidationRectInLocalCoordinates. Or
> > that method's name should be changed to generalize.
> > 
> > SVG's paint invalidation rect concept needs a big overhaul but I'd like to
save
> > that for a followup.
> 
> I can look into this if you like. I assume we want to move in the direction of
visualOverflowRect.

I now see that Xianzhu's https://codereview.chromium.org/1224933002 actually
cleans this up nicely by moving the outset code to addOutlineRects.

I've filed crbug.com/525833 to investigate cleaning up
paintInvalidationRectInLocalCoordinates. I'm not sure how far we should go in
this area.. some bikeshedding may be all that's needed.

Powered by Google App Engine
This is Rietveld 408576698