Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / ufo2ft / fonttools-cu2qu.patch
blob56aba78b5b31ae7fd914333c4235400534213f62
1 From eb63747509b2c18793b95eb12cc0141277520798 Mon Sep 17 00:00:00 2001
2 From: Simon Cozens <simon@simon-cozens.org>
3 Date: Thu, 11 Feb 2021 09:43:41 +0000
4 Subject: [PATCH 1/2] Rename cu2qu to fontTools.cu2qu
6 ---
7 Lib/ufo2ft/filters/cubicToQuadratic.py | 4 ++--
8 Lib/ufo2ft/preProcessor.py | 4 ++--
9 setup.py | 1 -
10 tests/outlineCompiler_test.py | 2 +-
11 tests/preProcessor_test.py | 2 +-
12 5 files changed, 6 insertions(+), 7 deletions(-)
14 diff --git a/Lib/ufo2ft/filters/cubicToQuadratic.py b/Lib/ufo2ft/filters/cubicToQuadratic.py
15 index 87d81b1..4b77144 100644
16 --- a/Lib/ufo2ft/filters/cubicToQuadratic.py
17 +++ b/Lib/ufo2ft/filters/cubicToQuadratic.py
18 @@ -1,7 +1,7 @@
19 import logging
21 -from cu2qu.pens import Cu2QuPointPen
22 -from cu2qu.ufo import CURVE_TYPE_LIB_KEY, DEFAULT_MAX_ERR
23 +from fontTools.pens.cu2quPen import Cu2QuPointPen
24 +from fontTools.cu2qu.ufo import CURVE_TYPE_LIB_KEY, DEFAULT_MAX_ERR
26 from ufo2ft.filters import BaseFilter
27 from ufo2ft.fontInfoData import getAttrWithFallback
28 diff --git a/Lib/ufo2ft/preProcessor.py b/Lib/ufo2ft/preProcessor.py
29 index e239152..9463aea 100644
30 --- a/Lib/ufo2ft/preProcessor.py
31 +++ b/Lib/ufo2ft/preProcessor.py
32 @@ -267,7 +267,7 @@ class TTFInterpolatablePreProcessor:
33 skipExportGlyphs=None,
34 filters=None,
36 - from cu2qu.ufo import DEFAULT_MAX_ERR
37 + from fontTools.cu2qu.ufo import DEFAULT_MAX_ERR
39 self.ufos = ufos
40 self.inplace = inplace
41 @@ -304,7 +304,7 @@ class TTFInterpolatablePreProcessor:
42 self.postFilters = [[f for f in filters if not f.pre] for filters in filterses]
44 def process(self):
45 - from cu2qu.ufo import fonts_to_quadratic
46 + from fontTools.cu2qu.ufo import fonts_to_quadratic
48 needs_decomposition = set()
50 diff --git a/setup.py b/setup.py
51 index d8d9982..a165ab1 100644
52 --- a/setup.py
53 +++ b/setup.py
54 @@ -30,7 +30,6 @@ setup(
55 tests_require=["pytest>=2.8"],
56 install_requires=[
57 "fonttools[ufo]>=4.34.0",
58 - "cu2qu>=1.6.7",
59 "cffsubr>=0.2.8",
60 "booleanOperations>=0.9.0",
62 diff --git a/tests/outlineCompiler_test.py b/tests/outlineCompiler_test.py
63 index b31319c..ee51920 100644
64 --- a/tests/outlineCompiler_test.py
65 +++ b/tests/outlineCompiler_test.py
66 @@ -2,7 +2,7 @@ import logging
67 import os
69 import pytest
70 -from cu2qu.ufo import font_to_quadratic
71 +from fontTools.cu2qu.ufo import font_to_quadratic
72 from fontTools.ttLib import TTFont
73 from fontTools.ttLib.tables._g_l_y_f import USE_MY_METRICS
75 diff --git a/tests/preProcessor_test.py b/tests/preProcessor_test.py
76 index 11196f8..bc32d55 100644
77 --- a/tests/preProcessor_test.py
78 +++ b/tests/preProcessor_test.py
79 @@ -2,7 +2,7 @@ import logging
80 import os
82 import pytest
83 -from cu2qu.ufo import CURVE_TYPE_LIB_KEY
84 +from fontTools.cu2qu.ufo import CURVE_TYPE_LIB_KEY
85 from fontTools import designspaceLib
87 import ufo2ft
88 --
89 2.36.1
91 From 58f3ab5e5db8090aba10fefd58ad8df4b507e7c3 Mon Sep 17 00:00:00 2001
92 From: Simon Cozens <simon@simon-cozens.org>
93 Date: Thu, 11 Feb 2021 09:49:28 +0000
94 Subject: [PATCH 2/2] Sort the imports
96 ---
97 Lib/ufo2ft/filters/cubicToQuadratic.py | 2 +-
98 tests/preProcessor_test.py | 2 +-
99 2 files changed, 2 insertions(+), 2 deletions(-)
101 diff --git a/Lib/ufo2ft/filters/cubicToQuadratic.py b/Lib/ufo2ft/filters/cubicToQuadratic.py
102 index 4b77144..5f28ea4 100644
103 --- a/Lib/ufo2ft/filters/cubicToQuadratic.py
104 +++ b/Lib/ufo2ft/filters/cubicToQuadratic.py
105 @@ -1,7 +1,7 @@
106 import logging
108 -from fontTools.pens.cu2quPen import Cu2QuPointPen
109 from fontTools.cu2qu.ufo import CURVE_TYPE_LIB_KEY, DEFAULT_MAX_ERR
110 +from fontTools.pens.cu2quPen import Cu2QuPointPen
112 from ufo2ft.filters import BaseFilter
113 from ufo2ft.fontInfoData import getAttrWithFallback
114 diff --git a/tests/preProcessor_test.py b/tests/preProcessor_test.py
115 index bc32d55..41c579c 100644
116 --- a/tests/preProcessor_test.py
117 +++ b/tests/preProcessor_test.py
118 @@ -2,8 +2,8 @@ import logging
119 import os
121 import pytest
122 -from fontTools.cu2qu.ufo import CURVE_TYPE_LIB_KEY
123 from fontTools import designspaceLib
124 +from fontTools.cu2qu.ufo import CURVE_TYPE_LIB_KEY
126 import ufo2ft
127 from ufo2ft.constants import (
129 2.36.1