This INCOMPLETE report is prepared by fantasai. It summarizes, section by section, the test coverage of CSS Writing Modes Level 3 in March 2015.
Notes for further improvement are written in orange.
Missing tests are described in red.
writing-mode
Property DefinitionThe property definition table defines the syntax and defaults.
This next section defines that writing-mode
specifies the block flow direction;
the tests check this for various types of boxes.
This property specifies whether lines of text are laid out horizontally or vertically and the direction in which blocks progress. Possible values:
- horizontal-tb
- Top-to-bottom block flow direction. The writing mode is horizontal.
- vertical-rl
- Right-to-left block flow direction. The writing mode is vertical.
- vertical-lr
- Left-to-right block flow direction. The writing mode is vertical.
The writing-mode property specifies the block flow direction, which determines the ordering direction of block-level boxes in a block formatting context; the ordering direction of line boxes in a block container that contains inlines; the ordering direction of rows in a table; etc. By virtue of determining the stacking direction of line boxes, the writing-mode property also determines whether the line boxes' orientation (and thus the writing mode) is horizontal or vertical.
The principal writing mode of the document is determined by the writing-mode and direction values specified on the root element. [...] Like direction, the writing-mode value of the root element is also propagated to the initial containing block and sets the block flow direction of the initial block formatting context.
horizontal-tb
| vertical-rl
| vertical-lr
| Comments | |
---|---|---|---|---|
in-flow block | block-flow-direction-001 | block-flow-direction-002 block-flow-direction-024 | block-flow-direction-003 block-flow-direction-023 | |
left-floated block | block-flow-direction-005 block-flow-direction-006 | These test pairs seem redundant, only one should be necessary. | ||
right-floated block | block-flow-direction-007 block-flow-direction-008 | These test pairs are redundant, only one should be necessary. | ||
absolutely-positioned block | block-flow-drection-009 | block-flow-drection-010 | ||
inline-block | block-flow-direction-011 block-flow-direction-012 block-flow-direction-013 | block-flow-direction-014 block-flow-direction-015 block-flow-direction-016 | These sets of tests could probably be folded together. | |
table-cell | block-flow-direction-017 | block-flow-direction-018 | ||
table-caption | block-flow-direction-019 | block-flow-direction-020 | ||
list-item | block-flow-direction-021 | block-flow-direction-022 | ||
initial containing block | block-flow-direction-025 | Missing vertical-lr test | Would be more comprehensive if auto-sized, also checked root size. |
horizontal-tb
| vertical-rl
| vertical-lr
| Comments | |
---|---|---|---|---|
in-flow block | line-box-direction-001 | line-box-direction-002 | line-box-direction-003 | |
right-floated orthogonal block | line-box-direction-005 line-box-direction-006 | line-box-direction-007 line-box-direction-008 | These pairs seem redundant. | |
absolutely-positioned orthogonal block | line-box-direction-009 | line-box-direction-010 | ||
orthogonal inline-block | line-box-direction-011 line-box-direction-011 | line-box-direction-013 line-box-direction-014 | These tests need to remove display: block. | |
orthogonal table-cell | line-box-direction-015 | line-box-direction-016 | ||
orthogonal table-cell | line-box-direction-015 | line-box-direction-016 | ||
orthogonal table-caption | line-box-direction-017 | line-box-direction-019 | ||
orthogonal list-item | line-box-direction-020 | Missing vertical-lr test | ||
Missing test for outside list-item markers. (list-items-vert-rl-005 is invalid) | ||||
Missing test for inside list-item markers. |
This next section defines some special box-type transformations
when writing-mode
of the parent and child differ.
If a box has a different block flow direction than its containing block:
- If the box has a specified display of inline, its display computes to inline-block. [CSS21]
- If the box has a specified display of run-in, its display computes to block. [CSS21]
- If the box is a block container, then it establishes a new block formatting context.
horizontal-tb
| vertical-rl
| vertical-lr
| Comments | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
inline-block inside inline | different-block-flow-dir-001 | Missing vertical-lr test | Needs to confirm that #outer still remains inline.
inline-block inside inline-block
|
| different-block-flow-dir-002
| Missing vertical-lr test
| Needs to confirm that #outer is inline-block, preferably by including a second #inner.
| Tests for | run-in not necessary; this feature was dropped from CSS2.1.
Missing tests for block formatting context.
| |
These tests check orthogonal writing modes. Need to also check behavior of parallel writing modes.
Need to check that direciton
and text-orientation
do not tirgger these effects;
only writing-mode
property itself does.
The content of replaced elements do not rotate due to the writing mode: images, for example, remain upright. However replaced content involving text (such as MathML content or form elements) should match the replaced element’s writing mode and line orientation if the UA supports such a vertical writing mode for the replaced content.
horizontal-tb
| vertical-rl
| vertical-lr
| Comments | |
---|---|---|---|---|
images | inline-replaced-vrl-002 inline-replaced-vrl-004 | inline-replaced-vlr-003 inline-replaced-vlr-005 | Need to check also for setting writing-mode direction on IMG, in case UA is using style rules to fix images. Replace 'vertical-align: top' with 'display: block' in 002/3, to test block-level images and avoid duplication. | |
image alt text | replaced-content-image-002 | replaced-content-image-003 | ||
form controls | form-controls-vert-rl-004 form-controls-vert-rl-005 | Height declaration seems unnecessary in -004. Instructions in -005 could be improved. | ||
MathML | Missing test for MathML | Missing test for MathML |
text-orientation
| horizontal-tb
| vertical-rl
| vertical-lr
| |||
---|---|---|---|---|---|---|
ltr
| rtl
| ltr
| rtl
| ltr
| rtl
| |
mixed
| ||||||
upright
| ||||||
sideways
| ||||||
sideways-left
| ||||||
sideways-right
|
horizontal-tb
| vertical-rl
| vertical-lr
| Comments | |
---|---|---|---|---|
pagination | page-flow-direction-002 | page-flow-direction-003 | Need to set width: 100% on HTML element also! Need to check direction of page flow, not just whether it breaks into pages. A 400%-wide canvas bg image might work. Test can avoid using images with horizontal-tb setting on divs. |