diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 09:22:09 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 09:22:09 +0000 |
commit | 43a97878ce14b72f0981164f87f2e35e14151312 (patch) | |
tree | 620249daf56c0258faa40cbdcf9cfba06de2a846 /testing/web-platform/tests/css/css-multicol/multicol-count-computed-003.xht | |
parent | Initial commit. (diff) | |
download | firefox-upstream.tar.xz firefox-upstream.zip |
Adding upstream version 110.0.1.upstream/110.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testing/web-platform/tests/css/css-multicol/multicol-count-computed-003.xht')
-rw-r--r-- | testing/web-platform/tests/css/css-multicol/multicol-count-computed-003.xht | 86 |
1 files changed, 86 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/css-multicol/multicol-count-computed-003.xht b/testing/web-platform/tests/css/css-multicol/multicol-count-computed-003.xht new file mode 100644 index 0000000000..96a1e477d9 --- /dev/null +++ b/testing/web-platform/tests/css/css-multicol/multicol-count-computed-003.xht @@ -0,0 +1,86 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Multi-column Layout Test: column-rule and overflow inside (complex test)</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" /> + <link rel="reviewer" title="GĂ©rard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-29 --> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns" title="3. The number and width of columns" /> + <link rel="match" href="multicol-count-computed-003-ref.xht" /> + <meta name="flags" content="ahem" /> + <meta name="assert" content="This test checks that if one of 2 adjacent column boxes (2nd and 3rd colum box in this test) does not have any content, then the column rule separating those should not be drawn. In this test, the 3rd colum box should have no inline content. This test also checks that inline content in the normal flow that extends into a column gap should not be clipped in the middle of the column gap. So, in this test, inline content in 1st column box should not be clipped and should overlappe partially the 1st column-rule." /> + <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" /> + <style type="text/css"><![CDATA[ + div + { + background: yellow; + border: gray solid 1em; + color: black; + font: 1.25em/1 Ahem; + orphans: 1; + widows: 1; + width: 13em; + + column-count: 3; + column-gap: 5em; + column-rule-color: blue; + column-rule-style: solid; + column-rule-width: 1.5em; + } + + /* + (11) if (column-width = auto) and (column-count != auto) then + (12) N := column-count; + (13) W := max(0, (available-width - ((N - 1) * column-gap)) / N); + (14) exit; + + So, the used column-count in this test is 3. + + W := max(0, (available-width - ((N - 1) * column-gap)) / N); + W == max(0, (13em - ((3 - 1) * 5em)) / 3); + W == max(0, (13em - (2 * 5em)) / 3); + W == max(0, (13em - (10em)) / 3); + W == max(0, (3em) / 3); + W == max(0, 1em); + W == 1em; + + So, the used column-width in this test is 1em. + */ + + #pink {color: pink;} + #orange {color: orange;} + #purple {color: purple;} + #gray {color: gray;} + + /* + Since + " + content that extends outside column boxes visibly overflows and is not clipped to the column box. + " + https://drafts.csswg.org/css-multicol-1/#overflow-inside-multicol-elements + this causes the right-half (0.5em) of the 'K' glyph to + overlap the right-half (0.75em) of the 1st blue column-rule. + Same thing should happen to the 'N' glyph of 'ORAN'. + + Because no inline content should be rendered into the + 3rd column box, this causes the 2nd column rule not + been rendered because + " + Column rules are only drawn between two columns that + both have content. + " + http://www.w3.org/TR/css3-multicol/#column-gaps-and-rules + */ + ]]></style> + </head> + + <body> + + <div> + <span id="pink">PINK</span> + <span id="orange">ORAN</span> + <span id="purple">PURP</span> + <span id="gray">GRAY</span> + </div> + + </body> +</html> |