Allow duplicate non-conflicting kerning pairs
Fixes https://github.com/unified-font-object/ufoLib/pull/15#issuecomment-193552682
This commit is contained in:
parent
1867eb5a37
commit
f5ddac0e5d
@ -961,7 +961,9 @@ def kerningValidatorReportPairs(kerning, groups):
|
||||
firstOptions = groups[first]
|
||||
secondGroup = flatSecondGroups[second]
|
||||
for glyph in firstOptions:
|
||||
if (glyph, secondGroup) in kerning:
|
||||
if ((glyph, second) not in kerning and
|
||||
(glyph, secondGroup) in kerning and
|
||||
kerning[(glyph, secondGroup)] != kerning[(first, second)]):
|
||||
errors.append("%s, %s (%d) conflicts with %s, %s (%d)" % (glyph, secondGroup, kerning[glyph, secondGroup], first, second, kerning[first, second]))
|
||||
pairs.append((glyph, secondGroup))
|
||||
pairs.append((first, second))
|
||||
@ -970,7 +972,9 @@ def kerningValidatorReportPairs(kerning, groups):
|
||||
secondOptions = groups[second]
|
||||
firstGroup = flatFirstGroups[first]
|
||||
for glyph in secondOptions:
|
||||
if (firstGroup, glyph) in kerning:
|
||||
if ((first, glyph) not in kerning and
|
||||
(firstGroup, glyph) in kerning and
|
||||
kerning[(firstGroup, glyph)] != kerning[(first, second)]):
|
||||
errors.append("%s, %s (%d) conflicts with %s, %s (%d)" % (firstGroup, glyph, kerning[firstGroup, glyph], first, second, kerning[first, second]))
|
||||
pairs.append((firstGroup, glyph))
|
||||
pairs.append((first, second))
|
||||
|
Loading…
x
Reference in New Issue
Block a user