9572 Commits

Author SHA1 Message Date
pyup-bot
16b48bb1a6 Update zopfli from 0.1.9 to 0.2.1 2022-06-06 17:09:06 +01:00
pyup-bot
b93d3490c8 Update scipy from 1.7.3 to 1.8.1 2022-06-06 17:09:05 +01:00
pyup-bot
253c2dbde5 Update freetype-py from 2.2.0 to 2.3.0 2022-06-06 17:09:05 +01:00
pyup-bot
b8cd73e590 Update freetype-py from 2.2.0 to 2.3.0 2022-06-06 17:09:05 +01:00
pyup-bot
3eda4b1041 Update reportlab from 3.6.5 to 3.6.10 2022-06-06 17:09:04 +01:00
pyup-bot
8c374630cd Update sphinx from 4.3.2 to 5.0.1 2022-06-06 17:09:04 +01:00
Khaled Hosny
feb4e75469
Merge pull request #2637 from fonttools/subset-update-tags
[subset] Update default feature tags
2022-06-03 20:10:23 +02:00
Behdad Esfahbod
5295ebe966
Update Lib/fontTools/subset/__init__.py
Co-authored-by: Jany Belluz <jany.belluz@daltonmaag.com>
2022-06-03 05:48:03 -06:00
Behdad Esfahbod
a1fabd0fcb [subset] Update default feature tags
Corresponding to HarfBuzz commits:
40193adbfc
40d7d56e53
2022-06-03 05:41:31 -06:00
Nikolaus Waxweiler
42e4d66184
Merge pull request #2609 from fonttools/ds5-add-some-polish
[designspaceLib] Add some polish to the v5 paths
2022-05-04 16:13:03 +01:00
Nikolaus Waxweiler
fc174a9170 Undo warning 2022-05-04 14:54:07 +01:00
Nikolaus Waxweiler
26bf33bb60 Use assert instead of standalone error 2022-05-04 14:37:08 +01:00
Cosimo Lupo
b488d10768
Merge pull request #2611 from tshinnic/svglib_parser_real_number_format
Handle one more valid real number format in svgLib parse_path()
2022-05-04 08:27:24 +01:00
Cosimo Lupo
a09e80b1b1
Merge pull request #2596 from tshinnic/path_arc_rx_ry_nonnegative
Protect SVG path parsing from negative rx ry on arc commands
2022-05-04 08:14:15 +01:00
Thomas Shinnick
5abfef15e1 Handle one more valid real number format in svgLib parse_path()
Using svg.draw(pen) and parse_path() from svgLib threw exception
     ValueError: could not convert string to float: 'a'
on a SVG <path> string generated by Inkscape. Altering the path
string might object to other string bits like 'Z' or 'v', or
give even stranger exceptions.

Finally tracked it down to the path containing particular valid
numbers like "-4e-5" or "1e-4". Changing these to "-4.0e-5" or
"1.0e-4" would stop the exceptions. The parse_path() was not
accepting valid SVG real numbers.

The specification for real number formats is a bit of a mess in
CSS land right now, but the reassuringly concrete spec is:
    https://www.w3.org/TR/css-syntax-3/#number-token-diagram
which allows a real number having an exponent but without having
a fractional part, such as the number "1e3".

This change updates an RE to make fractional parts optional,
and adds a test for this valid SVG number format.
2022-05-03 17:48:14 -05:00
Thomas Shinnick
2066d3ad95 Update svgLib test for now non-negative arc radius values
Missed this test in previous commit.

Test is testing that parsing extraction of individual parameters
works as specified when spaces are omitted. Such as signaled when
a new number is specified with a leading sign +/-

Test previously used
     "M1-2A3-4-1.0 01.5.7",
where the first arc radius value was '3' and the second was '-4'.

Now that we are forcing radius values to be non-negative using abs()
the value returned in the test is not
     ("arcTo", (3.0, -4.0, -1.0, False, True, (0.5, 0.7))),
but rather
     ("arcTo", (3.0, 4.0, -1.0, False, True, (0.5, 0.7))),

