feaLib: demote warning about redefined kern pairs to debug message
https://github.com/fonttools/fonttools/issues/1147#issuecomment-421539956
This commit is contained in:
parent
0431360cf2
commit
9536541aba
@ -1515,10 +1515,9 @@ class PairPosBuilder(LookupBuilder):
|
||||
oldValue = self.glyphPairs.get(key, None)
|
||||
if oldValue is not None:
|
||||
# the Feature File spec explicitly allows specific pairs generated
|
||||
# by an 'enum' rule to be overridden by preceding single pairs;
|
||||
# we emit a warning and use the previously defined value
|
||||
# by an 'enum' rule to be overridden by preceding single pairs
|
||||
otherLoc = self.locations[key]
|
||||
log.warning(
|
||||
log.debug(
|
||||
'Already defined position for pair %s %s at %s:%d:%d; '
|
||||
'choosing the first value',
|
||||
glyph1, glyph2, otherLoc[0], otherLoc[1], otherLoc[2])
|
||||
|
@ -202,7 +202,7 @@ class BuilderTest(unittest.TestCase):
|
||||
def test_pairPos_redefinition_warning(self):
|
||||
# https://github.com/fonttools/fonttools/issues/1147
|
||||
logger = logging.getLogger("fontTools.feaLib.builder")
|
||||
with CapturingLogHandler(logger, "WARNING") as captor:
|
||||
with CapturingLogHandler(logger, "DEBUG") as captor:
|
||||
# the pair "yacute semicolon" is redefined in the enum pos
|
||||
font = self.build(
|
||||
"@Y_LC = [y yacute ydieresis];"
|
||||
|
Loading…
x
Reference in New Issue
Block a user