googlefonts / ufo2ft

A bridge from UFOs to FontTools objects (and therefore, OTFs and TTFs).
MIT License
151 stars 43 forks source link

Add static method PostProcessor.rename_glyphs #600

Closed m4rc1e closed 2 years ago

m4rc1e commented 2 years ago

I need to rename glyphs in a ttf using a custom mapping. I don't really want to write my own function to do this since we're already doing it in this repo quite nicely.

No offence taken if this gets rejected.

anthrotype commented 2 years ago

make sure you do your renaming as first thing after loading a TTFont before loading any other table otherwise you incur in https://github.com/googlefonts/ufo2ft/issues/485

m4rc1e commented 2 years ago

Thanks for the tip!

If you're happy, I'll squash the two commits.

anthrotype commented 2 years ago

sure! LGTM

m4rc1e commented 2 years ago

hold up. I'm arse clowning here.

anthrotype commented 2 years ago

oops merged :)