[ttGlyphSet] Copy glyph components before shifting

Fixes https://github.com/fonttools/fonttools/issues/2774
This commit is contained in:
Behdad Esfahbod 2022-08-24 13:30:09 -06:00
parent 2fcac63a74
commit 5454989987

View File

@ -153,6 +153,7 @@ def _setCoordinates(glyph, coord, glyfTable):
if glyph.isComposite():
assert len(coord) == len(glyph.components)
glyph.components = [copy(comp) for comp in glyph.components]
for p,comp in zip(coord, glyph.components):
if hasattr(comp, 'x'):
comp.x,comp.y = p