6641 Commits

Author SHA1 Message Date
Cosimo Lupo
cd58eb3276 README: remove Landscape.io badge
It's no longer working since we moved to the new fonttools organization, and it wasn't that useful after all
(I never used it myself), so I'm removing it from the main page.
2019-02-26 14:23:32 -08:00
Michiharu Ariza
c8d4149b32 Fix issue #1516: subset VVAR (#1517)
* fix #issue 1516: subset VOrgMap

* fixed BsbMap as well

* fix bad edit
2019-02-22 19:23:04 -05:00
Nikolaus Waxweiler
1fccfacb3d
Merge pull request #1514 from madig/varLib-load_designspace-add-ital-std-name
[varLib] load_designspace: add standard en name for ital tag
2019-02-22 13:13:27 +00:00
Nikolaus Waxweiler
3cb88ba861 Add NEWS item 2019-02-22 13:02:44 +00:00
Nikolaus Waxweiler
ea24fa8d2a [varLib] load_designspace: add standard en name for ital tag 2019-02-22 11:29:33 +00:00
Cosimo Lupo
67fe931f15 Snippets/svg2glif: import internal copy of glifLib and pointPen modules 2019-02-22 11:08:40 +00:00
Khaled Hosny
cbd0995224 [feaLib] Fix double indentation of subtable
Similar to 05329ed033ae0aa2451272a39ada9aad9f1f5ed7.
2019-02-19 19:00:16 +02:00
Khaled Hosny
1a0aec4c56 [feaLib] Add forceChain to MultipleSubstStatement
For consistency with other substitution statements.
2019-02-19 18:59:58 +02:00
Cosimo Lupo
4e687c8327 Bump version: 3.38.0 → 3.38.1.dev0 2019-02-18 09:57:09 +00:00
Cosimo Lupo
517dde00b9 Release 3.38.0 2019-02-18 09:57:09 +00:00
Cosimo Lupo
9dd01bd001 Update changelog 2019-02-18 09:57:04 +00:00
Read Roberts
7ae6ca8106 [subset CFF] Fix de-subroutinizing bug when subroutines contain hints (#1499)
* [subset CFF] Fix bug in de-subroutinizing when subroutines contain hints, issue 1493

The  code was skipping executing a subroutine if it had already been desubroutinized. The initial set of vstemhm and hstemhm operators and values may be in a subroutine. If a charstring is being executed which calls such subroutines, they still need to be executed in order to count the number of hint values seen, so that the byte length of the hintmask can be calculated.

I fixed this bug by executing subroutines even if they have already been desubroutinized, as long  as  (we don't know yet if we are doing hintmasks) or ( we do need a hintmask, but have not yet seen it).

Clean up code per Cosimo's suggestions:

In arg list for stop_hint_count(), use *args to accept unused argument, rather than a dummy positional argument.

Change stop_hintcount_ops to a from a global variable to a class variable  in _DesubroutinizingT2Decompiler.

Remove un-needed 'return' at line 387

Remove duplicate assignment of cs at line 437

Add patch for the bug where AttributeError is encountered when remove_hints is run after desubroutinize: remove lines deleting the GlobalSubrs for each FontDict. This always needed to be done only once, and is now in any case done in cff.GlobalSubrs.clear(), at the end of the desubroutinize() function.

Changed test case subset_test.py::'test_no_hinting_desubroutinize_CFF' to reference a font with a non-empty GlobalSubr, in order to trigger AttributeError traceback.
2019-02-18 09:43:27 +00:00
Cosimo Lupo
1e48dc5cfc
Merge pull request #1498 from fonttools/pyup-scheduled-update-2019-02-11
Scheduled weekly dependency update for week 06
2019-02-18 09:35:14 +00:00
Cosimo Lupo
da4ea5b906
Merge pull request #1508 from fonttools/svg-shapes
[svgLib] add support for importing shapes into paths
2019-02-15 21:25:47 +00:00
Just van Rossum
9f80939576
Merge pull request #1509 from khaledhosny/pointpen
A couple ufoLib.pointPen → pens.pointPen
2019-02-15 08:03:42 +01:00
Khaled Hosny
e0b517a6e7 A couple ufoLib.pointPen → pens.pointPen 2019-02-14 23:38:11 +02:00
Cosimo Lupo
7a25b3a4e1 factor out _strip_xml_ns into its own function 2019-02-14 17:43:44 +00:00
Cosimo Lupo
dda4c1a41e svgLib: rename PathBuilder's 'pathes' attribute to 'paths' 2019-02-14 17:18:33 +00:00
Cosimo Lupo
a4ed057dd1 minor whitespace 2019-02-14 17:16:26 +00:00
Cosimo Lupo
813826f68c Merge pull request #1500 from rsheeter/master into svg-shapes 2019-02-14 17:11:51 +00:00
Cosimo Lupo
bcd40431d6
Merge pull request #1501 from punchcutter/master
Read special case of contextual positioning
2019-02-14 10:40:54 +00:00
Cosimo Lupo
72e046647b
Add parentheses to clarify operators
Co-Authored-By: punchcutter <punchcutter@gmail.com>
2019-02-13 11:12:21 -08:00
Cosimo Lupo
51a49de3ed
Merge pull request #1476 from chrissimpkins/name-viewer
[Snippets] Add name-viewer.ipynb jupyter notebook
2019-02-13 18:16:23 +00:00
punchcutter
da5b1500b9 Read special case of contextual positioning. 2019-02-12 12:35:34 -08:00
Rod Sheeter
4f318045fd Merge remote-tracking branch 'upstream/master' 2019-02-12 11:53:52 -08:00
Rod Sheeter
416da67fdd Try to follow FT coding style 2019-02-12 11:53:27 -08:00
pyup-bot
33a39a94e1 Update fs from 2.2.1 to 2.3.1 2019-02-11 16:14:10 +01:00
pyup-bot
901eaf41c1 Update scipy from 1.2.0 to 1.2.1 2019-02-11 16:14:08 +01:00
Miguel Sousa
113a4c2585
Merge pull request #1497 from fonttools/fealib-main-tables
[feaLib] Add 'tables' option to __main__.py
2019-02-11 00:41:39 -08:00
Miguel Sousa
17b2108666 [feaLib] Add 'tables' option to __main__.py
Relates to #1159
2019-02-10 22:27:26 -08:00
Khaled Hosny
c3f3606c59 [feaLib] Allow hyphen in glyph class names
Matches AFDKO’s makeotf behaviour.
2019-02-10 14:31:37 +02:00
Rod Sheeter
199aa9e24b Rudimentary decimal support 2019-02-08 14:59:28 -08:00
Rod Sheeter
1e70458679 More simple shape examples 2019-02-08 13:11:33 -08:00
Rod Sheeter
d910ba371b Wire SVGPath to import other shapes 2019-02-08 11:37:00 -08:00
Rod Sheeter
1292029be2 test for basic rounded rect 2019-02-08 10:50:22 -08:00
Rod Sheeter
f0e8e72187 Test wiring for <rect> import 2019-02-08 10:06:14 -08:00
Cosimo Lupo
173a0f5011 [C_P_A_L_] make Color a subclass of namedtuple
so that's comparable/hashable/immutable and can be used as key in a dict or set.

The fromXML instance method was dropped since it relied on the object being mutable.
A fromHex classmethod replaces it.
2019-02-08 01:16:47 +01:00
Read Roberts
4de8342310
Merge pull request #1490 from anthrotype/fix-subset-desubroutinize
[subset] Fix 'AttributeError: GlobalSubrs' with --desubroutinize option
2019-02-06 20:18:08 -08:00
Cosimo Lupo
8e8da97a4c [cffLib]: add clear() method to Index class to empty in-place 2019-02-07 01:58:22 +01:00
Cosimo Lupo
97006a0d67 [subset] Fix 'AttributeError: GlobalSubrs' with --desubroutinize option
Fixes #1483

'remove_unused_subroutines' method expects a 'GlobalSubrs' attribute but the 'desubroutinize'
method deletes it. We don't have to call 'remove_unused_subroutines' at the end of 'desubroutinize'
method, we can just delete all the local subroutines, and clear the GlobalSubrsIndex.

Only call 'remove_unused_subroutines' method once, when we are not desubroutinizing.
2019-02-07 01:51:05 +01:00
Cosimo Lupo
027501cc26 .travis.yml: need to use 'dist: xenial' for pypy 6.0 2019-02-06 22:27:17 +01:00
Cosimo Lupo
74d683d04b .travis: use pypy2.7-6.0
5.8.0 seems to be no longer available on travis.
this should be the latest one currently available.
https://travis-ci.org/fonttools/fonttools/jobs/489641018
2019-02-06 22:19:07 +01:00
Nikolaus Waxweiler
bc9d6c6b36
Merge pull request #1489 from madig/cffLib-PrivateDict-refactor-getattr
[cffLib] Replace `PrivateDict.__getattr__` with property for `in_cff2`
2019-02-06 17:03:59 +00:00
Nikolaus Waxweiler
a8d4bfc42d Replace PrivateDict.__getattr__ with property
The dunder method doesn't seem to be doing anything other than providing
an `in_cff2` attribute. Do that with a property instead of bending
__getattr__.

This one confused me when I was working on
https://github.com/fonttools/fonttools/pull/1488.
2019-02-06 10:15:38 +00:00
Cosimo Lupo
649dc49dba [cffLib] Fix RecursionError in BaseDict.__getattr__ when unpickling
We need to raise AttributeError for non-existing dunder methods like
'__deepcopy__' or '__getstate__', because deepcopy() and pickle.load()
test for these on the instance using getattr() and treat the resulting
AttributeError as a signal that the object doesn't implement these custom
hooks. If we don't do that, we enter an infinite recursion as we attempt
to look up the missing dunder methods in the 'rawDict' dictionary,
because 'rawDict' is set inside __init__, but __init__ is not invoked
while unpickling (only __new__ is); thus self.rawDict is also missing
and __getattr__ is invoked with argument 'rawDict' again and again until
it crashes with RecursionError. Phew.

Fixes https://github.com/fonttools/fonttools/pull/1488
2019-02-06 01:05:11 +01:00
Cosimo Lupo
8832062c40
Merge pull request #1488 from madig/fix-cff-deepcopy
WIP: Fix deepcopy-ing of CFFs
2019-02-06 01:00:39 +01:00
Nikolaus Waxweiler
e50733df21 Make simpler test in cffLib tests 2019-02-05 14:33:58 +00:00
Nikolaus Waxweiler
3011f3b7d4 Add smoke-test for layout interpolation of OTFs 2019-02-05 13:57:01 +00:00
Nikolaus Waxweiler
8bff72139c Reinstate fixed load_masters() 2019-02-05 13:02:53 +00:00
Nikolaus Waxweiler
9739dc7d86 Bump version: 3.37.3 → 3.37.4.dev0 2019-02-05 12:50:18 +00:00