Addressing Byte Alignment Issues in fontTools When Creating TrueType Fonts

Kazunari Tsuboi
Posts: 18
Is it possible to add padding to the 'glyf' using the current version of fontTools? I have managed to retrieve and manipulate data using the 'compile' method of the Glyph class, but had to give up due to the absence of a 'decompile' method. Could I be overlooking something?
I am attempting to use fontTools to create a font with a 'loca' table in the Short version structure. During this process, I have noticed that the 'glyf' data, once compiled by fontTools, does not adhere to a 2-byte boundary. I have also referenced an Issue that discusses this aspect: https://github.com/fonttools/fonttools/issues/203.
My aim is to create TrueType fonts that are easily manageable with Type 42 Embedded fonts. The Adobe document 5012.Type42_Spec.pdf, section 4.2, specifies that PostScript strings must align to 4 bytes and begin on a font table boundary, or for glyph data, they should align to 2 bytes and start on a glyph boundary.
Any suggestions or best practices would be greatly appreciated.
Tagged:
0
Categories
- All Categories
- 46 Introductions
- 3.8K Typeface Design
- 476 Type Design Critiques
- 555 Type Design Software
- 1.1K Type Design Technique & Theory
- 640 Type Business
- 830 Font Technology
- 29 Punchcutting
- 507 Typography
- 120 Type Education
- 313 Type History
- 74 Type Resources
- 109 Lettering and Calligraphy
- 30 Lettering Critiques
- 79 Lettering Technique & Theory
- 529 Announcements
- 84 Events
- 110 Job Postings
- 165 Type Releases
- 169 Miscellaneous News
- 274 About TypeDrawers
- 54 TypeDrawers Announcements
- 118 Suggestions and Bug Reports