table-height-algorithm-008.xht (2198B)
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: Height of a cell is maximum between its specified 'height' and content minimum height</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#height-layout" /> 7 <meta name="flags" content="ahem" /> 8 <meta name="assert" content="The height of a cell is the maximum between its specified 'height' and content minimum height." /> 9 <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" /> 10 <style type="text/css"> 11 #reference 12 { 13 background: black; 14 font: 16px/1em Ahem; 15 height: 10em; 16 width: 20em; 17 } 18 table 19 { 20 border-spacing: 0; 21 } 22 td 23 { 24 padding: 0; 25 } 26 .c1 27 { 28 background: blue; 29 color: blue; 30 height: 1em; 31 } 32 .c2 33 { 34 background: purple; 35 color: purple; 36 height: 5em; 37 } 38 </style> 39 </head> 40 <body> 41 <p>Test passes if the blue and purple boxes below are half the height of the black box.</p> 42 <div id="reference"> 43 <table> 44 <tr> 45 <td class="c1">XXXXXXXXXX</td> 46 </tr> 47 <tr> 48 <td class="c1">XXXXXXXXXX</td> 49 </tr> 50 <tr> 51 <td class="c1">XXXXXXXXXX</td> 52 </tr> 53 <tr> 54 <td class="c1">XXXXXXXXXX</td> 55 </tr> 56 <tr> 57 <td class="c1">XXXXXXXXXX</td> 58 </tr> 59 </table> 60 <table> 61 <tr> 62 <td class="c2">XXXXXXXXXX</td> 63 </tr> 64 </table> 65 </div> 66 </body> 67 </html>