Closed GoogleCodeExporter closed 8 years ago
fix for getHMTX in ttfonts.py
def add_chars(char, defaultwidth):
if char > 256*256:
char = 256*256
delta = char - len(self.charWidths) + 1
if delta > 0:
self.charWidths += [defaultwidth] * delta
...
for char in glyphToChar[glyph]:
if (char != 0 and char != 65535):
w = int(round(scale*aw+0.001)) # ROUND_HALF_UP in PY3K (like php)
if (w == 0): w = 65535
if (char < 196608):
if len(self.charWidths) <= char:
add_chars(char, self.defaultWidth)
self.charWidths[char] = w
nCharWidths += 1
Original comment by romiq...@gmail.com
on 26 Feb 2015 at 6:59
fixed in default branch
Original comment by romiq...@gmail.com
on 27 Feb 2015 at 9:37
Original issue reported on code.google.com by
romiq...@gmail.com
on 26 Feb 2015 at 6:58