tor-browser

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

ex-unit-003.html (1074B)


      1 <!DOCTYPE html>
      2 <meta charset="utf-8">
      3 <title>CSS Values and Units Test: support for the ex 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/ex-unit-002-ref.html">
      7 <meta name="assert" content="Even in vertical writing modes, the ex unit equals the x-height of the first available font if it has reliable metrics for the x-height.">
      8 <style>
      9 @font-face {
     10  font-family: ExTest;
     11  src: url(resources/ExTest.woff);
     12 }
     13 div {
     14  height: 10px;
     15  background-color: blue;
     16  margin-top: 10px;
     17 }
     18 .test {
     19  writing-mode: vertical-rl;
     20  width: 10ex;
     21 }
     22 .ref {
     23  width: 100px;
     24 }
     25 </style>
     26 <p>The test passes if there are two blue rectangles of equal length.</p>
     27 <!-- ExTest is a font whose OS/2 table's sxHeight field is set to an
     28     eighth of the font's units per em, so ex units should compute to
     29     0.125em, resulting in the div being 100px wide. -->
     30 <div class="test" style="font: 80px ExTest;"></div>
     31 <div class="ref"></div>