Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle .ttf fonts with missing ulCodePageRange1 entries #906

Merged
merged 1 commit into from
Mar 15, 2022

Conversation

corranwebster
Copy link
Contributor

I think this happens for either very old fonts or fonts which aren't fully compliant with the open type specification. Not much either we or the user can do about it, so we just ignore - the information we want isn't there.

We could write a test if we can find a font which is missing this piece of data and has a suitable license (eg. OTL). However the only fonts I could find with this are Humor sans 1.0 which is unlicensed and MTExtra which is owned by Microsoft and which is not suitably licensed.

A reviewer can validate that this PR works by:

  • having either Humor Sans or MTExtra installed in their test system
  • clearing out ~/.enthought/kiva (or the corresponding directory on Windows)
  • running some code which uses fonttools (eg. the kiva_explorer script should be fine).
  • confirming that there is no error output to the consule

Fixes #882.

I think this happens for either very old fonts or fonts which aren't fully
compliant with the open type specification.  Not much either we or the user
can do about it.
@corranwebster corranwebster merged commit bcb8d25 into main Mar 15, 2022
@jwiggins jwiggins deleted the fix/ttf-font-property-error branch March 15, 2022 19:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Running Kiva for the first time raises errors while recreating font cache
2 participants