c414-flt-fit-005.xht (1785B)
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> 2 <html xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <title>CSS Test: Non-Replaced Float Not Fitting Beside Opposite Float</title> 5 6 <link rel="author" title="CSS1 Test Suite Contributors" href="http://www.w3.org/Style/CSS/Test/CSS1/current/tsack.html"/> 7 <link rel="author" title="Ian Hickson" href="mailto:ian@hixie.ch"/> 8 <link rel="reviewer" title="GĂ©rard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2012-06-30 --> 9 <link rel="help" href="http://www.w3.org/TR/REC-CSS1#floating-elements"/> 10 <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#floats" title="9.5 Floats"/> 11 <link rel="help" href="http://www.w3.org/TR/CSS21/text.html#alignment-prop" title="16.2 Alignment: the 'text-align' property"/> 12 <link rel="match" href="c414-flt-fit-005-ref.xht" /> 13 14 <style type="text/css"><![CDATA[ 15 .control { padding: 1em; } 16 .control div { width: 10em; background: navy; color: yellow; } 17 .control div.right { margin-left: 5em; text-align: right; } 18 .test { width: 15em; margin: 1em; } 19 .test div { margin: 0; padding: 0; background: red; } 20 .test p { margin: 0; padding: 0; width: 10em; background: navy; color: yellow; } 21 .test p.left { float: left; text-align: left; } 22 .test p.right { float: right; text-align: right; } 23 ]]></style> 24 </head> 25 <body> 26 <p>Test pass if the 2 patterns are identical with <strong>no red</strong>.</p> 27 <div class="control"> 28 <div class="left">  ☮ </div> 29 <div class="right"> ☮  </div> 30 </div> 31 <div class="test"> 32 <div> 33 <p class="left">  ☮ </p> 34 <p class="right"> ☮  </p> 35 </div> 36 </div> 37 </body> 38 </html>