mirror of
https://github.com/belluzj/fantasque-sans.git
synced 2024-12-22 07:21:31 +01:00
Merge pull request #142 from d125q/master
Make build scripts compatible with Python 3
This commit is contained in:
commit
996150820b
|
@ -2,6 +2,8 @@
|
||||||
#
|
#
|
||||||
# Adapted from https://github.com/tonsky/FiraCode/blob/master/gen_calt.clj
|
# Adapted from https://github.com/tonsky/FiraCode/blob/master/gen_calt.clj
|
||||||
|
|
||||||
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from textwrap import dedent
|
from textwrap import dedent
|
||||||
from collections import defaultdict
|
from collections import defaultdict
|
||||||
import tempfile
|
import tempfile
|
||||||
|
@ -33,7 +35,7 @@ def update_features(font):
|
||||||
# Add the dummy "LIG" glyph
|
# Add the dummy "LIG" glyph
|
||||||
lig = font.createChar(-1, 'LIG')
|
lig = font.createChar(-1, 'LIG')
|
||||||
lig.width = font['space'].width
|
lig.width = font['space'].width
|
||||||
with tempfile.NamedTemporaryFile(suffix='.fea') as f:
|
with tempfile.NamedTemporaryFile(mode='w', suffix='.fea') as f:
|
||||||
f.write(fea_code)
|
f.write(fea_code)
|
||||||
f.seek(0)
|
f.seek(0)
|
||||||
font.mergeFeature(f.name)
|
font.mergeFeature(f.name)
|
||||||
|
|
|
@ -3,6 +3,8 @@
|
||||||
# LICENSE: MIT
|
# LICENSE: MIT
|
||||||
# vim: sts=4 sw=4 ts=4 et
|
# vim: sts=4 sw=4 ts=4 et
|
||||||
|
|
||||||
|
from past.builtins import xrange
|
||||||
|
|
||||||
import fontforge
|
import fontforge
|
||||||
from itertools import compress
|
from itertools import compress
|
||||||
import os
|
import os
|
||||||
|
|
Loading…
Reference in New Issue
Block a user