Fix GlyphCoordinates
It's embarrassing that I failed to test ttx completely. https://github.com/behdad/fonttools/issues/4
This commit is contained in:
parent
583ce6356d
commit
71d76fa1b8
@ -281,7 +281,7 @@ class Glyph:
|
||||
if self.numberOfContours < 0:
|
||||
raise ttLib.TTLibError, "can't mix composites and contours in glyph"
|
||||
self.numberOfContours = self.numberOfContours + 1
|
||||
coordinates = GlyphCoords()
|
||||
coordinates = GlyphCoordinates()
|
||||
flags = []
|
||||
for element in content:
|
||||
if type(element) <> TupleType:
|
||||
@ -784,7 +784,7 @@ class GlyphCoordinates:
|
||||
|
||||
@staticmethod
|
||||
def zeros(count):
|
||||
return GlyphCoordinates([(0,0)] * count)
|
||||
return GlyphCoordinates([0,0] * count)
|
||||
|
||||
def copy(self):
|
||||
c = GlyphCoordinates()
|
||||
@ -811,7 +811,7 @@ class GlyphCoordinates:
|
||||
return 'GlyphCoordinates(['+','.join(str(c) for c in self)+'])'
|
||||
|
||||
def append(self, (x,y)):
|
||||
self._a.append((x,y))
|
||||
self._a.extend((x,y))
|
||||
|
||||
def extend(self, iterable):
|
||||
for x,y in iterable:
|
||||
|
Loading…
x
Reference in New Issue
Block a user