diff --git a/gecko-bug/EBGaramond-Regular.woff2 b/gecko-bug/EBGaramond-Regular.woff2 new file mode 100644 index 0000000..a744a61 Binary files /dev/null and b/gecko-bug/EBGaramond-Regular.woff2 differ diff --git a/gecko-bug/OpenSans-Regular.ttf b/gecko-bug/OpenSans-Regular.ttf new file mode 100644 index 0000000..8529c43 Binary files /dev/null and b/gecko-bug/OpenSans-Regular.ttf differ diff --git a/gecko-bug/index.html b/gecko-bug/index.html new file mode 100644 index 0000000..1e7e3af --- /dev/null +++ b/gecko-bug/index.html @@ -0,0 +1,48 @@ + + + + + + The Trees of Kortirion + + + + + +

OpenType font features do not display on any element that shares all font properties with an element that has a property set using the ch unit.

+

The incorrect behaviour is observed on:

+ +

The correct behaviour is observed on:

+ +
+

EB Garamond

+

The first div has a font-size of 7rem and a height of 10rem. The elongated "Q" displays correctly.

+

The second div has a font-size of 8rem and a height of 3ch. The elongated "Q" does not display, because of the use of the ch unit.

+

The third div has a font-size of 8rem and a height of 10rem. The elongated "Q" still does not display, because of the use of the ch unit in the second div, which has the same font-size.

+
Queen
+
Queen
+
Queen
+
+
+

Open Sans

+

As for the other font.

+
going
+
going
+
going
+
+ + + diff --git a/gecko-bug/style.css b/gecko-bug/style.css new file mode 100644 index 0000000..13423bb --- /dev/null +++ b/gecko-bug/style.css @@ -0,0 +1,70 @@ +@font-face { + font-family: "EB Garamond"; + font-style: normal; + font-weight: 400; + src: url(./EBGaramond-Regular.woff2) format("woff2"); +} + +@font-face { + font-family: "Open Sans"; + font-style: normal; + font-weight: 400; + src: url(./OpenSans-Regular.ttf) format("truetype"); +} + +@font-feature-values "EB Garamond" { + @swash { + long-q: 1; + } +} + +@font-feature-values "Open Sans" { + @styleset { + alt-g: 1; + } +} + +.garamond { + font-family: "EB Garamond", serif; + font-variant-alternates: swash(long-q); +} + +.open-sans { + font-family: "Open Sans", sans-serif; + font-variant-alternates: styleset(alt-g); +} + +.correct { + font-size: 7rem; + height: 10rem; +} + +.broken { + font-size: 8rem; + height: 3ch; +} + +.also-broken { + font-size: 8rem; + height: 10rem; +} + +/* CSS below here is irrelevant to the bug */ + +.testcase { + display: inline-block; + vertical-align: top; + width: 22rem; + margin: 1rem; + padding: 2rem; + border: 0.5rem dashed #ce5e46; +} + +h1 { + font-weight: normal; + color: #ce5e46; +} + +body { + background-color: #f9f9ef; +}