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

Issue 2388723004: [SPInvalidation] Fix PrePaintTreeWalk for multicol spanner (Closed)

Created:
4 years, 2 months ago by Xianzhu
Modified:
3 years, 11 months ago
CC:
blink-reviews, blink-reviews-paint_chromium.org, chromium-reviews, dshwang
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[SPInvalidation] Fix PrePaintTreeWalk for multicol spanner We should not do anything for the spanner placeholder but just walk the spanner directly. Out-of-flow positioned descendants of a multicol spanner need to be specially handled because their container may be not their ancestor in the order of PrePaintTreeWalk. This fixes the following layout tests for slimmingPaintInvalidation: fast/multicol/dynamic/*spanner*.html fast/multicol/span/*.html (except for fast/multicol/dynamic/abspos-multicol-with-spanner-becomes-spanner.html which is still failing because of some other reason.) BUG=646176 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Committed: https://crrev.com/ea4d26d0200991d105b7ae8b43a7040c5d1e3f5a Cr-Commit-Position: refs/heads/master@{#423713}

Patch Set 1 #

Patch Set 2 : Positioned descendants of spanner; Unit test #

Total comments: 16

Patch Set 3 : fixes #

Total comments: 6

Patch Set 4 : Revert ContainingBlockContext changes #

Unified diffs Side-by-side diffs Delta from patch set Stats (+165 lines, -8 lines) Patch
M third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp View 1 2 3 3 chunks +61 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp View 1 2 3 2 chunks +89 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/paint/PrePaintTreeWalk.cpp View 1 2 2 chunks +13 lines, -6 lines 0 comments Download

Messages

Total messages: 32 (13 generated)
Xianzhu
4 years, 2 months ago (2016-10-04 17:14:35 UTC) #7
Xianzhu
Hold on. Just found that fast/multicol/dynamic/abspos-multicol-with-spanner-becomes-spanner.html failure is also related to tree walk. Will upload ...
4 years, 2 months ago (2016-10-04 17:49:49 UTC) #8
Xianzhu
On 2016/10/04 17:49:49, Xianzhu wrote: > Hold on. Just found that > fast/multicol/dynamic/abspos-multicol-with-spanner-becomes-spanner.html failure > ...
4 years, 2 months ago (2016-10-04 22:04:36 UTC) #11
chrishtr
https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp (right): https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp#newcode669 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp:669: container.objectPaintProperties()->localBorderBoxProperties(); DCHECK(properties && container.isBox()) https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp (right): https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp#newcode2748 ...
4 years, 2 months ago (2016-10-05 00:48:17 UTC) #14
mstensho (USE GERRIT)
https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp (right): https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp#newcode2760 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp:2760: " <div id=normal style='height: 50px'>" Missing </div> ? https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp#newcode2764 ...
4 years, 2 months ago (2016-10-05 08:44:09 UTC) #15
Xianzhu
https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp (right): https://codereview.chromium.org/2388723004/diff/20001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp#newcode669 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.cpp:669: container.objectPaintProperties()->localBorderBoxProperties(); On 2016/10/05 00:48:17, chrishtr wrote: > DCHECK(properties && ...
4 years, 2 months ago (2016-10-05 17:29:41 UTC) #16
mstensho (USE GERRIT)
I agree with the comments in the test now. https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp (right): https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp#newcode2787 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp:2787: ...
4 years, 2 months ago (2016-10-05 18:17:55 UTC) #17
Xianzhu
https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp (right): https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp#newcode2787 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilderTest.cpp:2787: EXPECT_EQ(LayoutPoint(0, 90), On 2016/10/05 18:17:54, mstensho wrote: > Yeah.. ...
4 years, 2 months ago (2016-10-05 19:40:54 UTC) #18
mstensho (USE GERRIT)
OK, back to chrishtr for the magic word, then. :) I don't think I should ...
4 years, 2 months ago (2016-10-06 16:19:42 UTC) #19
chrishtr
https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h (right): https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h#newcode25 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h:25: // State that propagates on the container chain (and ...
4 years, 2 months ago (2016-10-06 16:22:33 UTC) #20
Xianzhu
https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h (right): https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h#newcode25 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h:25: // State that propagates on the container chain (and ...
4 years, 2 months ago (2016-10-06 16:47:48 UTC) #21
chrishtr
https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h (right): https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h#newcode25 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h:25: // State that propagates on the container chain (and ...
4 years, 2 months ago (2016-10-06 16:54:21 UTC) #22
Xianzhu
https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h File third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h (right): https://codereview.chromium.org/2388723004/diff/40001/third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h#newcode25 third_party/WebKit/Source/core/paint/PaintPropertyTreeBuilder.h:25: // State that propagates on the container chain (and ...
4 years, 2 months ago (2016-10-06 17:33:01 UTC) #23
chrishtr
lgtm
4 years, 2 months ago (2016-10-06 20:38:38 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2388723004/60001
4 years, 2 months ago (2016-10-06 20:39:23 UTC) #26
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 2 months ago (2016-10-06 22:36:47 UTC) #28
commit-bot: I haz the power
Patchset 4 (id:??) landed as https://crrev.com/ea4d26d0200991d105b7ae8b43a7040c5d1e3f5a Cr-Commit-Position: refs/heads/master@{#423713}
4 years, 2 months ago (2016-10-06 22:40:37 UTC) #30
pdr.
I was looking at this again to see if we could simplify the multi-column special-cases ...
3 years, 11 months ago (2017-01-04 06:15:04 UTC) #31
Xianzhu
3 years, 11 months ago (2017-01-04 17:12:55 UTC) #32
Message was sent while issue was closed.
On 2017/01/04 06:15:04, pdr. wrote:
> I was looking at this again to see if we could simplify the multi-column
> special-cases in PrePaintTreeWalk and PaintPropertyTreeBuilder. We currently
> modify the paint and hit testing treewalks to special-case colspan:all by
> skipping spanners and later traversing them through a placeholder. The current
> pre-paint tree walk (and associated paint property tree building) has a
similar
> modification. Could we let paint properties get built in layout tree order
> instead? My reasoning is that the paint properties follow the unmodified
layout
> tree order:
> 
> <!doctype html>
> <div id="columns" style="columns: 1; width: 100px;">
> a b c
> <div id="relative" style="position: relative; background: green;
> filter:blur(1px);">
> relative
> <div id="spanner" style="column-span: all">
> <div id="absolute" style="position: absolute; background: blue; top: 5px;
left:
> 0;">abs</div>
> </div>
> </div>
> d e f
> <div>
> 
> *LayoutView 0x268adf604010             	#document
>   LayoutBlockFlow 0x268adf61c010       	HTML
>     LayoutBlockFlow 0x268adf61c138     	BODY
>       LayoutBlockFlow 0x268adf61c260   	DIV id="columns" style="columns: 1;
> width: 100px;"
>         LayoutMultiColumnFlowThread (anonymous) 0x268adf628010
>           LayoutBlockFlow (anonymous) 0x268adf61ca78
>             LayoutText 0x268adf63c1a0  	#text "\na b c\n"
>           LayoutBlockFlow (relative positioned) 0x268adf61c4b0	DIV
id="relative"
> style="position: relative; background: green; filter:blur(1px);"
>             LayoutBlockFlow (anonymous) 0x268adf61c388
>               LayoutText 0x268adf63c268	#text "\nrelative\n"
>             LayoutBlockFlow (column spanner) 0x268adf61c828	DIV id="spanner"
> style="column-span: all"
>               LayoutBlockFlow (positioned) 0x268adf61cba0	DIV id="absolute"
> style="position: absolute; background: blue; top: 5px; left: 0;"
>                 LayoutText 0x268adf63c330	#text "abs"
>           LayoutBlockFlow (anonymous) 0x268adf61c950
>             LayoutText 0x268adf63c010  	#text "\nd e f\n"
>           LayoutBlockFlow 0x268adf61c5d8	DIV
>         LayoutMultiColumnSet (anonymous) 0x268adf64c300
>         LayoutMultiColumnSpannerPlaceholder (anonymous) 0x268adf638010
>         LayoutMultiColumnSet (anonymous) 0x268adf64c010
> 
> In layout tree order: "a b c", "relative", "spanner", "abs", "d e f"
> In paint order (also, current prepaint tree walk order): "a b c", "relative",
"d
> e f", "spanner", "abs"
> 
> The spanner paint offset would need some finessing, but I think we could
adjust
> the paint offset when the spanner is traversed, rather than adjusting the
> traversal order for everything else.

The proposal sounds great.

Powered by Google App Engine
This is Rietveld 408576698