Changed to expect the positive value, nicely the test continues to
test omitting spaces, but now also tests that negative radius values
are forced non-negative.
2022-05-03 17:21:48 -05:00
Nikolaus Waxweiler
9f984d93f7 Fix up tests 2022-04-29 18:13:03 +01:00
Nikolaus Waxweiler
177e0a71b8 Clean up one of the DSv5 documents somewhat 2022-04-29 16:57:06 +01:00
Nikolaus Waxweiler
ada9828121 Add some proper exceptions 2022-04-29 16:56:50 +01:00
Cosimo Lupo
41bd3a143d
Merge pull request #2603 from fonttools/subset-singlepos2-all-none
[subset] Fix subsetting SinglePosFormat2 with ValueFormat=0
2022-04-27 16:15:21 +01:00
Cosimo Lupo
0e43b0e2c3 [subset] Fix subsetting SinglePosFormat2 when ValueFormat=0
If a font has SinglePosFormat2 subtable with ValueFormat=0, then it contains a Value list with all None values.
Even though we don't build such inefficient tables, they do exist in the wild, as #2602 demostrates so we should handle those nicely, by downgrading them to Format1 with a single None value
2022-04-27 16:03:23 +01:00
Cosimo Lupo
8309aaf8d8 [subset_test] add failing test to repro SinglePosFormat2 with ValueFormat=0
reproduces #2602
2022-04-27 15:58:29 +01:00
Nikolaus Waxweiler
0f375d251f
Merge pull request #2601 from fonttools/update-ci-versions
Update CI testing
2022-04-26 11:29:23 +01:00
Nikolaus Waxweiler
2ff36bcef8 Test Cython on Python 3.10 2022-04-26 11:19:28 +01:00
Nikolaus Waxweiler
82319c31fa Test on 3.7 and 3.10 only 2022-04-26 11:16:58 +01:00
Nikolaus Waxweiler
40015efe60 Update GitHub Actions 2022-04-26 11:16:49 +01:00
Cosimo Lupo
ba8880e9f1 Bump version: 4.33.3 → 4.33.4.dev0 2022-04-26 10:51:16 +01:00
Cosimo Lupo
b9621ff427 Release 4.33.3 2022-04-26 10:51:15 +01:00
Cosimo Lupo
619e55d72a Add test for designspaceLib.types.Range dataclass
test for https://github.com/fonttools/fonttools/pull/2597
2022-04-26 10:50:36 +01:00
Cosimo Lupo
62eaac651e Update NEWS.rst 2022-04-26 10:45:08 +01:00
Cosimo Lupo
2e0dd62836
Merge pull request #2600 from fonttools/fix-deepcopyExceptFonts
[dsLib] Fix typo to actually transfer font references during deepcopy
2022-04-26 10:43:07 +01:00
Nikolaus Waxweiler
d8bf4c3123 Fix typo to actually transfer font references 2022-04-26 10:15:37 +01:00
Cosimo Lupo
cefb41e6c2
Merge pull request #2597 from m10d/fix_dataclass__post_init__method
correct naming of dataclasses '__post_init__' method
2022-04-24 06:58:44 +01:00
mike maxfield
47bbe6f7ca correct naming of dataclasses '__post_init__' method 2022-04-23 16:18:41 -06:00
Thomas Shinnick
812d05c122 Protect SVG path parsing from negative rx ry on arc commands
SVG documentation has an explicit requirement that _consumers_
of path arc commands accept and *correct* certain bad values.
This includes using the absolute value of the arc command's rx
and ry radius parameters.

See "9.5.1. Out-of-range elliptical arc parameters"
https://www.w3.org/TR/SVG/paths.html#PathDataEllipticalArcCommands

Lib\fontTools\svgLib\path\parser.py is missing any guard against
negative values for rx and ry parameter. Adding an abs() to each
value read will implement the SVG specification.

A problem was seen here while most programs and browsers handle
bad arc commands just fine. A bug report has been registered with
Inkscape (!) to protect any other non-SVG compliant programs.
See https://gitlab.com/inkscape/inbox/-/issues/6857 for more details.
2022-04-23 01:36:30 -05:00
Cosimo Lupo
37767203b0 Bump version: 4.33.2 → 4.33.3.dev0 2022-04-22 19:26:47 +01:00
Cosimo Lupo
e569154033 Release 4.33.2 2022-04-22 19:26:47 +01:00
Cosimo Lupo
224490d0b6 Update NEWS.rst 2022-04-22 19:26:06 +01:00
Cosimo Lupo
071915cda5
Merge pull request #2595 from fonttools/hb-repack-logging
[otBase] demote repacker ERROR to WARNING, only 1 per loop; don't exit at first failure
2022-04-22 19:20:03 +01:00
Cosimo Lupo
350f893e17 [otBase] demote repacker ERROR to WARNING, only 1 per loop; don't exit at firstfail
Fixes https://github.com/fonttools/fonttools/issues/2594
2022-04-22 19:05:54 +01:00
Cosimo Lupo
f68ce14d7a [otBase] log the name of uharfbuzz exception 2022-04-22 15:31:34 +01:00
Cosimo Lupo
4217384e81 subset_test: ignore_errors in rmtree when tearing down tempdir
should fix random test failures like
https://github.com/fonttools/fonttools/runs/6127120342?check_suite_focus=true
2022-04-22 11:46:07 +01:00
Cosimo Lupo
fe81aa729a Bump version: 4.33.1 → 4.33.2.dev0 2022-04-22 11:38:46 +01:00
Cosimo Lupo
04b835d04f Release 4.33.1 2022-04-22 11:38:46 +01:00
Cosimo Lupo
4e6f90d405 Update NEWS.rst 2022-04-22 11:38:43 +01:00
Cosimo Lupo
20de0784c2 send DeprecationWarning if FONTTOOLS_GPOS_COMPACT_MODE env var is set
and factor out shared code to read the env var
2022-04-22 11:32:43 +01:00
Cosimo Lupo
f8611bf848 [optimize.gpos] use the same default for config and env var 2022-04-22 11:18:00 +01:00
Cosimo Lupo
badeb75d90
Merge pull request #2593 from fonttools/fix-ufo2ft-regression
Fix ufo2ft regression by bringing back the env var for now
2022-04-22 11:13:23 +01:00
Jany Belluz
0bd2834d1e Fix ufo2ft regression by bringing back the env var for now 2022-04-22 10:14:16 +01:00
Cosimo Lupo
36e8eb2ada Bump version: 4.33.0 → 4.33.1.dev0 2022-04-21 19:29:35 +01:00