File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -589,3 +589,7 @@ implementers).
589589Passing ``ismath="TeX!" `` to `.RendererAgg.get_text_width_height_descent ` is
590590deprecated. Pass ``ismath="TeX" `` instead, consistently with other low-level
591591APIs which support the values True, False, and "TeX" for ``ismath ``.
592+
593+ ``matplotlib.ttconv ``
594+ ~~~~~~~~~~~~~~~~~~~~~
595+ This module is deprecated.
Original file line number Diff line number Diff line change 4141from matplotlib .path import Path
4242from matplotlib .dates import UTC
4343from matplotlib import _path
44- from matplotlib import ttconv
44+ from matplotlib import _ttconv
4545from . import _backend_pdf_ps
4646
4747_log = logging .getLogger (__name__ )
@@ -996,7 +996,7 @@ def get_char_width(charcode):
996996 # Make the charprocs array (using ttconv to generate the
997997 # actual outlines)
998998 try :
999- rawcharprocs = ttconv .get_pdf_charprocs (
999+ rawcharprocs = _ttconv .get_pdf_charprocs (
10001000 os .fsencode (filename ), glyph_ids )
10011001 except RuntimeError :
10021002 _log .warning ("The PDF backend does not currently support the "
Original file line number Diff line number Diff line change 2626from matplotlib .cbook import is_writable_file_like , file_requires_unicode
2727from matplotlib .font_manager import is_opentype_cff_font , get_font
2828from matplotlib .ft2font import LOAD_NO_HINTING
29- from matplotlib .ttconv import convert_ttf_to_ps
29+ from matplotlib ._ttconv import convert_ttf_to_ps
3030from matplotlib .mathtext import MathTextParser
3131from matplotlib ._mathtext_data import uni2type1
3232from matplotlib .path import Path
Original file line number Diff line number Diff line change 1+ """
2+ Converting and subsetting TrueType fonts to PS types 3 and 42, and PDF type 3.
3+ """
4+
5+ from . import cbook
6+ from ._ttconv import convert_ttf_to_ps , get_pdf_charprocs # noqa
7+
8+
9+ cbook .warn_deprecated ('3.3' , name = __name__ , obj_type = 'module' )
Original file line number Diff line number Diff line change @@ -413,7 +413,7 @@ def get_extensions(self):
413413 yield ext
414414 # ttconv
415415 ext = Extension (
416- "matplotlib.ttconv " , [
416+ "matplotlib._ttconv " , [
417417 "src/_ttconv.cpp" ,
418418 "extern/ttconv/pprdrv_tt.cpp" ,
419419 "extern/ttconv/pprdrv_tt2.cpp" ,
Original file line number Diff line number Diff line change @@ -279,7 +279,7 @@ static PyModuleDef ttconv_module = {
279279#pragma GCC visibility push(default)
280280
281281PyMODINIT_FUNC
282- PyInit_ttconv (void )
282+ PyInit__ttconv (void )
283283{
284284 PyObject* m;
285285
You can’t perform that action at this time.
0 commit comments