Related Topic
Describe
I'm trying to convert the font using TTFont.
It works fine.
from fontTools.ttLib import TTFont
font = TTFont( SOURCE_PATH )
font.flavor = "woff"
font.save( TARGET_PATH )
But..
There is no way to use zopfli in document ttFont Doc.
What can I do?
Here is the approach that is being used in ttx:
I think that if you set sfnt.USE_ZOPFLI = True before your font.save([PATH]) step, SFNTWriter should use zopfli rather than the zlib package?
Chris is correct, although I dislike that approach of modifying a global variable. Pity I didn't get the chance to fix that yet. (PRs welcome)
@chrissimpkins
Thanks for telling me a good way.
If I have enough time, I will consider writing a PR.
Most helpful comment
Chris is correct, although I dislike that approach of modifying a global variable. Pity I didn't get the chance to fix that yet. (PRs welcome)