Expand CFF Index tables
This commit is contained in:
parent
112d17e49b
commit
aa736d8a7b
@ -5,6 +5,8 @@ pygtk.require('2.0')
|
|||||||
import gtk
|
import gtk
|
||||||
|
|
||||||
import fontTools.ttx
|
import fontTools.ttx
|
||||||
|
import fontTools.ttLib
|
||||||
|
import fontTools.cffLib
|
||||||
|
|
||||||
class FontTreeStoreBuilder:
|
class FontTreeStoreBuilder:
|
||||||
|
|
||||||
@ -17,9 +19,13 @@ class FontTreeStoreBuilder:
|
|||||||
getattr(value, "asdf")
|
getattr(value, "asdf")
|
||||||
except AttributeError:
|
except AttributeError:
|
||||||
pass
|
pass
|
||||||
if value.__class__ == fontTools.ttLib.getTableModule('glyf').Glyph:
|
if isinstance(value, fontTools.ttLib.getTableModule('glyf').Glyph):
|
||||||
# Glyph type needs explicit expanding to be useful
|
# Glyph type needs explicit expanding to be useful
|
||||||
value.expand(self.font['glyf'])
|
value.expand(self.font['glyf'])
|
||||||
|
if isinstance(value, fontTools.cffLib.Index):
|
||||||
|
# Load all items
|
||||||
|
for i in range(len(value)):
|
||||||
|
value[i]
|
||||||
|
|
||||||
item = self.ts.append(parent, [key, '%s' % value.__class__.__name__])
|
item = self.ts.append(parent, [key, '%s' % value.__class__.__name__])
|
||||||
for k,v in sorted(value.__dict__.items()):
|
for k,v in sorted(value.__dict__.items()):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user