Revert "Revert "t2CharStringPen: specializeCommands expects command args to be list, not tuples""

This reverts commit fe2e897d13aab383d03b7759a15787ed2db99c77.

ufo2ft tests are failing with fonttools master with this error:

fontTools/cffLib/specializer.py:497:
>   commands[i-1] = (new_op, args1+args2)
    TypeError: can only concatenate list (not "tuple") to list
This commit is contained in:
Cosimo Lupo 2018-02-20 17:35:10 +00:00
parent 323783d41c
commit 2cc182ce58
No known key found for this signature in database
GPG Key ID: 59D54DB0C9976482

View File

@ -54,7 +54,7 @@ class T2CharStringPen(BasePen):
def _p(self, pt):
p0 = self._p0
pt = self._p0 = self.roundPoint(pt)
return (pt[0]-p0[0], pt[1]-p0[1])
return [pt[0]-p0[0], pt[1]-p0[1]]
def _moveTo(self, pt):
self._commands.append(('rmoveto', self._p(pt)))