behave nicely when the font doesn't do an initial moveto.
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@170 4cde692c-a291-49d1-8350-778aa11640f8
This commit is contained in:
parent
8c74f4639a
commit
239498a496
@ -400,6 +400,11 @@ class T2OutlineExtractor(SimpleT2Decompiler):
|
||||
def appendPoint(self, point, isPrimary):
|
||||
import Numeric
|
||||
point = self.currentPoint + Numeric.array(point, Numeric.Int16)
|
||||
if not self.contours:
|
||||
# The glyph doesn't start with a moveto. Not sure whether
|
||||
# this is legal, but apparently it usually works.
|
||||
self.newPath()
|
||||
self.appendPoint(self.currentPoint, 1)
|
||||
self.currentPoint = point
|
||||
points, flags, isClosed = self.contours[-1]
|
||||
points.append(point)
|
||||
|
Loading…
x
Reference in New Issue
Block a user