Skip to content

Commit 931e5b7

Browse files
mstenshochromium-wpt-export-bot
authored andcommitted
[LayoutNG] Only apply block-end margins where the block actually ends.
If we reached the end of a block in an earlier fragmentainer, but there's overflowing content, we'll revisit this block in subsequent fragmentainers as long as child content needs it. Repeating the block-end margins in these fragmentainers would be wrong, though. Use AdjustForFragmentation() only for margins, and rename it to AdjustMarginsForFragmentation(). The fieldset layout algorithm was using this one for borders/padding, while block and multicol layout called AdjustBorderScrollbarPaddingForFragmentation() in container_builder_. Become more uniform by calling that method for all in SetupFragmentBuilderForFragmentation() (via the base layout algorithm constructor). Since this depends on the initial fragment geometry being set, also do that in the base layout algorithm constructor. Bug: 829028 Change-Id: I6808d023e4e79ab489bdb3a48e3c6c47cf9db6c6 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2287313 Reviewed-by: Alison Maher <[email protected]> Reviewed-by: Ian Kilpatrick <[email protected]> Commit-Queue: Ian Kilpatrick <[email protected]> Cr-Commit-Position: refs/heads/master@{#786791}
1 parent 8d71043 commit 931e5b7

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<!DOCTYPE html>
2+
<link rel="author" title="Morten Stenshorne" href="mailto:[email protected]">
3+
<link rel="help" href="https://www.w3.org/TR/css-break-3/#parallel-flows">
4+
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
5+
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
6+
<div style="columns:2; column-fill:auto; column-gap:0; width:100px; height:100px; background:red;">
7+
<div style="margin-bottom:20px; height:50px;">
8+
<div style="height:70px; background:green;"></div>
9+
<div style="height:90px;"></div>
10+
<div style="height:40px; background:green;"></div>
11+
</div>
12+
<div style="height:50px; background:green;"></div>
13+
<div style="height:40px; background:green;"></div>
14+
</div>

0 commit comments

Comments
 (0)