Olli Meier
384415f573
Update Tests/ttLib/tables/_n_a_m_e_test.py
...
Co-authored-by: Just van Rossum <justvanrossum@gmail.com>
2022-02-10 21:59:39 +01:00
Olli Meier
4a0b559caf
Update Tests/ttLib/tables/_n_a_m_e_test.py
...
Co-authored-by: Just van Rossum <justvanrossum@gmail.com>
2022-02-10 21:59:29 +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
51eda21b0a
Adding more unittests, based on feedback.
2022-02-10 17:11:26 +01:00
Olli Meier
1649973800
Make use of 'Best' in names
2022-02-09 17:44:28 +01:00
Olli Meier
1a16b24cd5
Fix unittests
2022-02-09 17:17:11 +01:00
Olli Meier
c50f38ed0e
extend name table with getFamilyName, getSubFamilyName and getNiceFullName + unittests
2022-02-09 17:06:02 +01:00
Cosimo Lupo
8d6a7617a2
minor: fix 4-space indentation from PR 2441
2021-11-08 12:27:26 +00:00
Rod S
7dd3488732
Traverse when there is no layer list
2021-11-06 14:26:27 -07:00
Cosimo Lupo
e3bc036c7e
Add tests for SVG table
2021-10-13 14:53:00 +02:00
Khaled Hosny
232b2ccbc4
Move the rest of py23 module to textTools
...
Change all imports to use textTools module, except the test_py23.py test
which is kept until we decide to remove the module (if ever).
2021-08-20 01:29:45 +02:00
Cosimo Lupo
e161bbc980
Merge pull request #2384 from fonttools/newline-2021
...
Default to "\n" for newlinestr instead of None
2021-08-03 09:21:10 +01:00
Cosimo Lupo
094a40ca2e
Revert "Deprecate and ignore newlinestr"
...
This reverts commit 5af178ac8eb2da79b965be5c6cee693dad602c65.
2021-08-03 10:00:13 +02:00
Cosimo Lupo
58ac5a9fd8
have ClipList and ClipBox format start at 1, not 0
...
b7e81fcbd6
2021-08-02 19:34:30 +02:00
Khaled Hosny
5af178ac8e
Deprecate and ignore newlinestr
2021-07-30 04:31:19 +02:00
Khaled Hosny
000bf81700
Default to "\n" for newlinestr instead of None
...
If newlinestr is None, os.linesep is used, bu it is the third millennium
and we don’t need or want different line endings per-platform.
2021-07-30 04:12:33 +02:00
Cosimo Lupo
800bf85b2f
add ClipList.Format so we can bump when we finally get >16bit GIDs
...
https://github.com/googlefonts/colr-gradients-spec/issues/346
2021-07-29 15:35:08 +02:00
Cosimo Lupo
bee2c85f61
[colrv1] otData: define ClipList, ClipBox, etc.
2021-07-28 18:04:48 +02:00
Cosimo Lupo
b74ffb4cda
test roundtripping variable COLRv1 with a working VarIndexMap and VarStore
2021-07-23 17:27:57 +01:00
Cosimo Lupo
29a2ebf813
omit default VarIndexBase
...
4294967295 (0xFFFFFFFF in decimal form) is not very memorable.
Still, using hex notation for all VarIndexBases would make the non-default values less readable (when interpreted as an index into the DeltaSetIndexMap array, decimal makes more sense).
Since 0xFFFFFFFF means 'no variation data', it makes sense to omit it from the ttx dump and write an empty <VarIndexBase/> element with no value.
We also allow to build Var tables without needing to pass "VarIndexBase": 0xFFFFFFFF in the source dict.
2021-07-23 17:27:57 +01:00
Cosimo Lupo
6ba0163614
fix C_O_L_R_test.py following recent changes
2021-07-23 17:27:57 +01:00
Rod S
7225ac22a6
Update to reflect COLR v1 FWORD center and offset to transform
2021-07-06 17:47:56 +01:00
Cosimo Lupo
0e99474985
otData: reduce precision of specialized transforms, use F2Dot14 for all angles
...
https://github.com/googlefonts/colr-gradients-spec/pull/307 & https://github.com/googlefonts/colr-gradients-spec/pull/310
2021-07-06 17:47:56 +01:00
Cosimo Lupo
a0bd872f0e
TupleVariation: make shared tuples order deterministic
...
most frequent first (like before https://github.com/fonttools/fonttools/pull/2351 ), only sort ties alphabetically
2021-07-02 12:52:54 +01:00
Cosimo Lupo
d0d59d2f2c
Add PaintScale* and Paint{Rotate,Skew}* variants
...
This updates fonttools to match the latest draft COLRv1 spec at https://github.com/googlefonts/colr-gradients-spec/pull/290
Summary of changes:
- Added 8 new PaintScale* tables: with/without centers, uniform vs non-uniform
- Added *AroundCenter variants to PaintRotate and PaintSkew (default versions no longer have centerX/Y defaulting to origin)
- PaintRotate, PaintSkew and PaintComposite formats re-numbered
2021-06-28 18:38:47 +01:00
Cosimo Lupo
1cb7e36bbd
COLRv1: rename otData structs to remove 'V1' to match updated draft spec
...
This is a breaking change (but the COLRv1 API was already marked as unstable and subject to change)
The changes in this PR are meant to match the changes from the COLRv1 draft spec at:
https://github.com/googlefonts/colr-gradients-spec/pull/302
2021-06-28 16:13:47 +01:00
Cosimo Lupo
adbe4c3de7
otTables_test: mixed tabs and spaces
2021-05-20 19:22:24 +01:00
Cosimo Lupo
d1e2e0e381
otTables: ignore Format attribute in split.*Subst overflow-fixing methods
...
Fixes https://github.com/fonttools/fonttools/issues/2319
2021-05-20 19:19:37 +01:00
Eigi
20c4a3ce74
test if issue #2295 is fixed
2021-05-13 09:58:53 +01:00
Just van Rossum
d601951eab
[otTables] Default varIdx should be 0xFFFFFFFF ( #2298 )
...
* default value for varIdx should be 0xFFFFFFFF to indicate 'no variations'
* use lc hex notation as per feedback
2021-05-07 22:26:48 +02:00
Garret Rieger
1bb3183231
Add tests for lazy loading of MVAR with more than 8 value records.
2021-04-21 14:37:47 -07:00
Behdad Esfahbod
bcd4a62f10
[TupleVariation] Use b'' instead of NotImplemented for "use shared points"
2021-04-09 12:16:15 -06:00
Behdad Esfahbod
ef0d695de9
[TupleVariation] Remove unused usesSharedPoints return from tv.compile()
2021-04-09 12:13:49 -06:00
Behdad Esfahbod
f7b66c7af2
[VariationData] Fix tests after recent changes
2021-04-08 18:31:24 -06:00
Behdad Esfahbod
1e6b20cc2c
[TupleVariation] Don't round deltas (again!)
...
Remove tests that passed float in.
2021-04-08 09:41:45 -06:00
Behdad Esfahbod
e9acd9634f
[GlyphCoordinates] Store int data as 4byte, not 2byte
...
The memory increase is negligible, but means that we don't have to
worry about integer overflows anymore.
2021-04-08 09:41:45 -06: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
8f79235d00
[Tests] Remove hack after Coverage .Format removal
2021-03-23 11:44:13 -07:00
Behdad Esfahbod
d6bdfba587
[Tests] Fix more test expectations for SingleSubst .Format removal
2021-03-23 11:43:55 -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
Zachary Scheuren
0434b1a917
Add feaLib support for STAT table
2021-02-25 17:16:01 +00:00
rsheeter
7abd234929
Update tests for new formats
2021-02-15 10:42:59 +00:00
Cosimo Lupo
82c32cbf88
C_O_L_R_test: fix incorrect NumLayers
...
there's actually 3 LayerRecords defined in the COLR_V1_SAMPLE, not 4.
2021-02-05 10:36:12 +00:00