fonttools 4.57.0__cp311-cp311-macosx_10_9_universal2.whl → 4.58.0__cp311-cp311-macosx_10_9_universal2.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of fonttools might be problematic. Click here for more details.
- fontTools/__init__.py +1 -1
- fontTools/cffLib/__init__.py +61 -26
- fontTools/cu2qu/cu2qu.c +4564 -4048
- fontTools/cu2qu/cu2qu.cpython-311-darwin.so +0 -0
- fontTools/designspaceLib/statNames.py +14 -7
- fontTools/feaLib/ast.py +84 -10
- fontTools/feaLib/builder.py +20 -4
- fontTools/feaLib/lexer.c +6266 -7109
- fontTools/feaLib/lexer.cpython-311-darwin.so +0 -0
- fontTools/feaLib/parser.py +1 -39
- fontTools/fontBuilder.py +6 -0
- fontTools/misc/bezierTools.c +13476 -15371
- fontTools/misc/bezierTools.cpython-311-darwin.so +0 -0
- fontTools/misc/etree.py +4 -27
- fontTools/mtiLib/__init__.py +0 -2
- fontTools/otlLib/builder.py +195 -145
- fontTools/otlLib/optimize/gpos.py +42 -62
- fontTools/pens/momentsPen.c +4490 -4672
- fontTools/pens/momentsPen.cpython-311-darwin.so +0 -0
- fontTools/pens/pointPen.py +21 -12
- fontTools/qu2cu/qu2cu.c +5725 -5456
- fontTools/qu2cu/qu2cu.cpython-311-darwin.so +0 -0
- fontTools/subset/__init__.py +11 -0
- fontTools/ttLib/tables/G_V_A_R_.py +5 -0
- fontTools/ttLib/tables/T_S_I__0.py +14 -3
- fontTools/ttLib/tables/T_S_I__5.py +16 -5
- fontTools/ttLib/tables/__init__.py +1 -0
- fontTools/ttLib/tables/_c_v_t.py +2 -0
- fontTools/ttLib/tables/_f_p_g_m.py +3 -1
- fontTools/ttLib/tables/_g_l_y_f.py +2 -6
- fontTools/ttLib/tables/_g_v_a_r.py +58 -15
- fontTools/ttLib/tables/_p_o_s_t.py +5 -2
- fontTools/ttLib/tables/otBase.py +1 -0
- fontTools/ufoLib/__init__.py +2 -2
- fontTools/ufoLib/converters.py +89 -25
- fontTools/ufoLib/errors.py +8 -0
- fontTools/ufoLib/etree.py +1 -1
- fontTools/ufoLib/filenames.py +155 -100
- fontTools/ufoLib/glifLib.py +9 -2
- fontTools/ufoLib/kerning.py +66 -36
- fontTools/ufoLib/utils.py +5 -2
- fontTools/unicodedata/Mirrored.py +446 -0
- fontTools/unicodedata/__init__.py +6 -2
- fontTools/varLib/__init__.py +2 -0
- fontTools/varLib/iup.c +6838 -6362
- fontTools/varLib/iup.cpython-311-darwin.so +0 -0
- fontTools/voltLib/__main__.py +206 -0
- fontTools/voltLib/ast.py +4 -0
- fontTools/voltLib/parser.py +16 -8
- fontTools/voltLib/voltToFea.py +347 -166
- {fonttools-4.57.0.dist-info → fonttools-4.58.0.dist-info}/METADATA +45 -11
- {fonttools-4.57.0.dist-info → fonttools-4.58.0.dist-info}/RECORD +58 -54
- {fonttools-4.57.0.dist-info → fonttools-4.58.0.dist-info}/WHEEL +1 -1
- fonttools-4.58.0.dist-info/licenses/LICENSE.external +359 -0
- {fonttools-4.57.0.data → fonttools-4.58.0.data}/data/share/man/man1/ttx.1 +0 -0
- {fonttools-4.57.0.dist-info → fonttools-4.58.0.dist-info}/entry_points.txt +0 -0
- {fonttools-4.57.0.dist-info → fonttools-4.58.0.dist-info}/licenses/LICENSE +0 -0
- {fonttools-4.57.0.dist-info → fonttools-4.58.0.dist-info}/top_level.txt +0 -0
|
Binary file
|
fontTools/feaLib/parser.py
CHANGED
|
@@ -1613,7 +1613,7 @@ class Parser(object):
|
|
|
1613
1613
|
"HorizAxis.BaseScriptList",
|
|
1614
1614
|
"VertAxis.BaseScriptList",
|
|
1615
1615
|
), self.cur_token_
|
|
1616
|
-
scripts = [
|
|
1616
|
+
scripts = [self.parse_base_script_record_(count)]
|
|
1617
1617
|
while self.next_token_ == ",":
|
|
1618
1618
|
self.expect_symbol_(",")
|
|
1619
1619
|
scripts.append(self.parse_base_script_record_(count))
|
|
@@ -2062,44 +2062,6 @@ class Parser(object):
|
|
|
2062
2062
|
)
|
|
2063
2063
|
self.expect_symbol_(";")
|
|
2064
2064
|
|
|
2065
|
-
# A multiple substitution may have a single destination, in which case
|
|
2066
|
-
# it will look just like a single substitution. So if there are both
|
|
2067
|
-
# multiple and single substitutions, upgrade all the single ones to
|
|
2068
|
-
# multiple substitutions.
|
|
2069
|
-
|
|
2070
|
-
# Check if we have a mix of non-contextual singles and multiples.
|
|
2071
|
-
has_single = False
|
|
2072
|
-
has_multiple = False
|
|
2073
|
-
for s in statements:
|
|
2074
|
-
if isinstance(s, self.ast.SingleSubstStatement):
|
|
2075
|
-
has_single = not any([s.prefix, s.suffix, s.forceChain])
|
|
2076
|
-
elif isinstance(s, self.ast.MultipleSubstStatement):
|
|
2077
|
-
has_multiple = not any([s.prefix, s.suffix, s.forceChain])
|
|
2078
|
-
|
|
2079
|
-
# Upgrade all single substitutions to multiple substitutions.
|
|
2080
|
-
if has_single and has_multiple:
|
|
2081
|
-
statements = []
|
|
2082
|
-
for s in block.statements:
|
|
2083
|
-
if isinstance(s, self.ast.SingleSubstStatement):
|
|
2084
|
-
glyphs = s.glyphs[0].glyphSet()
|
|
2085
|
-
replacements = s.replacements[0].glyphSet()
|
|
2086
|
-
if len(replacements) == 1:
|
|
2087
|
-
replacements *= len(glyphs)
|
|
2088
|
-
for i, glyph in enumerate(glyphs):
|
|
2089
|
-
statements.append(
|
|
2090
|
-
self.ast.MultipleSubstStatement(
|
|
2091
|
-
s.prefix,
|
|
2092
|
-
glyph,
|
|
2093
|
-
s.suffix,
|
|
2094
|
-
[replacements[i]],
|
|
2095
|
-
s.forceChain,
|
|
2096
|
-
location=s.location,
|
|
2097
|
-
)
|
|
2098
|
-
)
|
|
2099
|
-
else:
|
|
2100
|
-
statements.append(s)
|
|
2101
|
-
block.statements = statements
|
|
2102
|
-
|
|
2103
2065
|
def is_cur_keyword_(self, k):
|
|
2104
2066
|
if self.cur_token_type_ is Lexer.NAME:
|
|
2105
2067
|
if isinstance(k, type("")): # basestring is gone in Python3
|
fontTools/fontBuilder.py
CHANGED
|
@@ -714,6 +714,12 @@ class FontBuilder(object):
|
|
|
714
714
|
gvar.reserved = 0
|
|
715
715
|
gvar.variations = variations
|
|
716
716
|
|
|
717
|
+
def setupGVAR(self, variations):
|
|
718
|
+
gvar = self.font["GVAR"] = newTable("GVAR")
|
|
719
|
+
gvar.version = 1
|
|
720
|
+
gvar.reserved = 0
|
|
721
|
+
gvar.variations = variations
|
|
722
|
+
|
|
717
723
|
def calcGlyphBounds(self):
|
|
718
724
|
"""Calculate the bounding boxes of all glyphs in the `glyf` table.
|
|
719
725
|
This is usually not called explicitly by client code.
|