Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Open
Description
Bug summary
When saving a figure in svg using the option text.usetex = True, the texts in the obtained svg picture are rendered as path.
Code for reproduction
frompathlibimportPathimportmatplotlib.pyplotaspltthis_dir=Path(__file__).parents[0]plt.rcParams['svg.fonttype']='none'plt.rcParams['text.usetex']=Truex= [0,10]fig,ax=plt.subplots()ax.plot(x,x)fig.savefig(this_dir/'test.svg')
Actual outcome
As an example, the label here is a path svg object.
Expected outcome
Here the same plot, with the line plt.rcParams['text.usetex'] = True commented
Additional information
No response
Operating system
Windows
Matplotlib Version
3.5.2
Matplotlib Backend
No response
Python version
3.10
Jupyter version
No response
Installation
pip