googlefonts / nam-files

Unicode ranges used to subset fonts in the Google Fonts CSS API
Apache License 2.0
3 stars 0 forks source link

`unique_glyphs=False` modifies the cached subset for `CodepointsInSubset` #17

Open dscorbett opened 4 months ago

dscorbett commented 4 months ago

Calling CodepointsInSubset without unique_glyphs=True modifies the cached subset, which affects later calls with unique_glyphs=True.

>>> from gfsubsets import CodepointsInSubset
>>> len(CodepointsInSubset('duployan', unique_glyphs=True))
155
>>> len(CodepointsInSubset('duployan', unique_glyphs=False))
386
>>> len(CodepointsInSubset('duployan', unique_glyphs=True))
386