Improve glyphset viewing and embedding specific characters
- Dominant language
- HTML
- Stars
- 20.5k
- Forks
- 2.9k
- Avg merge
- 1d 21h
- Merged PRs (30d)
- 95
Description
**Describe the issue**
Wondering why a `css2` embedded font was lacking certain characters revealed a number of issues with embed documentation and font presentation. For example with this embed code:
``````
a website would not render "→" `U+2192`. The issues encountered along the chain of trying to debug this:
1. The [font page Gylphs tab](https://fonts.google.com/specimen/Work+Sans/glyphs) seemingly shows the fonts character set, yet it actually shows an arbitrary selection of characters. This is misleading to the point of making the user think the font does not, in fact, include characters not listed here.
2. The github documentation link on a font page links only to the project website, not the Google fonts repository of the font. To find the actual truth of what characters are currently in the Google fonts version the repository link should be added.
3. Neither the [embed code page](https://fonts.google.com/selection/embed) nor the [css2 API documentation page](https://developers.google.com/fonts/docs/css2) clearly state that the embed code will, in fact, load an arbitrary subset of the font.
4. This subset is not readily documented anywhere I could find, other than by intercepting the webfont sent to the browser and inspecting it.
5. The `&text=...` parameter could facilitate adding a specific character to the default charset, instead of requiring a full text. e.g. to use Work Sans for normal Latin text setting, _but also including "→"_ the text parameter needs to be explicitly fed a url encoded full Latin charset, e.g. to add "→" (%E2%86%92) to the embed, instead of:
``````
the parameter could support a similar shortform:
``````
**To Reproduce**
See the embed code above.
**Expected behavior**
A clear documentation that:
1. Fonts are subset
2. What that subset is
3. How to add specific characters to an embed more easily
Contributor guide
Assessment
This issue has not been assessed yet.