bennyboer / thaw

Hierarchical organizable and versionable document tool with export to PDF
MIT License
4 stars 1 forks source link

Support getting kerning information from the GPOS Table #52

Closed bennyboer closed 4 years ago

bennyboer commented 4 years ago

Currently we only support getting kerning from the KERN table of font files. Unfortunately a lot of fonts only contain the GPOS table and not the KERN table. Thus we need to support the GPOS table as well.

bennyboer commented 4 years ago

With FontBox we can use ttf.getTableBytes(ttf.getTable("GPOS")) to get the GPOS table bytes and then we have to parse it ourselves.

bennyboer commented 4 years ago

We might also include Apache FOP and read the font via FOP to get the kerning

bennyboer commented 4 years ago

Parsed the GPOS table (only pair positioning information) by ourselves without using another library.