Open madig opened 4 years ago
varLib expects that the masters to either have a GPOS table that is mergeable (same features, same number of lookups as the default) or it doesn't have one at all (in which case that sparse master is ignored). Maybe the font designer can insert a dummy kern value of 0 in the master that has empty kerning, so that ufo2ft will write a kern feature (that does nothing) for it.
The 0-value class kern pairs are currently ignored when collecting the kerning pairs from kerning.plist: https://github.com/googlefonts/ufo2ft/blob/2712e023567d6cc407bc1569da5fb3867d8fb970/Lib/ufo2ft/featureWriters/kernFeatureWriter.py#L328-L330
Maybe instead of skipping 0-value kern pairs we should write them as they are but only print a warning.
If one master of many does not have at least one non-zero pair, no
kern
feature is generated for it and varLib will fail to merge the GPOS tables due to a feature list mismatch. Example of three masters where one does not have a kerning.plist: