tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

line-break-anywhere-005.html (1458B)


      1 <!DOCTYPE html>
      2 <html lang=en>
      3 <meta charset="utf-8">
      4 <title>CSS Text Test: line-break: anywhere</title>
      5 <link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com" />
      6 <link rel="help" title="3. White Space and Wrapping: the white-space property" href="https://www.w3.org/TR/css-text-3/#white-space-property">
      7 <link rel="help" title="5.3. Line Breaking Strictness: the line-break property" href="https://www.w3.org/TR/css-text-3/#propdef-line-break">
      8 <link rel="help" href="https://drafts.csswg.org/css-text-3/#valdef-white-space-break-spaces">
      9 <link rel="help" href="https://drafts.csswg.org/css-text-3/#valdef-line-break-anywhere">
     10 <link rel="match" href="reference/line-break-anywhere-004-ref.html">
     11 <meta name="assert" content="line-break: anywhere + break-spaces do allow a break
     12 between the last character of a word and the first space of a sequence of preserved
     13 spaces even if there is a previous breaking opportunity">
     14 <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
     15 <style>
     16 div {
     17  font: 25px/1 Ahem;
     18  width: 4ch;
     19  line-height: 1;
     20 }
     21 .red {
     22  position: absolute;
     23  white-space: pre;
     24  color: red;
     25  background: green;
     26  z-index: -1;
     27 }
     28 .test {
     29  white-space: break-spaces;
     30  line-break: anywhere;
     31  color: green;
     32 }
     33 </style>
     34 <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p>
     35 <div class="red">X XX<br> XX <br>X XX<br> X</div>
     36 <div class="test">X XX XX X XX X</div>