floats-006

Left floats interacting with inline content

WeasyPrint

This browser

Flags
ahem
Assertion
Inline boxes are reflowed to the first available line on the other side of a float.

Source

 1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 2 <html>
 3     <head>
 4         <title>CSS Test: Left floats interacting with inline content</title>
 5         <link rel="author" title="Microsoft" href="http://www.microsoft.com/">
 6         <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#floats">
 7         <meta name="flags" content="ahem">
 8         <meta name="assert" content="Inline boxes are reflowed to the first available line on the other side of a float.">
 9         <style type="text/css">
10             #div1
11             {
12                 height: 2in;
13                 width: 3in;
14             }
15             #span1
16             {
17                 color: orange;
18                 font: 1in/1 Ahem;
19             }
20             .class1
21             {
22                 background-color: blue;
23                 float: left;
24                 height: 1in;
25                 width: 1in;
26             }
27         </style>
28     </head>
29     <body>
30         <p>Test passes if the blue box is to the left of the orange box and the boxes top edges are aligned.</p>
31         <div id="div1">
32            <span id="span1">X</span>
33            <div class="class1"></div>
34            <div class="class1"></div>
35         </div>
36     </body>
37 </html>