1850 Commits

Author SHA1 Message Date
Behdad Esfahbod
4e13a2268e [otlLib] One more rename 2016-01-22 19:38:20 +01:00
Behdad Esfahbod
aea0ce9ae1 [otlLib] Adapt names to newly agreed scheme 2016-01-22 19:32:45 +01:00
Behdad Esfahbod
564af5a65c [otlLib] Return None if coverage is empty 2016-01-22 19:27:33 +01:00
Behdad Esfahbod
577a1500e5 [mtiLib] Cosmetic 2016-01-22 19:25:14 +01:00
Behdad Esfahbod
f63f23e4bd [mtiLib] Port to otlLib.buildLigCaretList() 2016-01-22 19:24:05 +01:00
Behdad Esfahbod
c84eb24a1e [mtiLib] Fix typo! 2016-01-22 18:11:58 +01:00
Sascha Brawer
af48e43371 [otlLib] Move building of MarkLigPos from feaLib to otlLib 2016-01-22 14:50:17 +01:00
Sascha Brawer
036e2ce497 [otlLib] Move building of LigatureArrays from feaLib to otlLib
Not sure if empty ComponentRecords can be optimized away.
For the time being, leaving the output unchanged so that
the refactoring has no effect on the generated files.
2016-01-22 14:14:47 +01:00
Behdad Esfahbod
501480fa70 Revert "[ot] Instead of deleting unnecessary Format, set it to None"
This reverts commit 6851f66d1810a4d3f484f2a82e39960e1a677f42.

See https://github.com/typesupply/compositor/issues/7
Fixes https://github.com/behdad/fonttools/issues/475
2016-01-22 14:03:23 +01:00
Behdad Esfahbod
f8e3ea08fb [mtiLib] Port SinglePos to otlLib 2016-01-22 13:44:27 +01:00
Behdad Esfahbod
59ee0618d7 [otlLib] Explicitly set Value to None if needed
Although the compiler (and now XML writer) assume None if an attribute
is not set, it's extremely frustrating for other code to have to check
before accessing an attribute.  So, explicitly set please!
2016-01-22 13:43:05 +01:00
Sascha Brawer
1978194caf [otlLib] Move building of LigatureAttach tables from feaLib to otlLib 2016-01-22 12:45:29 +01:00
Sascha Brawer
cf7c670e80 [otlLib] Move building of MarkBasePos from feaLib to otlLib 2016-01-22 11:53:34 +01:00
Sascha Brawer
50cbd5ca78 [otlLib] Move building of BaseArrays from feaLib to otlLib 2016-01-22 10:57:03 +01:00
James Godfrey-Kittle
34115b2f3f [feaLib] Add unit test for empty statement parsing 2016-01-21 13:32:58 -08:00
James Godfrey-Kittle
8fa5073e7e [feaLib] Accept empty statements in parser 2016-01-21 10:32:30 -08:00
Sascha Brawer
de24f4f0d4 [otlLib] Move building of BaseRecords from feaLib to otlLib 2016-01-21 17:23:36 +01:00
Sascha Brawer
08fa0f14dd [otlLib] Move building of MarkArrays from feaLib to otlLib 2016-01-21 16:23:55 +01:00
Sascha Brawer
f09de4277d [otlLib] Make otlLib compliant with PEP8 2016-01-21 15:23:41 +01:00
Sascha Brawer
f42d312580 [otlLib] Move building of ComponentRecords from feaLib to otlLib 2016-01-21 15:16:55 +01:00
Sascha Brawer
15ca8bb0a0 [otlLib] Move building of Mark2Records from feaLib to otlLib 2016-01-21 13:08:16 +01:00
Sascha Brawer
b07d168c0e [feaLib] Simplify how MarkArrays are built 2016-01-21 11:39:34 +01:00
Sascha Brawer
a4318a38c1 [otlLib] Build MarkRecords 2016-01-21 11:29:32 +01:00
Sascha Brawer
3c65e82307 [otlLib] Move building of otTables.Lookup from feaLib to otlLib 2016-01-20 19:25:41 +01:00
justvanrossum
56f863564e added GlyphCoordinatest().toInt() method; made compileCoordinates() actually work with float coords. 2016-01-20 19:23:16 +01:00
Sascha Brawer
51ec0bf5cc [otlLib] Move building of MarkGlyphSetsDef table from feaLib to otlLib 2016-01-20 11:28:33 +01:00
Sascha Brawer
3eacada029 [otlLib] Move building of LigCaretLists from feaLib to otlLib 2016-01-20 09:49:09 +01:00
Sascha Brawer
939b03fbea [otlLib] Move building of LigGlyphs from feaLib to otlLib 2016-01-20 09:16:31 +01:00
Sascha Brawer
bfff7b4e86 [otlLib] Move building of CaretValues from feaLib to otlLib 2016-01-20 08:23:42 +01:00
Sascha Brawer
1bb757ee3c [otlLib] Return None for empty argument to buildAttachList()
This simplifies call sites when building GDEF tables.
Also, publicly expose the buildAttachPoint() function.

