We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 37c2903 commit 0938497Copy full SHA for 0938497
doc/users/next_whats_new/subsetting.rst
@@ -0,0 +1,22 @@
1
+Type 42 Subsetting is now enabled for PDF/PS backends
2
+-----------------------------------------------------
3
+
4
+`~matplotlib.backends.backend_pdf` and `~matplotlib.backends.backend_ps` now use
5
+a unified Type 42 font subsetting interface, with the help of `fontTools <https://fonttools.readthedocs.io/en/latest/>`_
6
7
+Set `~matplotlib.RcParams`'s *fonttype* value as ``42`` to trigger this workflow:
8
9
+.. code-block::
10
11
+ # for PDF backend
12
+ plt.rcParams['pdf.fonttype'] = 42
13
14
+ # for PS backend
15
+ plt.rcParams['ps.fonttype'] = 42
16
17
18
+ fig, ax = plt.subplots()
19
+ ax.text(0.4, 0.5, 'subsetted document is smaller in size!')
20
21
+ fig.savefig("document.pdf")
22
+ fig.savefig("document.ps")
0 commit comments