Fix for some issues on Windows (hinting, and font naming in some programs) #202
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
(nb I don’t know 100% what I’m doing here, so I’d love to hear from someone who knows this stuff what is actually going on here)
This PR contains two commits to fix some weird issues I am seeing on Windows 11.
Chinese glyphs in TTF and OTF thumbnails
This stops happening if you remove CJK from the OS/2 charsets. For that I added explicit entries in all the fonts.props files.
GIMP fails to use some fonts
The unadorned versions show the 08 weight. I don't know why the italic thumbnail is blank but that variant works. The
#1
variants don't work.I suspect some apps don’t tolerate anything else than the usual "Bold" or "Italic" styles in style names. So I changed the TTF names so the "08" and "12" becomes part of the font family name. This seems not ideal but at least I can use all the fonts now.
So for that I edited the
LangName
entries like this:Hinting
A picture says more than a 1000 words. This is what I got on Windows 11 😟
TTF on the left, OTF on the right.
So it took some experimentation to figure out that:
ttfautohint
does not affect opentype font files.font.generate()
if you don’t give it a flags argument. But be advised if you specify it at all, by default you do not get opentype tables in your font unless you use the "opentype" flag.ttfautohint
actually works. It was instructed to use the “slight”, or “natural” hinting.