From b63f6413cad4d244c0d38f12236fcb0577872f3b Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Wed, 15 Dec 2021 16:53:40 -0700 Subject: [PATCH] [merge] Remove _glyphsAreSame() check This was removing semantically-significant difference amongst glyphs such as two identical glyphs one in Noto Sans Tamil one in Noto Sans Grantha as in the following issue: Part of fixing https://github.com/fonttools/fonttools/issues/2475 --- Lib/fontTools/merge.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/fontTools/merge.py b/Lib/fontTools/merge.py index 362932b07..2ed2b2e4d 100644 --- a/Lib/fontTools/merge.py +++ b/Lib/fontTools/merge.py @@ -489,8 +489,8 @@ def merge(self, m, tables): for idx in (fontIdx, oldFontIdx): if glyphSets[idx] is None: glyphSets[idx] = m.fonts[idx].getGlyphSet() - if _glyphsAreSame(glyphSets[oldFontIdx], glyphSets[fontIdx], oldgid, gid): - continue + #if _glyphsAreSame(glyphSets[oldFontIdx], glyphSets[fontIdx], oldgid, gid): + # continue m.duplicateGlyphsPerFont[fontIdx][oldgid] = gid elif m.duplicateGlyphsPerFont[fontIdx][oldgid] != gid: # Char previously mapped to oldgid but oldgid is already remapped to a different