277 Commits

Author SHA1 Message Date
justvanrossum
2636325844 font placeholder doesn't need an fvar table 2021-05-04 19:29:39 +02:00
justvanrossum
d3fd46e3f3 uncomment failing tests 2021-05-04 18:21:37 +02:00
justvanrossum
ad438931e4 adding compile/decompile step; this currently fails for the 32-bit tests (which are therefore commented out) 2021-05-04 17:08:27 +02:00
justvanrossum
267ab2baba add 32-bit master value tests 2021-05-04 16:39:20 +02:00
justvanrossum
22dda54616 use optimizer 2021-05-04 16:19:48 +02:00
justvanrossum
7de2f347c5 add tests for OnlineVarStoreBuilder/VarStoreInstancer 2021-05-04 16:12:24 +02:00
justvanrossum
a7fd202952 add 32-bit tests to test_buildVarData_optimize 2021-05-04 14:49:12 +02:00
justvanrossum
eba058d439 add 32-bit tests to test_buildVarData_no_optimize 2021-05-04 14:41:01 +02:00
Zachary Scheuren
41da60f130 Add missing dict operators to CFF2 2021-03-30 21:24:14 +09:00
Just van Rossum
5fc65d7168
Misc py23 cleanups (#2243)
* Replaced all from ...py23 import * with explicit name imports, or removed completely when possible.
* Replaced tounicode() with tostr()
* Changed all BytesIO ans StringIO imports to from io import ..., replaced all UnicodeIO with StringIO.
* Replaced all unichr() with chr()
* Misc minor tweaks and fixes
2021-03-29 11:45:58 +02:00
Behdad Esfahbod
2a483f9856 [Tests] Fix most test expectations for AlternateSubst .Format removal 2021-03-23 18:01:32 -07:00
Behdad Esfahbod
6b2b2f4949 [Tests] Fix most test expectations for ClassDef[12] .Format removal 2021-03-23 11:43:46 -07:00
Behdad Esfahbod
9ac1f39045 [Tests] Fix most test expectations for AlternateSubst .Format removal 2021-03-23 11:43:22 -07:00
Behdad Esfahbod
b62170e86d [Tests] Fix most tests expectations for LigatureSubst .Format change 2021-03-23 11:43:15 -07:00
Behdad Esfahbod
61b06a7fe0 [Tests] Fix most tests expectations for SingleSubst .Format change 2021-03-23 11:43:03 -07:00
Behdad Esfahbod
de81aae164 [Tests] Fix more tests expectations for Coverage/ClassDef .Format change 2021-03-23 11:42:54 -07:00
Behdad Esfahbod
975f85ed72 [Tests] Fix most tests expectations for Coverage/ClassDef .Format change 2021-03-23 11:42:38 -07:00
Simon Cozens
23cb8b989b More tests 2021-03-18 21:24:13 +00:00
Simon Cozens
8a6e3087ce Use pytest exception handling 2021-03-17 11:55:51 +00:00
Simon Cozens
0a1aa19c39 Test for better error message 2021-03-15 13:12:11 +00:00
Behdad Esfahbod
ed6164a44f [varLib.cff] Round deltas using bankers round as well
See https://github.com/fonttools/fonttools/pull/2214#issuecomment-790742479

Good news: this reverted the one CFF test that needed its expectation to
change when I started this patchset. Bad news: it introduced a couple other
diffs to the same glyph of the same test, which is consistent with changing
the rounding from otRound to round3.
2021-03-04 13:10:01 -07:00
Behdad Esfahbod
68004b8fec [varLib] Shift most (all?) delta-rounding to VarModel
Reduces error.

The main varfont-builder now asks the model to do rounding, and asks
VariationStore to do no rounding, so we don't spend extra times rounding
multiple times (specially with the heavy otRound).

I *think* I got it all and right...

Fixes https://github.com/fonttools/fonttools/issues/2213
2021-03-04 09:20:43 -07:00
Marc Foley
52fec53d20
Drop nameID 25 if instantiating a static font 2021-02-26 10:32:38 +00:00
Marc Foley
a7913ef50e
Add test for Regular fallback 2021-02-26 10:32:38 +00:00
Cosimo Lupo
2be13d50ac
make instancer into a package dir and move all names-related funcs to submodule
move instancer tests to Tests/varLib/instancer directory

create instancer/__main__.py to make package executable
2021-02-26 10:31:30 +00:00
Marc Foley
0280eb36cc Parametrize updateNameTable tests 2021-02-26 10:19:43 +00:00
Marc Foley
336e7827e7 Implement Cosimo feedback 2021-02-26 10:19:43 +00:00
Marc Foley
29e4ff987c instancer: implement Cosimo feedback 2021-02-26 10:19:43 +00:00
Marc Foley
0bcbbfdbb5 instancer: reuse existing instantiateSTAT func 2021-02-26 10:19:43 +00:00
Marc Foley
9a72311d19 instancer: refactor updateNameTable 2021-02-26 10:19:43 +00:00
Marc Foley
b328475072 wip instancer: update uniqueID 2021-02-26 10:19:43 +00:00
Marc Foley
ce1d8a9955 instancer: Add axisDefaults to axisLimits 2021-02-26 10:19:43 +00:00
Marc Foley
69c8667982 instancer: sort axisValues so format 4 are dominant for constructing names 2021-02-26 10:19:43 +00:00
Marc Foley
b4b1ce3579 instancer: include attribute axisValues 2021-02-26 10:19:42 +00:00
Marc Foley
f89c01d2d7 instancer: only updateNames if axisValue with specified coord exists 2021-02-26 10:19:42 +00:00
Marc Foley
78f6c2ae75 instancer: add test for partial instance name 2021-02-26 10:19:42 +00:00
Marc Foley
b502471a08 wip instancer: support format 4 axisvalues 2021-02-26 10:19:42 +00:00
Marc Foley
b95607513c WIP instancer: update static font nametable 2021-02-26 10:19:42 +00:00
Zachary Scheuren
0434b1a917
Add feaLib support for STAT table 2021-02-25 17:16:01 +00:00
Cosimo Lupo
ae07ce6e55
Merge pull request #2100 from fonttools/switch-to-gha
Switch to GitHub Actions
2020-11-20 11:03:54 +00:00
Cosimo Lupo
685b047565 varLib_test: fix failing windows tests
os.path.relpath requires that src and dst be on the same mount drive; GH Actions windows runner create the temporary directory on a different drive than the one where the source is cloned.
2020-11-20 10:06:58 +00:00
Simon Cozens
3e964ad8da
Merge pull request #2101 from simoncozens/alternate-contextual-representations
[otlLib] Build format 1 and format 2 contextual lookups
2020-11-18 07:34:04 -08:00
Simon Cozens
47d95c5e30 Fix varLib test expectations 2020-11-17 12:19:35 +00:00
Just van Rossum
b992e28374
[varLib] Add designspace lib key for custom feavar feature tag (#2080)
* Add designspace lib key to specify a custom feature tag for feature variations, as discussed in #2079

* Added comment for the lib key

* if the lib key is present, the 'processing' flag should be ignored completely
2020-10-08 14:21:42 +02:00
Cosimo Lupo
e16cf0f8b8
instancer_test: check GSUB.FeatureVariations set to None is skipped
and doesn't raise TypeError exception.
2020-10-05 18:59:21 +01:00
Cosimo Lupo
1329c8f7db
instancer_test: add tests for --remove-overlaps on generated VF instance 2020-09-29 19:38:17 +01:00
Simon Cozens
6d4c5fe31c Rename GPOS8->GPOS7 2020-07-07 13:35:33 +01:00
Simon Cozens
4adea942cc Fix varlib test expectations - now badly named. 2020-07-07 13:33:32 +01:00
Cosimo Lupo
7ca42f6623
Merge pull request #1967 from anthrotype/pickle
sfnt: add __getstate__ and __setstate__ to SFNTReader to make it pickelable
2020-05-19 14:03:52 +01:00
Cosimo Lupo
cbe84da8c3
varLib_test: comment why font.close() is needed 2020-05-19 10:57:09 +01:00