W3C home > Mailing lists > Public > public-css-archive@w3.org > October 2020

Re: [csswg-drafts] [css-fonts] Reduce layout shift via @font-face descriptor(s) overriding inline spacing (#5533)

From: jfkthame via GitHub <sysbot+gh@w3.org>
Date: Wed, 21 Oct 2020 10:35:48 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-713475566-1603276547-sysbot+gh@w3.org>
Personally, I'm unconvinced this is a good idea at all. Glyph spacing is an integral part of the font design, and arbitrarily overriding the spacing of glyphs -- not for a specific design intent such as letter-spacing but just to try and match metrics of some other font -- is never likely to look good.

To minimize layout shift, specify fallback fonts that have similar metrics to the desired webfont. If they're different enough that layout shift will be a significant problem, then they're also different enough that forcing them to match the intended font will be a distortion.

If it's more important to avoid layout shift than to use the designer's "ideal" font, then add a `font-display` descriptor to make it optional, and if it doesn't load quickly enough, just continue to use a fallback (with its own proper glyph spacing, not shoehorned into the metrics of the font that didn't load).

-- 
GitHub Notification of comment by jfkthame
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5533#issuecomment-713475566 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 21 October 2020 10:35:50 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:42:20 UTC