Re: [csswg-drafts] [css-highlight-api] Support for some font styles and decorations (#8355)

To avoid being layout affecting, we'd need more than just a monospaced font. We'd need the two fonts we're swapping from/to to be:
* fonts with the same x-height
* fonts with the same leading
* fonts with the same monospace advance measure
* *really* monospace: not just monospace over the ascii range, and varying results over the whichever other part of unicode is supported
* fonts with the same unicode coverage (otherwise, they might trigger fallback on different characters, and unless those fallbacks are also monospaced / same x-height / same leading / … we're back to square one)
…

All in all, swapping fonts is, in the general case, layout affecting, and I doubt that's going to be practical here.

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


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 25 September 2023 07:11:40 UTC