table-layout-applies-to-003.xht (2175B)
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 2 <html xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <title>CSS Test: Table-layout and 'display: list-item' elements</title> 5 <link rel="author" title="Microsoft" href="http://www.microsoft.com/" /> 6 <link rel="help" href="http://www.w3.org/TR/CSS21/tables.html#propdef-table-layout" /> 7 <link rel="help" href="http://www.w3.org/TR/CSS21/tables.html#width-layout" /> 8 <meta name="flags" content="ahem" /> 9 <meta name="assert" content="Table-layout does not apply to 'display: list-item' elements." /> 10 <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" /> 11 <style type="text/css"> 12 body 13 { 14 margin-left: 1em; 15 } 16 #test 17 { 18 display: list-item; 19 table-layout: fixed; 20 width: 10em; 21 } 22 .colgroup 23 { 24 display: table-column-group; 25 width: 5em; 26 } 27 .tr 28 { 29 display: table-row; 30 } 31 .td 32 { 33 background: black; 34 display: table-cell; 35 font: 1em Ahem; 36 overflow: hidden; 37 padding: 0; 38 } 39 #reference 40 { 41 background: blue; 42 height: 2em; 43 width: 20em; 44 } 45 </style> 46 </head> 47 <body> 48 <p>Test passes if both bars below are the same width and there is a marker bullet on the left-hand side of the black box.</p> 49 <div id="test"> 50 <div class="colgroup"></div> 51 <div class="colgroup"></div> 52 <div class="tr"> 53 <div class="td">XXXXX</div> 54 <div class="td">XXXXX</div> 55 </div> 56 <div class="tr"> 57 <div class="td">XXXXXXXXX0</div> 58 <div class="td">XXXXXXXXX0</div> 59 </div> 60 </div> 61 <div id="reference"></div> 62 </body> 63 </html>