diff options
author | bptato <nincsnevem662@gmail.com> | 2024-05-19 15:36:18 +0200 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2024-05-19 15:48:24 +0200 |
commit | 6078b9ca896007357b699f13aee7843f0c862b4a (patch) | |
tree | 9219970da142246ba4d8be2a6f721cfe1718a73e /test/layout/float-minimum-height.html | |
parent | 47d08bff7e4f82fb622e30eee770c74904dac93c (diff) | |
download | chawan-6078b9ca896007357b699f13aee7843f0c862b4a.tar.gz |
layout: fix BFC positioning in presence of floats
Previously, the following printed "2" instead of "12": <div style=float:left>1</div><div style=display:flow-root>2</div> This fixes the above problem in the laziest possible way: we relayout once in the smallest possible space the BFC fits in when floats exist. See the comment in the code for details. As a nice bonus, this also fixes tables overlapping with floated boxes, by pretending that they establish a BFC.
Diffstat (limited to 'test/layout/float-minimum-height.html')
-rw-r--r-- | test/layout/float-minimum-height.html | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/test/layout/float-minimum-height.html b/test/layout/float-minimum-height.html new file mode 100644 index 00000000..b466890c --- /dev/null +++ b/test/layout/float-minimum-height.html @@ -0,0 +1,15 @@ +<br> +<br> +<br> +<br> +<br> +<div style="display: flow-root"> +<div style="float: right"> +line 1<br> +line 2<br> +line 3<br> +line 4<br> +line 5<br> +</div> +</div> +testing testing testing testing testing |