10636 Commits

Author SHA1 Message Date
Behdad Esfahbod
47813b217c [varStore] Make optimize() stable
Before, calling optimize() on its own output could generate different
result. I think it's stable now.
2023-05-24 18:09:58 -06:00
Behdad Esfahbod
6b20edf1fb [varStore] Fix algorithm comment to match code 2023-05-24 17:08:20 -06:00
Behdad Esfahbod
1aa088e150 [varStore.main] Speed up if output is not requested 2023-05-24 17:05:00 -06:00
Behdad Esfahbod
2f78605c27 [varStore] Change a sort key in optimize()
Produces more optimized results in empirical testing.
2023-05-24 16:55:16 -06:00
Behdad Esfahbod
aeaf98a438 [varStore] Another fix and test 2023-05-24 16:34:15 -06:00
Behdad Esfahbod
ab510d1e7b [varStore] Add test resulting in empty varStore 2023-05-24 15:53:14 -06:00
Behdad Esfahbod
09dfed6b5e [varStore] Remove unused variable in test 2023-05-24 15:38:21 -06:00
Behdad Esfahbod
171741baf2 [varStore] Log XML when first assert fails in test 2023-05-24 15:36:06 -06:00
Behdad Esfahbod
8ae33a7ef3 [varStore] Add a round=round parameter to storeMasters 2023-05-24 14:24:36 -06:00
Behdad Esfahbod
22c76c45ff
Merge pull request #3124 from fonttools/varStore-optimize-fix
[varStore] Improve optimize algorithm
2023-05-24 21:40:47 +02:00
Behdad Esfahbod
abe2a37b6f [varStore] Add another test 2023-05-24 13:30:08 -06:00
Behdad Esfahbod
b72a8da045 [varStore] Adjust encoding overhead in optimize()
Previously we were not accounting for the LOffset to VarData.
2023-05-24 13:21:33 -06:00
Behdad Esfahbod
0677c0e705 [varStore] Another bugfix in optimize() 2023-05-24 13:18:58 -06:00
Behdad Esfahbod
e4281b07bc [varStore] Add test for optimize()
Doesn't hit all branches yet.
2023-05-24 12:51:24 -06:00
Behdad Esfahbod
cb2f5aacd3 [varStore] More documentation 2023-05-24 12:19:46 -06:00
Behdad Esfahbod
cdcbf64d36 [varStore] Document the optimize algorithm 2023-05-24 12:09:43 -06:00
Behdad Esfahbod
58954179ec [varStore] Another fix to the optimize algorithm
Previously we were disregarding the best_gain. Ouch!
2023-05-24 12:02:05 -06:00
Cosimo Lupo
55003d8039
wheels.yml: test fonttools core lib without extras when building wheels
we already run full tests suite at each push anyway. There are too many issues installing things like lxml or scipy on so many pythons/platforms/architectures, not worth the hassle
2023-05-24 18:32:12 +01:00
Behdad Esfahbod
6097b3293b [varStore] Improve optimize algorithm
This was always supposed to be how it works, but was missed in
the initial implementation apparently.
2023-05-24 11:07:19 -06:00
Cosimo Lupo
9334a9117b
wheels.yml: must tell tox where tox.ini is
because cibuildwheel insists on running the test command from a temp folder
2023-05-24 17:55:23 +01:00
Cosimo Lupo
f2bd7f7cef
wheels.yml: must redefine tox_env in matrix include items 2023-05-24 16:49:09 +01:00
Cosimo Lupo
610eeca449
requirements.txt: bump lxml to 4.9.2 2023-05-24 16:39:58 +01:00
Cosimo Lupo
20319e02f9
fix 'TypeError: lxml.etree._Attrib is not a mapping' on pypy3
https://github.com/fonttools/fonttools/actions/runs/5070601982/jobs/9105864056#step:5:3610
2023-05-24 16:39:26 +01:00
Cosimo Lupo
31cb8c0a96
define 'noextra' tox env, fold 'nolxml' into that one
and keep all pinned test dependencies inside a single requirements.txt, previously lxml was defined only inside tox.ini
2023-05-24 16:30:57 +01:00
Cosimo Lupo
d017d2b173
use pytest importorskip to skip modules that depend on extra requirements
this should allow to run the basic test suite against the dependency-less core of fonttools library
2023-05-24 16:26:48 +01:00
Cosimo Lupo
53712dcebe
Merge pull request #3121 from fonttools/binary-wheels
Add workflow config file for building native binary wheels
2023-05-24 13:52:23 +01:00
Cosimo Lupo
dab38d575f
call cibuildwheel on the current directory since we no longer run on distinct submodule directory 2023-05-24 13:51:43 +01:00
Cosimo Lupo
5260d68338
Add workflow config file for building native binary wheels
copied from https://github.com/fonttools/fonttools-wheels/blob/main/.github/workflows/ci.yml

