Khaled Hosny
0f953cccd8
[otlLib] Support building MATH table
2024-02-14 02:48:13 +02:00
Cosimo Lupo
f96b2128a1
[feaLib] keep declaration order of ligatures within ligature set
...
Fixes #3428
2024-01-24 12:59:00 +00:00
Cosimo Lupo
2c07619344
[otlLib] make ClassDefBuilder class order match varLib.mergers
...
see https://github.com/fonttools/fonttools/blob/c3d876/Lib/fontTools/misc/classifyTools.py#L77
i.e. we want (large classes first, then lexicographic order on the glyphs); previously otlLib was sorting by the _reverse_ of (small classes first, then glyphs lexicographic order) -- effectively comparing the reverse of the glyph sets of classes of the same size.
Fixes https://github.com/fonttools/fonttools/issues/3321
note the ttx dump of previously built fonts may change but there won't be any functional changes.
2023-11-02 16:36:48 +00:00
Olli Meier
86e4795405
As requested: black Tests/otlLib/builder_test.py
2022-02-11 15:58:34 +01:00
Olli Meier
3b1fac049d
Renamed unittest as requested by anthrotype
2022-02-11 15:56:03 +01:00
Olli Meier
68fa3bbd47
Cleaning code based on feedback from Just
2022-02-10 22:13:58 +01:00
Olli Meier
e968e8fd7f
Based on the discussion with Just and anthrotype: Undo the changes in the name table and extend unittests. If there are inconsistencies in the name table, it's ok to create new name IDs, even if this might not be the most efficient way of creating the name table.
2022-02-10 21:24:51 +01:00
Olli Meier
ad1d82f810
Some more changes. Not sure about this.
2022-02-10 17:56:42 +01:00
Olli Meier
51eda21b0a
Adding more unittests, based on feedback.
2022-02-10 17:11:26 +01:00
Olli Meier
6bf842a30e
Reduce unittest content and update description.
2022-02-10 16:31:17 +01:00
Olli Meier
9028a53d3b
based on feedback 'anthrotype' I use 'windowsNames' and 'macNames' in STAT table functions and 'windows' and 'mac' in name table functions.
2022-02-10 15:57:56 +01:00
Olli Meier
6014cd8ae5
based on Just Van Rossum's feedback: replace variables.
2022-02-10 15:39:51 +01:00
Olli Meier
7f21d5eee3
adding variable platforms
2022-02-10 15:14:20 +01:00
Olli Meier
0f17da0836
Bugfix: The script to create a STAt table created multiple unnecessary name table entries, because it did not take care a bout existing entries with the same name.
2022-02-10 13:44:42 +01:00
Olli Meier
62bc692da1
adding description
2022-02-10 13:09:27 +01:00
Olli Meier
01ba5394fb
Create failng unittest first.
2022-02-10 13:07:37 +01:00
David Corbett
cfa69f245f
[otlLib] Remove duplicates when building coverage
2021-11-06 13:32:43 -04:00
Behdad Esfahbod
1e83650db8
[otlLib] Ensure built SinglePos ValueRecords are padded with 0s
...
Like when they are decompiled.
Part of https://github.com/fonttools/fonttools/pull/2237
2021-03-24 09:26:26 -07:00
Behdad Esfahbod
d961ef5e52
[otlLib] Ensure built PairPos2 ValueRecords are padded with 0s
...
Like when they are decompiled.
Part of https://github.com/fonttools/fonttools/pull/2237
2021-03-24 09:26:26 -07:00
Cosimo Lupo
b1ca16738c
[otlLib] Ensure built PairPos1 ValueRecords are padded with 0s
...
Like when decompiled.
See 2089d05126 (r48578120)
Part of https://github.com/fonttools/fonttools/pull/2237
2021-03-24 09:25:42 -07:00
Nikolaus Waxweiler
30ade474dd
Update test data
2021-03-22 14:45:24 +00:00
Zachary Scheuren
0434b1a917
Add feaLib support for STAT table
2021-02-25 17:16:01 +00:00
Tom Archer
be898ec6f9
Change ValueError to OpenTypeLibError
2021-01-20 14:30:49 +00:00
Tom Archer
9712407054
Change TypeError to ValueError
2021-01-20 11:19:43 +00:00
Tom Archer
7c6337facf
Add exception and test
2021-01-19 17:57:53 +00:00
Simon Cozens
85edf0e380
Use the ChainContextualRule class instead of bare tuples
2020-07-22 14:20:50 +01:00
Simon Cozens
b6f7b2dc4b
Stylistic fixes from feedback
2020-07-11 19:54:52 +01:00
Simon Cozens
bc0f69884e
Thinko
2020-07-07 13:28:44 +01:00
Simon Cozens
9f4cc2f1cb
Introduce the concept of a ClassContextualRuleSet
...
Currently unused but will be super helpful for optimizing the formats of contextual lookups.
* Splits the rules of a class contextual lookup based on explicit subtable breaks
* Returns various properties on the ruleset to help determine appropriate layout format.
* (More properties, such as "touched glyphs", planned - will be added when needed.)
2020-07-07 12:44:25 +01:00
Simon Cozens
3b50a533d5
otlLib now sets this flag itself.
2020-07-03 12:37:22 +01:00
Just van Rossum
90c7c7fae1
Fix for #1985 : ensure that the AxisNameID in the STAT table is > 255 ( #1986 )
...
Fix for #1985 :
* ensure that the AxisNameID in the STAT table is not less than 256. This needed an additional argument to the addMultiLingualName() name table method.
* fvar axis name IDs must also not be less than 256, just like STAT axis names.
2020-06-08 19:39:28 +02:00
Just van Rossum
d6bb38c7e6
[otlLib.builder] Add function to build STAT table from high-level description ( #1926 )
...
* added a function to build a STAT table: `fontTools.otlLib.builder.buildStatTable()`
* make `varLib._add_stat()` a client of `buildStatTable()`
2020-05-09 16:08:11 +02:00
Simon Cozens
ab075a9957
Annotate LookupFlag ttx dump
2020-03-10 21:42:28 +00:00
Nikolaus Waxweiler
01328213c7
Remove __future__ imports
2019-08-09 12:20:13 +01:00
Cosimo Lupo
18f969ab7d
otlLib_test: convert to using pytest-style tests
2019-06-20 15:33:53 +01:00
Martin Hosken
27d8d1bda0
Update tests
2019-03-15 11:16:51 +07:00
Cosimo Lupo
78ad48eaf3
Move all *_test.py modules and test data to external Tests/ folder
2017-01-16 09:14:12 +00:00