pre-wrap-leading-spaces-015.html (1098B)
1 <!doctype html> 2 <meta charset=utf-8> 3 <title>CSS Text test: breaking opportunities at leading spaces with white-space:pre-wrap</title> 4 <link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com" /> 5 <link rel="help" href="https://drafts.csswg.org/css-text-3/#white-space-phase-2"> 6 <link rel="help" href="https://drafts.csswg.org/css-text-3/#white-space-property"> 7 <link rel="help" href="https://drafts.csswg.org/css-text-3/#valdef-white-space-pre-wrap"> 8 <link rel="match" href="reference/white-space-break-spaces-005-ref.html"> 9 <meta name="assert" content="Empty line with preserved white spaces must account for box sizing."> 10 <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" /> 11 <style> 12 .ref { 13 position: absolute; 14 background: red; 15 width: 100px; 16 height: 100px; 17 z-index: -1; 18 } 19 .test { 20 font: 50px/1 Ahem; 21 width: 2ch; 22 background: green; 23 color: green; 24 25 white-space: pre-wrap; 26 } 27 </style> 28 29 <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> 30 <div class="ref"></div> 31 <div class="test">   X</div>