Ensure sbix's Glyph.referenceGlyphName is set
This commit is contained in:
parent
68ab25b88a
commit
c1509a30c4
@ -133,9 +133,9 @@ class Glyph(object):
|
|||||||
# glyph is a "dupe", i.e. a reference to another glyph's image data.
|
# glyph is a "dupe", i.e. a reference to another glyph's image data.
|
||||||
# in this case imageData contains the glyph id of the reference glyph
|
# in this case imageData contains the glyph id of the reference glyph
|
||||||
# get glyph id from glyphname
|
# get glyph id from glyphname
|
||||||
self.imageData = struct.pack(
|
glyphname = safeEval("'''" + attrs["glyphname"] + "'''")
|
||||||
">H", ttFont.getGlyphID(safeEval("'''" + attrs["glyphname"] + "'''"))
|
self.imageData = struct.pack(">H", ttFont.getGlyphID(glyphname))
|
||||||
)
|
self.referenceGlyphName = glyphname
|
||||||
elif name == "hexdata":
|
elif name == "hexdata":
|
||||||
self.imageData = readHex(content)
|
self.imageData = readHex(content)
|
||||||
else:
|
else:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user