fonttools 4.59.2__cp314-cp314-win32.whl → 4.60.0__cp314-cp314-win32.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of fonttools might be problematic. Click here for more details.

Files changed (42) hide show
  1. fontTools/__init__.py +1 -1
  2. fontTools/annotations.py +30 -0
  3. fontTools/cu2qu/cu2qu.c +1067 -946
  4. fontTools/cu2qu/cu2qu.cp314-win32.pyd +0 -0
  5. fontTools/cu2qu/cu2qu.py +19 -2
  6. fontTools/feaLib/lexer.c +18 -12
  7. fontTools/feaLib/lexer.cp314-win32.pyd +0 -0
  8. fontTools/misc/bezierTools.c +18 -12
  9. fontTools/misc/bezierTools.cp314-win32.pyd +0 -0
  10. fontTools/misc/enumTools.py +23 -0
  11. fontTools/pens/filterPen.py +218 -26
  12. fontTools/pens/momentsPen.c +18 -12
  13. fontTools/pens/momentsPen.cp314-win32.pyd +0 -0
  14. fontTools/pens/pointPen.py +40 -6
  15. fontTools/qu2cu/qu2cu.c +30 -16
  16. fontTools/qu2cu/qu2cu.cp314-win32.pyd +0 -0
  17. fontTools/ttLib/tables/_p_o_s_t.py +5 -5
  18. fontTools/ufoLib/__init__.py +279 -176
  19. fontTools/ufoLib/converters.py +14 -5
  20. fontTools/ufoLib/filenames.py +16 -6
  21. fontTools/ufoLib/glifLib.py +286 -190
  22. fontTools/ufoLib/kerning.py +32 -12
  23. fontTools/ufoLib/utils.py +41 -13
  24. fontTools/ufoLib/validators.py +121 -97
  25. fontTools/varLib/avar/__init__.py +0 -0
  26. fontTools/varLib/avar/__main__.py +72 -0
  27. fontTools/varLib/avar/build.py +79 -0
  28. fontTools/varLib/avar/map.py +108 -0
  29. fontTools/varLib/avar/plan.py +1004 -0
  30. fontTools/varLib/{avar.py → avar/unbuild.py} +70 -59
  31. fontTools/varLib/avarPlanner.py +3 -999
  32. fontTools/varLib/interpolatableHelpers.py +3 -0
  33. fontTools/varLib/iup.c +24 -14
  34. fontTools/varLib/iup.cp314-win32.pyd +0 -0
  35. {fonttools-4.59.2.dist-info → fonttools-4.60.0.dist-info}/METADATA +29 -2
  36. {fonttools-4.59.2.dist-info → fonttools-4.60.0.dist-info}/RECORD +42 -35
  37. {fonttools-4.59.2.data → fonttools-4.60.0.data}/data/share/man/man1/ttx.1 +0 -0
  38. {fonttools-4.59.2.dist-info → fonttools-4.60.0.dist-info}/WHEEL +0 -0
  39. {fonttools-4.59.2.dist-info → fonttools-4.60.0.dist-info}/entry_points.txt +0 -0
  40. {fonttools-4.59.2.dist-info → fonttools-4.60.0.dist-info}/licenses/LICENSE +0 -0
  41. {fonttools-4.59.2.dist-info → fonttools-4.60.0.dist-info}/licenses/LICENSE.external +0 -0
  42. {fonttools-4.59.2.dist-info → fonttools-4.60.0.dist-info}/top_level.txt +0 -0
fontTools/qu2cu/qu2cu.c CHANGED
@@ -1,4 +1,4 @@
1
- /* Generated by Cython 3.1.3 */
1
+ /* Generated by Cython 3.1.4 */
2
2
 
3
3
  /* BEGIN: Cython Metadata
4
4
  {
@@ -32,8 +32,8 @@ END: Cython Metadata */
32
32
  #elif PY_VERSION_HEX < 0x03080000
33
33
  #error Cython requires Python 3.8+.
34
34
  #else
35
- #define __PYX_ABI_VERSION "3_1_3"
36
- #define CYTHON_HEX_VERSION 0x030103F0
35
+ #define __PYX_ABI_VERSION "3_1_4"
36
+ #define CYTHON_HEX_VERSION 0x030104F0
37
37
  #define CYTHON_FUTURE_DIVISION 1
38
38
  /* CModulePreamble */
39
39
  #include <stddef.h>
@@ -3887,8 +3887,12 @@ static PyObject *__pyx_f_9fontTools_5qu2cu_5qu2cu_merge_curves(PyObject *__pyx_v
3887
3887
  __pyx_t_14 = __Pyx_c_diff_double(__pyx_v_p1, __pyx_v_p0);
3888
3888
  __pyx_t_7 = __pyx_PyComplex_FromComplex(__pyx_t_14); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 146, __pyx_L1_error)
3889
3889
  __Pyx_GOTREF(__pyx_t_7);
3890
- __pyx_t_9 = (__Pyx_PyList_GET_SIZE(__pyx_v_ts) != 0);
3891
- if (unlikely(((!CYTHON_ASSUME_SAFE_MACROS) && __pyx_t_9 < 0))) __PYX_ERR(0, 146, __pyx_L1_error)
3890
+ {
3891
+ Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_v_ts);
3892
+ if (unlikely(((!CYTHON_ASSUME_SAFE_SIZE) && __pyx_temp < 0))) __PYX_ERR(0, 146, __pyx_L1_error)
3893
+ __pyx_t_9 = (__pyx_temp != 0);
3894
+ }
3895
+
3892
3896
  if (__pyx_t_9) {
3893
3897
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_ts, 0, long, 1, __Pyx_PyLong_From_long, 1, 0, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 146, __pyx_L1_error)
3894
3898
  __Pyx_GOTREF(__pyx_t_1);
