[csswg-drafts] [css-text] Glyph substitution (#8545)

romainmenke has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-text] Glyph substitution ==
Recently ran into several similar issues:

- A project where the branding/client liked the visual appearance of `Æ` when the actual text content should have been `ae`.
- A project where a single character from the brand name was omitted and a space was rendered : `f o` when the actual text content should have been `foo`.

When solving this with actual character replacements we are creating problems for accessibility, SEO, how text breaks and wraps,...

Content editors also find it hard to consistently apply the "special" notation.

The alternative is to solve this in the font files by adding custom ligatures and substitutions.
This works really well and avoids all the issues mentioned above.

But adding custom ligatures is technically complex and not always feasible depending on the font files and their license.

It is not something that can be easily and quickly done by a frontend/css developer.

-----

This made me wonder if this could be solved with CSS?

- Is this something that is useful for more people than just me?
- Is this implementable?

-----

There are two classes of substitutions I am thinking of, but there might be more :
- replace an existing glyph in a font with another (or multiple)
- replace a glyph (or multiple) with a path/shape

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8545 using your GitHub account


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

Received on Wednesday, 8 March 2023 19:17:09 UTC