OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <html> |
| 3 <head> |
| 4 <style> |
| 5 #thecol { |
| 6 width: 200px; |
| 7 } |
| 8 td { |
| 9 height: 25px; |
| 10 } |
| 11 </style> |
| 12 <script type="text/javascript"> |
| 13 function runTest() { |
| 14 var col = document.getElementById('thecol'); |
| 15 col.offsetTop; |
| 16 col.style.width="100px"; |
| 17 window.checkLayout("#td1", document.getElementById("test-output"
)); |
| 18 window.checkLayout("#td2", document.getElementById("test-output"
)); |
| 19 window.checkLayout("#td3", document.getElementById("test-output"
)); |
| 20 window.checkLayout("#td4", document.getElementById("test-output"
)); |
| 21 window.checkLayout("#td5", document.getElementById("test-output"
)); |
| 22 window.checkLayout("#td6", document.getElementById("test-output"
)); |
| 23 window.checkLayout("#td7", document.getElementById("test-output"
)); |
| 24 window.checkLayout("#td8", document.getElementById("test-output"
)); |
| 25 window.checkLayout("#td9", document.getElementById("test-output"
)); |
| 26 } |
| 27 </script> |
| 28 <script src="../../resources/check-layout.js"></script> |
| 29 </head> |
| 30 <body onload="runTest()"> |
| 31 Tests that the width of table cell changes on changing the colgroup widt
h to new width. |
| 32 <table> |
| 33 <colgroup> |
| 34 <col id="thecol" span="4" style="background-color:red"> |
| 35 </colgroup> |
| 36 <thead> |
| 37 <tr> |
| 38 <td id="td1" data-expected-width="100"></td> |
| 39 <td id="td2" data-expected-width="100"></td> |
| 40 <td id="td3" data-expected-width="100"></td> |
| 41 </tr> |
| 42 </thead> |
| 43 <tfoot> |
| 44 <tr> |
| 45 <td id="td4" data-expected-width="100"></td> |
| 46 <td id="td5" data-expected-width="100"></td> |
| 47 <td id="td6" data-expected-width="100"></td> |
| 48 </tr> |
| 49 </tfoot> |
| 50 <tbody> |
| 51 <tr> |
| 52 <td id="td7" data-expected-width="100"></td> |
| 53 <td id="td8" data-expected-width="100"></td> |
| 54 <td id="td9" data-expected-width="100"></td> |
| 55 </tr> |
| 56 </tbody> |
| 57 </table> |
| 58 <div id="test-output"></div> |
| 59 </body> |
| 60 </html> |
OLD | NEW |