be relaxed about zero padding the input data to 4-byte boundaries
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@87 4cde692c-a291-49d1-8350-778aa11640f8
This commit is contained in:
parent
222aea7fca
commit
7268e24408
@ -33,7 +33,10 @@ class table__h_e_a_d(DefaultTable.DefaultTable):
|
||||
dependencies = ['maxp', 'loca']
|
||||
|
||||
def decompile(self, data, ttFont):
|
||||
sstruct.unpack(headFormat, data, self)
|
||||
dummy, rest = sstruct.unpack2(headFormat, data, self)
|
||||
if rest:
|
||||
# this is quite illegal, but there seem to be fonts out there that do this
|
||||
assert rest == "\0\0"
|
||||
self.unitsPerEm = int(self.unitsPerEm)
|
||||
self.strings2dates()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user