312 Commits

Author SHA1 Message Date
Behdad Esfahbod
caa353d5dd [varStore] Generate variation for Anchors and store in GDEF
Finally!  Phew...
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
cfd7bfbb2c [varLib] Start creating variations for GPOS using Merger 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
60e8bab524 [varLib] Unbreak gvar generation
Was completely broken by 15dd7181b47b8c8225b6054c6bb257fab91eea1c as master location
tags were mismatched with fvar.  Too bad gvar was silently ignoring that.  Fix coming.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
e713f75930 [varLib] Add gvar only if base font has glyf table 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
0546a4296b [varLib] Fix typo 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
ecce5cf344 [varLib] Minor 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
402d726692 [ot] Change Version to be an integer instead of float
API Change:
This will change XML output for GSUB/GPOS/GDEF/MATH/BASE/JSTF/...
Scripts that set the Version for those to 1.0 or other float values
also need fixing.  A warning is emitted when code or XML needs fix.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
ae93928275 [varLib] Rename fields in fvar, to accommodate for postscriptNameID 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
24346aaa88 [varLib] Store name entries with Windows English encoding instead of MacRoman 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
4e5145ac41 [varLib] Move code around 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
d916e18595 [varLib] Refactor main() code into build() 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
06b1840866 [varLib] Move code around 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
4fc2a3e5e1 [varLib] Move code around 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
c5ad2cb267 [varLib] Explicitly round values
It's annoying that python2's struct module doesn't err if float
is passed to it for an integer, whereas python3 does.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
3da7de7452 [varLib] Use Tag() in fvar 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
d9ee2609be [varLib] Move VariationModel and supporting code to fontTools.varLib.models
More code to be moved there in the future.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
4512a162b6 [varLib] Move designspace loading code into its own module 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
44fda3ac0b [varLib] Start OnlineVarStoreBuilder 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
a85dc19378 [varLib] Reuse base font's layout tables 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
72fe29359b [varLib] Start building Device table for variations 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
12a5c5895d [varLib] Enable building gvar again
Was dropped accidentlaly in 680059d0.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
76ce34b06c [varLib] Implement mapping tail optimization 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
687c2c1812 [varLib] Build indirect advance-width in HVAR
Fixes VarIdxMap implementation as well.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
32bd6bcc31 [varLib] Add optimizeVarData()
Though not really effective right now since we don't split into
multiple VarData sets.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
f11414c93b [varLib] Implement new VarData, aka. ItemVariationData, table 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
38c88f6996 [varLib] Rename VarTuple to VarRegion 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
e7163eddb0 [varLib] Rename VarTupleList to VarRegionList
Aka. ItemVariationRegionList.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
35a401f04d [varLib] Add support for VarIdxMap, aka. DeltaSetIndexMap.
Update HVAR / VVAR to latest draft.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
831bf051c0 [varLib] Shuffle code around 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
c1717224da [varLib] Generate direct HVAR 2016-09-27 19:49:41 +02:00
Behdad Esfahbod
e2da17e032 [opentype-gx/varLib] More work towards VariationStore
And HVAR/VVAR tables.
2016-09-27 19:49:41 +02:00
Behdad Esfahbod
9080151cd5 [varLib] Fix variations for composite glyphs using anchor points 2016-07-29 14:44:02 -07:00
Behdad Esfahbod
fc05fe74ec [varLib] Remove unused code 2016-07-29 14:40:16 -07:00
Behdad Esfahbod
0deb34829c [Snippets/interpolatable.py] Add preliminary script for detecting interpolation errors
Very basic.  Right now detects if glyphs have wrong order of contours / components.
2016-06-15 18:46:59 +04:00
Behdad Esfahbod
be27acbbd2 [varLib] Fix thinko 2016-06-10 19:49:45 -07:00
Behdad Esfahbod
b1474a3993 Minor 2016-06-07 16:21:43 -07:00
Behdad Esfahbod
c4f8cbb6a1 [varLib/mutator.py] Update hmtx lsb after updating glyf bounds 2016-06-07 15:51:54 -07:00
Behdad Esfahbod
18f70c75c5 [varLib] Add interpolation functions
Untested.
2016-05-26 13:34:37 -07:00
Cosimo Lupo
70ec8513d0 varLib: use cElementTree if available to parse designspace
The C implementation of ElementTree is included in CPython since 2.5.
It's got the same API and is up to 20 times faster than the Python implementation.
We'd better use it.
2016-04-28 09:56:21 +01:00
Behdad Esfahbod
e13f46c1dd [varLib] Add _SetCoordinates() 2016-04-27 01:30:12 -07:00
Behdad Esfahbod
ac26b33f48 [varLib] Copy coordinates before modifying 2016-04-27 00:25:31 -07:00
Behdad Esfahbod
e963a5b2c9 [varLib] Remove unused imports 2016-04-27 00:21:46 -07:00
Behdad Esfahbod
f7d390a955 [varLib] Minor refactoring, and bug fix 2016-04-27 00:15:07 -07:00
Behdad Esfahbod
c8b5b618e0 [varLib] Minor simplification 2016-04-26 23:59:39 -07:00
Behdad Esfahbod
8384c1e482 [varLib] Fix import 2016-04-18 16:48:13 -07:00
Behdad Esfahbod
2312880d79 [varLib] Assert that we found the base master 2016-04-17 11:53:20 -07:00
Behdad Esfahbod
5f953db5ee [varLib] Document module a bit 2016-04-15 13:56:37 -07:00
Behdad Esfahbod
fe7f99de16 [varLib] Simplify things a bit
This seems to be created correct fonts now.
2016-04-15 13:49:27 -07:00
Behdad Esfahbod
908d1dac47 [varLib] use operator.iadd instead of operator.add
Reduces copying.
2016-04-15 09:00:57 -07:00
Behdad Esfahbod
fd238eb2ae [varLib] Build GX variation font using all masters
Needs some fixing, but the basics are there.
2016-04-15 08:56:04 -07:00