@@ -3922,8 +3926,12 @@ static PyObject *__pyx_f_9fontTools_5qu2cu_5qu2cu_merge_curves(PyObject *__pyx_v
3922
3926
  __pyx_t_14 = __Pyx_c_diff_double(__pyx_v_p2, __pyx_v_p3);
3923
3927
  __pyx_t_1 = __pyx_PyComplex_FromComplex(__pyx_t_14); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 147, __pyx_L1_error)
3924
3928
  __Pyx_GOTREF(__pyx_t_1);
3925
- __pyx_t_9 = (__Pyx_PyList_GET_SIZE(__pyx_v_ts) != 0);
3926
- if (unlikely(((!CYTHON_ASSUME_SAFE_MACROS) && __pyx_t_9 < 0))) __PYX_ERR(0, 147, __pyx_L1_error)
3929
+ {
3930
+ Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_v_ts);
3931
+ if (unlikely(((!CYTHON_ASSUME_SAFE_SIZE) && __pyx_temp < 0))) __PYX_ERR(0, 147, __pyx_L1_error)
3932
+ __pyx_t_9 = (__pyx_temp != 0);
3933
+ }
3934
+
3927
3935
  if (__pyx_t_9) {
3928
3936
  __pyx_t_7 = __Pyx_GetItemInt_List(__pyx_v_ts, -1L, long, 1, __Pyx_PyLong_From_long, 1, 1, 1, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 147, __pyx_L1_error)
3929
3937
  __Pyx_GOTREF(__pyx_t_7);
@@ -9031,15 +9039,16 @@ static int __Pyx_InitConstants(__pyx_mstatetype *__pyx_mstate) {
9031
9039
  return -1;
9032
9040
  }
9033
9041
  /* #### Code section: init_codeobjects ### */
9034
- typedef struct {
9035
- unsigned int argcount : 3;
9036
- unsigned int num_posonly_args : 1;
9037
- unsigned int num_kwonly_args : 1;
9038
- unsigned int nlocals : 6;
9039
- unsigned int flags : 10;
9040
- unsigned int first_line : 9;
9041
- unsigned int line_table_length : 15;
9042
- } __Pyx_PyCode_New_function_description;
9042
+ \
9043
+ typedef struct {
9044
+ unsigned int argcount : 3;
9045
+ unsigned int num_posonly_args : 1;
9046
+ unsigned int num_kwonly_args : 1;
9047
+ unsigned int nlocals : 6;
9048
+ unsigned int flags : 10;
9049
+ unsigned int first_line : 9;
9050
+ unsigned int line_table_length : 15;
9051
+ } __Pyx_PyCode_New_function_description;
9043
9052
  /* NewCodeObj.proto */
9044
9053
  static PyObject* __Pyx_PyCode_New(
9045
9054
  const __Pyx_PyCode_New_function_description descr,
@@ -12270,6 +12279,7 @@ static int __pyx_CommonTypesMetaclass_init(PyObject *module) {
12270
12279
  return -1;
12271
12280
  }
12272
12281
  mstate->__pyx_CommonTypesMetaclassType = __Pyx_FetchCommonTypeFromSpec(NULL, module, &__pyx_CommonTypesMetaclass_spec, bases);
12282
+ Py_DECREF(bases);
12273
12283
  if (unlikely(mstate->__pyx_CommonTypesMetaclassType == NULL)) {
12274
12284
  return -1;
12275
12285
  }
@@ -16097,6 +16107,10 @@ static int __Pyx_check_binary_version(unsigned long ct_version, unsigned long rt
16097
16107
  PyCode_NewWithPosOnlyArgs
16098
16108
  #endif
16099
16109
  (a, p, k, l, s, f, code, c, n, v, fv, cell, fn, name, name, fline, lnos, __pyx_mstate_global->__pyx_empty_bytes);
16110
+ #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030c00A1
16111
+ if (likely(result))
16112
+ result->_co_firsttraceable = 0;
16113
+ #endif
16100
16114
  return result;
16101
16115
  }
16102
16116
  #elif PY_VERSION_HEX >= 0x030800B2 && !CYTHON_COMPILING_IN_PYPY
Binary file
@@ -118,6 +118,7 @@ class table__p_o_s_t(DefaultTable.DefaultTable):
118
118
  def build_psNameMapping(self, ttFont):
119
119
  mapping = {}
120
120
  allNames = {}
121
+ glyphOrderNames = set(self.glyphOrder)
121
122
  for i in range(ttFont["maxp"].numGlyphs):
122
123
  glyphName = psName = self.glyphOrder[i]
123
124
  if glyphName == "":
@@ -126,16 +127,15 @@ class table__p_o_s_t(DefaultTable.DefaultTable):
126
127
  if glyphName in allNames:
127
128
  # make up a new glyphName that's unique
128
129
  n = allNames[glyphName]
129
- # check if the exists in any of the seen names or later ones
130
- names = set(allNames.keys()) | set(self.glyphOrder)
131
- while (glyphName + "." + str(n)) in names:
130
+ # check if the glyph name exists in the glyph order
131
+ while f"{glyphName}.{n}" in glyphOrderNames:
132
132
  n += 1
133
133
  allNames[glyphName] = n + 1
134
- glyphName = glyphName + "." + str(n)
134
+ glyphName = f"{glyphName}.{n}"
135
135
 
136
- self.glyphOrder[i] = glyphName
137
136
  allNames[glyphName] = 1
138
137
  if glyphName != psName:
138
+ self.glyphOrder[i] = glyphName
139
139
  mapping[glyphName] = psName
140
140
 
141
141
  self.mapping = mapping