i = _fontforge.open(input_file)
o = _fontforge.font()
mappings = []
+ copy_space = False
for ((istart,istop),(ostart,ostop)) in zip(ranges, targets):
i.selection.select(('ranges',), istart, istop)
i.copy()
o.selection.select(('ranges',), ostart, ostop)
o.paste()
mappings.append((istart,istop,ostart,ostop))
+ if istart <= 0x20 and istop >= 20:
+ copy_space = True # HACK: FF doesn't like spaces?
+ if copy_space:
+ i.selection.select('space')
+ i.copy()
+ o.selection.select('space')
+ o.paste()
for attr in ['comment', 'copyright', 'encoding', 'familyname',
'fontname', 'fullname', 'sfntRevision', 'sfnt_names',
'userdata', 'version', 'woffMetadata']: