1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2 <html>
3 <head>
4 <title>CSS Test: White-space set to 'inherit'</title>
5 <link rel="author" title="Microsoft" href="http://www.microsoft.com/">
6 <link rel="help" href="http://www.w3.org/TR/CSS21/text.html#propdef-white-space">
7 <link rel="help" href="http://www.w3.org/TR/CSS21/text.html#white-space-prop">
8 <meta name="flags" content="ahem">
9 <meta name="assert" content="The 'white-space' property set to 'inherit' causes the element to use its parent's white-space value.">
10 <style type="text/css">
11 #wrapper
12 {
13 white-space: pre;
14 }
15 div
16 {
17 font: 1em Ahem;
18 line-height: 1em;
19 }
20 #test
21 {
22 white-space: normal;
23 white-space: inherit;
24 }
25 #reference
26 {
27 height: 1em;
28 width: 7em;
29 }
30 #div1, #div3
31 {
32 background: black;
33 }
34 #div1, #div2, #div3
35 {
36 display: inline-block;
37 height: 1em;
38 width: 2em;
39 }
40 #div2
41 {
42 height: 1em;
43 width: 3em;
44 }
45 </style>
46 </head>
47 <body>
48 <p>Test passes if there are two black squares on the page.</p>
49 <div id="wrapper"><div id="test">XX XX</div></div>
50 <div id="reference"><div id="div1"></div><div id="div2"></div><div id="div3"></div></div>
51 </body>
52 </html>