Replies: 2 comments 1 reply
-
I see now that I can simply add the instructions with etree:
I'll do it this way unless someone can suggest a better (easier or more efficient) way of doing it. |
Beta Was this translation helpful? Give feedback.
0 replies
-
You'd be much beter off using a higher level libary such as ufoLib2. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'd like to add TT instructions to a glif in a ufo using ufoLib. As far as I can see (so far), the way to do this is to get a glyphSet, get the contents of the glif with glyphSet.readGlyph() (supplying an instance of a very simple glyph object class), add the TrueType code to the lib, and use writeGlyph to put everything back:
My problem is where I've left the ellipses above. To avoid losing the outline data, I've got to supply a pointPen instance for readGlyph and a function that takes a pointPen as a parameter for writeGlyph. But the fontTools docs are vague about what goes into that function ("it has to call the proper PointPen methods to transfer the outline to the .glif file"). I can't figure out what that function should look like.
So here are my questions:
I'll be grateful for any guidance.
Beta Was this translation helpful? Give feedback.
All reactions