https://github.com/behdad/fonttools/issues/468#issuecomment-173006650
2016-01-19 23:25:47 +01:00
Sascha Brawer
d1fd788af9 [otlLib] Build AttachLists in otlLib instead of feaLib 2016-01-19 22:38:23 +01:00
Sascha Brawer
f9f951d2ae [otlLib] Do not emit empty <Value/> elements for empty ValueRecords
No changes in the compiled binary representation, this just affects XML.
After this change, the XML for empty ValueRecords is identical to the
output from makeotf.

https://github.com/behdad/fonttools/issues/471
2016-01-19 22:01:30 +01:00
Behdad Esfahbod
4fd3b2c4ca [mtiLib] Implement forward references
This makes mtiLib feature complete.  Next step would be to add tests.
2016-01-19 18:51:11 +01:00
Behdad Esfahbod
057c4faa33 [mtiLib] Shuffle 2016-01-19 18:51:02 +01:00
Sascha Brawer
d39f22668e [feaLib] Emit ValueRecords even if their ValueFormat is zero
https://github.com/behdad/fonttools/issues/471
2016-01-19 17:07:08 +01:00
Sascha Brawer
35cc4b886d [otlLib] Minor: Use variable names that are less confusing 2016-01-19 16:54:52 +01:00
Sascha Brawer
ed4c93514c [otlLib] Test what otlLib.buildSinglePos() does with empty values
Context: https://github.com/behdad/fonttools/issues/471

This test helps to isolate the problem. Now we know that it is
in feaLib while otlLib behaves correctly.
2016-01-19 16:49:54 +01:00
Sascha Brawer
32a6754fd7 [feaLib] Use otlLib for generating SinglePos tables
See https://github.com/behdad/fonttools/issues/471 for the change
to ValueRecords whose ValueFormat is zero; this may indicate a problem
in otlLib that needs to be fixed.

Resolves https://github.com/behdad/fonttools/issues/472.
2016-01-19 16:27:45 +01:00
Sascha Brawer
ce7cc432f2 [otlLib] Implement otlLib.getSinglePosSubtable()
https://github.com/behdad/fonttools/issues/468
2016-01-19 15:40:19 +01:00
Cosimo Lupo
6ea91c9e7a Merge pull request #470 from anthrotype/namerecord-tostr
_n_a_m_e: add toStr method to NameRecord
2016-01-19 13:30:54 +00:00
Sascha Brawer
6c7776683e [otlLib] Implement buildSinglePos() 2016-01-19 14:22:28 +01:00
Cosimo Lupo
be489d07a6 _n_a_m_e: make NameRecord.__str__ call toStr with errors='backslashreplace'
the Python docs say that the return value of `__str__` must be a "string" object -- which means bytes in Python 2 and unicode in Python 3. Previously, str(namerecord) would always call 'toUnicode' method, even on Python 2.

https://docs.python.org/2/reference/datamodel.html#object.__str__

https://docs.python.org/3/reference/datamodel.html#object.__str__
2016-01-19 13:20:36 +00:00
Cosimo Lupo
818dd6ce1e _n_a_m_e: add toStr method to NameRecord
as discussed in https://github.com/typesupply/compositor/pull/10
2016-01-19 12:31:46 +00:00
Behdad Esfahbod
ba90369af9 [mtiLib] Port CursivePos to otlLib.builder 2016-01-18 12:32:07 +01:00
Behdad Esfahbod
305b8eaae3 [otlLib] Minor 2016-01-18 12:32:01 +01:00
Behdad Esfahbod
1ddfcee5a1 Minor simplification 2016-01-15 22:25:49 +01:00
Sascha Brawer
049fd4bd8f [otlLib] Move CursivePos building from feaLib to otlLib 2016-01-14 17:54:47 +01:00
Sascha Brawer
3968aaa71b [feaLib] Make invocation of otlLib less verbose 2016-01-14 17:15:52 +01:00
Sascha Brawer
9612ef1a22 [otlLib] Move buildCoverage from feaLib to otlLib 2016-01-14 17:10:45 +01:00
Sascha Brawer
0f8882bcc3 [otlLib] Move creation of ValueRecords from feaLib to otlLib 2016-01-14 16:27:04 +01:00