[HarfBuzz] Need to read family name (nameID/fontTools/TTX related)
Rolf Langenhuijzen
rolf.langenhuijzen at xs4all.nl
Fri Oct 3 17:11:07 PDT 2014
Hello,
Sorry to hijack the Harfbuzz list for this, I think this is more fontTools/TTX related, but I didn’t see an (active?) TTX list to post this to…
Basically I’d like to read the name table in a Python script. I thought this could be done rather easy with fontTools/TTX, but no idea really. Any pointers??
I came across this https://github.com/tchollingsworth/ttname which is basically what I need, however I don’t need write stuff and basically only need to read the name table. I started forking it, but then noticed it depends on some older fontTools version, looking at how it wants to use the XML reader (import fontTools.ttLib.xmlImport).
So if this is a good start I would dive into that XML reading/parsing and perhaps update ttname if it’s worth it..
As I was looking for the Family Name in particular I’m now running a subprocess.Popen to “otfinfo --family" grabbing that information ;)
It’s a bit dirty, but for prototyping it works..
Kind regards,
Rolf
More information about the HarfBuzz
mailing list