Open ollimeier opened 1 year ago
opentype.js currently only supports writing in CFF format, and even that doesn't support all features yet. I think it's very unlikely the library will ever implement TTF format in writing for a variety of reasons, but of course that's open for discussion and if someone came along with a PR implementing a format switch for reading/storing the data and writing, it wouldn't be rejected. But right now, there are too many other features to tackle.
Expected Behavior
When loading a TTF font I would expect to have truetype tables in the font object. But in fact, I get CFF data.
Current Behavior
Any TTF will be converted into CFF data, eg. there is no glyf table in 'tables'.
Possible Solution
When loading a TTF -> no changes to the actual data.
Steps to Reproduce (for bugs)
for example:
Context
I tried to open a TTF file and change only one value in the OS/2 table and save it again. But when I saved the font, it's messed up totally. Many changes have been made automatically and even outlines have been converted to CFF.
Your Environment