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: CSS Floats: Shrink Wrapped Right Floats With Right Aligned Text</title>
5 <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch">
6 <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/float/013.xml" type="application/xhtml+xml">
7 <link rel="alternate" href="http://www.hixie.ch/tests/adhoc/css/box/float/013.html" type="text/html">
8 <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#floats">
9 <style>
10 .control { display: inline; font: 1em/1 Ahem, sans-serif; background: red; color: white; }
11 .container { width: 40%; padding: 0; margin: 1em; border: solid black; font: 2em/1 Ahem; height: 1em; width: 3em; background: white; }
12 .test { text-align: right; float: right; clear: right; color: green; }
13 </style>
14 </head>
15 <body>
16 <p class="control">Ahem_font_would_be_nice_for_this_test.</p>
17 <p>The following two boxes should look identical.</p>
18 <div class="container"> <div class="test">x x</div> </div>
19 <div class="container"> <div class="test"> x x </div> </div>
20 </body>
21 </html>