Part of https://github.com/fonttools/fonttools/issues/3116
2023-05-24 13:44:57 +01:00
Cosimo Lupo
77a35fe16d
Merge pull request #3119 from fonttools/glyph-data-format-option
fontBuilder: add glyphDataFormat=0; error with accidentally cubic outlines
2023-05-23 14:57:37 +01:00
Cosimo Lupo
57d5da2039
rename parameter validateGlyphFormat and reword docstring as per review 2023-05-23 14:41:16 +01:00
Cosimo Lupo
469c9ad963
add option to skip glyphDataFormat check for speed
If one is certain that the glyph data has compatible format and prefers not to wait for each glyph flag to checked...
2023-05-23 13:16:02 +01:00
Cosimo Lupo
9bb3b652b0
fontBuilder_test: test error with cubics but glyf format 0 2023-05-23 12:56:09 +01:00
Cosimo Lupo
a421f9045a
fontBuilder: add glyphDataFormat=0; error with accidentally cubic outlines
Fixes #3113
2023-05-23 12:56:08 +01:00
خالد حسني (Khaled Hosny)
115275cbf4
Merge pull request #3118 from fonttools/subset-layout-order
[subset] Make sure GDEF is processed before GSUB and GPOS
2023-05-22 23:34:38 +03:00
Khaled Hosny
7089635305 [subset] Make sure GDEF is processed before GSUB and GPOS
See https://github.com/fonttools/fonttools/pull/3114#pullrequestreview-1437266522
2023-05-22 23:22:44 +03:00
خالد حسني (Khaled Hosny)
a537f97b44
Merge pull request #3114 from fonttools/subset-prune-MarkGlyphSetsDef
[subset] Prune GDEF.MarkGlyphSetsDef
2023-05-22 18:33:37 +03:00
Cosimo Lupo
c2c2cb0949
Merge pull request #3115 from fonttools/xml-reader-join-content-chunks
xmlReader: join consecutive text data that had been cut by buffered xml parser
2023-05-22 12:37:23 +01:00
Khaled Hosny
7b0e3643a0 [subset] Add test for pruning GDEF.MarkGlyphSetsDef 2023-05-22 14:30:15 +03:00
Cosimo Lupo
e8f8a6c40d xmlReader: join consecutive text data that had been cut by buffered parser
Fixes https://github.com/fonttools/fonttools/issues/2614
2023-05-22 12:22:41 +01:00
Cosimo Lupo
f7c1407703 Add test to reproduce DSIG split by XML buffered parser 2023-05-22 12:15:50 +01:00
Khaled Hosny
04975b9a14 [subset] Prune GDEF.MarkGlyphSetsDef
Remove empty sets and fixup Lookup.MarkFilteringSet to use the new
indices.
2023-05-22 13:28:50 +03:00
Behdad Esfahbod
4c24a3e328 [varLib/merger] Fix merging of SinglePos with pos=0
Fixes https://github.com/fonttools/fonttools/issues/3111
2023-05-19 18:37:15 +02:00
Simon Cozens
65bc6105f7
[feaLib] Allow empty aalt features (#3110)
* Demote "feature has not been defined" to a warning

* Rework test

* Not my black
2023-05-17 15:08:08 +01:00
خالد حسني (Khaled Hosny)
86291b6ef6
Merge pull request #3105 from fonttools/deduplicate-multiple-subst-classes
feaLib: Dedupe multiple substitutions with classes
2023-05-14 17:11:31 +03:00
David Corbett
bd00fe24f1 feaLib: Test deduped multiple substitution lookups 2023-05-14 09:35:53 -04:00
David Corbett
8b69b9412e feaLib: Dedupe multiple substitutions with classes 2023-05-13 13:24:58 -04:00
Khaled Hosny
54e70b3cef Bump version: 4.39.4 → 4.39.5.dev0 2023-05-10 18:28:22 +03:00
Khaled Hosny
4246c69e9a Release 4.39.4 2023-05-10 18:28:21 +03:00
Khaled Hosny
f430da359f Fix setuptools warning
SetuptoolsDeprecationWarning: The license_file parameter is deprecated, use license_files instead.
2023-05-10 18:25:06 +03:00
خالد حسني (Khaled Hosny)
fbb30dc6a0
Merge pull request #3104 from fonttools/multiple-subst-classes-2
feaLib: handle singleton class as a single glyph in multiple subst
2023-05-10 17:57:43 +03:00