tor-browser

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

ch-unit-017.html (1115B)


      1 <!DOCTYPE html>
      2 <meta charset="utf-8">
      3 <title>CSS Values and Units Test: support for the ch unit</title>
      4 <link rel="author" title="Cameron McCormack" href="mailto:cam@mcc.id.au">
      5 <link rel="help" href="https://drafts.csswg.org/css-values-3/#font-relative-lengths">
      6 <link rel="match" href="reference/ch-unit-016-ref.html">
      7 <meta name="assert" content="In vertical upright writing modes, the ch unit is equal to the vertical advance of the zero glyph.">
      8 <style>
      9 @font-face {
     10  font-family: ChTestShortZero;
     11  src: url(resources/ChTestShortZero.woff);
     12 }
     13 div {
     14  height: 10px;
     15  background-color: blue;
     16  margin-top: 10px;
     17 }
     18 .test {
     19  writing-mode: vertical-rl;
     20  text-orientation: upright;
     21  width: 5ch;
     22 }
     23 .ref {
     24  width: 100px;
     25 }
     26 </style>
     27 <p>The test passes if there are two blue rectangles of equal length.</p>
     28 <!-- ChTestShortZero has a '0' glyph whose vertical advance is a quarter
     29     of the units per em, so ch units in vertical upright writing modes
     30     should compute to 0.25em, resulting in the div being 100px width. -->
     31 <div class="test" style="font: 80px ChTestShortZero;"></div>
     32 <div class="ref"></div>