Open typemytype opened 7 years ago
i'm not sure what to do with this. @typemytype please send a patch when you get to it, thanks.
When save it back to UFO2 the new (UFO3)groups are there
hm that's strange. If you set formatVersion=2, and call the writer.setKerningGroupConversionRenameMaps
method with the same conversion mapping that you got from the reader.getKerningGroupConversionRenameMaps
, then the writer should restore the old kerning group names, unless I'm missing something.
There's even a test for that:
https://github.com/unified-font-object/ufoLib/blob/b84eb25a50ef86e2236568f7941a8c5f11e40c56/tests/test_UFOConversion.py#L240-L347
Converting UFO2 to UFO3 goes fine. When save it back to UFO2 the new (UFO3)groups are there and cause issues while reopening/reconverting the UFO back to UFO3, cause both old and new groups are available. This should not happen, a simple check on the glyphList should be enough to determine if the group should have an additional prefix number.
https://github.com/unified-font-object/ufoLib/blob/master/Lib/ufoLib/converters.py#L37