CSS2 Test Suite: 16.6 white-space

[index page] [section] [Previous] [Next] [Specification]

The style declarations contained within this page:

.cl1 {white-space: pre;}
.cl2 {white-space: nowrap;}
.cl3 {white-space: normal;}
div.parent {white-space: normal;}
div.inh1 {white-space: pre;}
div.inh2 {white-space: nowrap;}


[cl1] This paragraph should show extra space where there would ordinarily not be any. There should also be preservation of returns as this sentence very clearly demonstrates.

[cl2] This paragraph should not word-wrap, no matter how long the paragraph might be or over how many lines it would ordinarily wrap, as it has been set to white-space: nowrap and that should have the obvious effect.

[cl1] This paragraph should show extra space, [cl3] except in the second half.


[div.parent] This DIV has been set with parental styles. The inline elements within this DIV are enclosed in square brackets in order to more easily discern their placement.
[div.inh1] This DIV should use normal white space handling for its display, as it has a style attribute set to inherit the white-space value. [/div.inh1]
[div.inh2] This DIV should use normal white space handling for its display, as it has a style attribute set to inherit the white-space value. [/div.inh2]
This is the end of the parent DIV. [/div.parent]

[index page] [section] [Previous] [Next] [Specification]