Content are drawn onto the bottom border of a container across columns with "box-decoration-break: clone"
Categories
(Core :: Layout: Block and Inline, defect, P3)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox99 | --- | fixed |
People
(Reporter: TYLin, Assigned: TYLin)
Details
Attachments
(1 file, 2 external files)
|
625 bytes,
text/html
|
Details |
See the attached columns-box-decoration-break.html. The container having box-decoration-break:clone are fragmented into two columns, and its child block shouldn't being drawn onto the container's bottom border in the first column.
I think the code that leads to this result is in [1] or somewhere in nsBlockFrame::ComputeFinalBSize().
Updated•6 years ago
|
| Assignee | ||
Comment 1•4 years ago
|
||
| Assignee | ||
Comment 2•4 years ago
|
||
If a block container has box-decoration-break:clone, its block-end border and
padding (BP) are usually drawn at the block-end edge in the current
column/page. Thus, when computing the available block-size for its children, we
should subtract its block-end border BP from it.
BlockReflowInput::ContentBSize() is the correct content-box block-size the
block container precomputed in BlockReflowInput's constructor. See
https://searchfox.org/mozilla-central/rev/c12a59323ee46b29b90c9917a3a7a70ea714ffec/layout/generic/BlockReflowInput.cpp#118-126
The remove hunk was a hack, working only for ColumnSetWrapper with
box-decoration-break:clone. It's no longer needed.
When I claim the block-end BP are usually drawn at the block-end edge, the
exception is that the block container with a definite block-size runs out of its
block-size in a column/page. In this case, the block-end BP is drawn at the
block-end edge of its content-box. The sub-tests having
box-decoration-break:clone border in box-decoration-break-bug-1249913.html
is such examples. It may seem strange that the overflowing lime boxes cannot
extend to the block-end edge of the first column, but this is expected as of
this patch because we subtract the block-end BP from the available block-size.
Depends on D138366
Updated•4 years ago
|
Updated•4 years ago
|
Comment 5•4 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/51cb3ac09506
https://hg.mozilla.org/mozilla-central/rev/aeaea91a4f58
Description
•