Cannot edit text in chart exported by Matplotlib and opened in Illustrator

半世苍凉 提交于 2019-12-02 18:19:40

You can edit the text in Acrobat/Illustrator if you set pdf.fonttype to 42 (TrueType), and export in pdf. You can set this in your ~/matplotlib/matplotlibrc:

pdf.fonttype : 42 # Output Type 3 (Type3) or Type 42 (TrueType)

..or dynamically:

>>> import matplotlib as mpl
>>> mpl.rcParams['pdf.fonttype'] = 42

Apparently it defaults to Type3 which Acrobat/Illustrator can't deal with.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!