floriankarsten / space-grotesk

Space Grotesk: a proportional variant of the original fixed-width Space Mono family
https://floriankarsten.github.io/space-grotesk
SIL Open Font License 1.1
1.56k stars 62 forks source link

Issue with vertical alignment on the web? #14

Closed nixolas1 closed 4 years ago

nixolas1 commented 4 years ago

Hi, I tried out the font on a site, but I'm getting weird vertical alignments. It seems like the font is aligned at the top of the letters, instead of the base?

Here's an example with three different line heights, 0, 1 and 2: image

I tested with the variable font, OTF and WOFF2, but all had the same issue. Also tried setting different vertical-align-s, but no difference Have you noticed this yourself, or am i doing something wrong?

Here is the font-family declaration i have:

@font-face {
  font-family: 'SpaceGrotesk';
  src: url('/static/fonts/SpaceGrotesk-Regular.otf') format('opentype');
  font-weight: 400;
  font-display: swap;
}
nixolas1 commented 4 years ago

Nevermind, in the screenshot it looks vertically aligned. Seems like I was doing some flex-streching :)