min-height-106

min-height - float and overflow

WeasyPrint

This browser

Flags
ahem
Assertion
'min-height' specifies a fixed minimum used height. If the element requires an horizontal scrollbar, then the horizontal scrollbar height should be subtracted from the height of its containing block so that the resulting used height continues to honor the declared min-height.

Source

 1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 2 <html>
 3 
 4  <head>
 5 
 6   <title>CSS Test: min-height - float and overflow</title>
 7 
 8   <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/">
 9   <link rel="author" title="Hilbrand Edskes" href="http://edskes.com/">
10   <link rel="help" href="http://www.w3.org/TR/CSS21/visudet.html#min-max-heights">
11   <link rel="help" href="http://www.w3.org/TR/CSS21/visufx.html#overflow">
12   <meta content="ahem" name="flags">
13   <meta content="'min-height' specifies a fixed minimum used height. If the element requires an horizontal scrollbar, then the horizontal scrollbar height should be subtracted from the height of its containing block so that the resulting used height continues to honor the declared min-height." name="assert">
14 
15   <style type="text/css">
16   div
17   {
18   font: 100px/1 Ahem;
19   overflow: auto;
20   width: 200px;
21   }
22 
23   #test-red-overlapped
24   {
25   background-color: red;
26   color: red;
27   float: left;
28   min-height: 200px;
29   }
30 
31   #control-green-overlapping
32   {
33   background-color: green;
34   clear: left;
35   color: green;
36   height: 200px;
37   position: relative;
38   top: -200px;
39   }
40   </style>
41 
42  </head>
43 
44  <body>
45 
46   <p>PREREQUISITE: User agent needs to support scrollbars as the scrolling mechanism. If it does not, then this test case does not apply to this user agent.</p>
47 
48   <p>Test passes if there is a green square and <strong>no red</strong>.</p>
49 
50   <div id="test-red-overlapped">XXX</div>
51 
52   <div id="control-green-overlapping">XX</div>
53 
54  </body>
55 </html>