How to add a new glyph to a font with FontTools?
![roipoussiere](https://secure.gravatar.com/avatar/ce0ee5185c3b715e1dc4865420132352/?default=https%3A%2F%2Fvanillicon.com%2Ff062a81a8e951cc262c9c12c1563835b_200.png&rating=g&size=200)
roipoussiere
Posts: 5
I'm trying to add a new glyph to a font. I managed to draw by glyph to a pen, then saved it to a glyph object with:
new_glyph = pen.glyph()Now I would like to do something like:
font.getGlyphSet()["e_m"] = new_glyphor (with a ttf font):
font["glyf"]["e_m"] = new_glyph
How to add a new glyph to a font with FontTools?
Thank you!
Tagged:
0
Comments
-
For anyone interested, the solution was to:1. create a new UFO;2. add the glyph to this UFO;3. compile this UFO to a font of the same type of the source font;4. merge the two fonts with fonttools.merge.1
Categories
- All Categories
- 43 Introductions
- 3.7K Typeface Design
- 810 Font Technology
- 1.1K Technique and Theory
- 625 Type Business
- 449 Type Design Critiques
- 546 Type Design Software
- 30 Punchcutting
- 137 Lettering and Calligraphy
- 84 Technique and Theory
- 53 Lettering Critiques
- 491 Typography
- 305 History of Typography
- 115 Education
- 71 Resources
- 503 Announcements
- 81 Events
- 106 Job Postings
- 150 Type Releases
- 165 Miscellaneous News
- 271 About TypeDrawers
- 53 TypeDrawers Announcements
- 117 Suggestions and Bug Reports