433700-ref.html (2616B)
1 <html><head> 2 <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> 3 <title>Testcase for bug 433700</title> 4 <style type="text/css"> 5 6 body { font-family: sans-serif; font-size: 16px; } 7 8 fieldset,legend { padding:0; margin:0; border-width:0; border-style:solid; } 9 fieldset { border-right:7px solid blue; font-size: 16px; } 10 11 #test1 { position:fixed; } 12 #test1 fieldset { background:lime;} 13 #test1 .legend { margin-left:30px; background:pink; } 14 15 #test2 { position:fixed; top:3em; } 16 #test2 fieldset { background:lime; width:260px; } 17 #test2 .legend { margin-left: 20px; background:pink; } 18 19 #test3 { position:fixed; top:6em; width:200px; } 20 #test3 fieldset { background:lime;} 21 #test3 .legend { margin-left: 80px; background:pink; } 22 23 #test4 { position:fixed; top:9em; width:200px; } 24 #test4 fieldset { background:lime; width:260px; } 25 #test4 .legend { margin-left: 80px; background:pink; } 26 27 #test5 { position:fixed; top:12em; width:200px; } 28 #test5 fieldset { background:lime;} 29 /* Percentage margins don't get counted in intrinsic width, so make sure that 30 our fixed-size margins sum to 0, so they also do not affect intrinsic width 31 either. */ 32 #test5 .legend { margin-left: 193px; background:pink; margin-right: -193px; } 33 34 #test6 { position:fixed; left:20px; top:15em; width:400px; } 35 #test6 fieldset { width:300px; } 36 #test6 fieldset div { position:relative; left:100px; padding-left:0px; width:200px; background:lime; } 37 #test6 legend { margin-left:0; background:pink; } 38 39 fieldset div { padding-left:60px; } 40 41 .legend { display:block; } 42 43 </style> 44 </head> 45 <body> 46 47 <div id="test1"> 48 <fieldset> 49 <legend><span class="legend">LEGEND</span></legend> 50 <div>FIELDSET</div> 51 <script>var v = document.body.offsetHeight;</script> 52 </fieldset> 53 </div> 54 55 <div id="test2"> 56 <fieldset> 57 <legend><span class="legend">LEGEND</span></legend> 58 <div>FIELDSET</div> 59 <script>var v = document.body.offsetHeight;</script> 60 </fieldset> 61 </div> 62 63 <div id="test3"> 64 <fieldset> 65 <legend><span class="legend">LEGEND</span></legend> 66 <div>FIELDSET</div> 67 <script>var v = document.body.offsetHeight;</script> 68 </fieldset> 69 </div> 70 71 <div id="test4"> 72 <fieldset> 73 <legend><span class="legend">LEGEND</span></legend> 74 <div>FIELDSET</div> 75 <script>var v = document.body.offsetHeight;</script> 76 </fieldset> 77 </div> 78 79 <div id="test5"> 80 <fieldset> 81 <legend><span class="legend">LEGEND</span></legend> 82 <div>FIELDSET</div> 83 <script>var v = document.body.offsetHeight;</script> 84 </fieldset> 85 </div> 86 87 <div id="test6"> 88 <fieldset> 89 <legend>LEGEND</legend> 90 <div>FIELDSET</div> 91 <script>var v = document.body.offsetHeight;</script> 92 </fieldset> 93 </div> 94 95 </body></html>