[LayoutNG] Support for forced fragmentainer breaks.
This is about implementing the "forced break" values for the CSS properties break-after and break-before. The legacy page-break-before:always and page-break-after:always declarations also work, if in paged media. For multicol, on the other hand, it's more about supporting break-before:column and break-after:column. Forced fragmentainer breaks may only occur at class A break points [1]. If there's a forced break-before value on a first in-flow child, or a break-after value on a last in-flow child, the values are to be propagated through the containing block chain, until we find a suitable place to break. [2] If we don't find a suitable break point, no break will be inserted. Initial and final break values inside a block are propagated upwards via NGLayoutResult. A few more layout tests pass. A few regress, too, among other things because we don't handle borders at column boundaries too well yet, and that we don't disable fragmentation inside scrollable containers. Some of the code in this CL is taken from LayoutBox in the legacy engine. [1] https://www.w3.org/TR/css-break-3/#possible-breaks [2] https://www.w3.org/TR/css-break-3/#break-between Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng Change-Id: Id67f2ed2d008a6d98a7c7a43d98c345964035e7b Reviewed-on: https://chromium-review.googlesource.com/835110 Commit-Queue: Morten Stenshorne <mstensho@chromium.org> Reviewed-by:Ian Kilpatrick <ikilpatrick@chromium.org> Cr-Commit-Position: refs/heads/master@{#525325}
Showing
Please register or sign in to comment