fontkit
fontkit copied to clipboard
Fix version types
The version readings in the hhea and vhea tables are currently not appropriate. https://docs.microsoft.com/en-us/typography/opentype/spec/hhea https://docs.microsoft.com/en-us/typography/opentype/spec/vhea
According to these, there are two versions in hhea, major and minor. They are both uint16, so the current single int32 version did not cause any problems.
In vhea, however, there is one version, and it seems to be uint32, not uint16. Currently, this causes a two-byte gap, and numberOfMetrics will always return zero. And it's also causing problems with reading the vmtx table.