简体   繁体   中英

matplotlib windows 10 old looking plot window

I have python 2.7.14 on Win10, and installed matplotlib 2.1.2 via pip. I don't like the way the buttons and the whole plot window look like. How can I fix this. It should rather look like in 1 .

supposed to be plot window

my plot window

As of matplotlib version >= 2.0 using

import matplotlib.pyplot as plt
plt.gca()
plt.show()

you get this window now:

在此处输入图片说明

You can use the classic style ( plt.style.use("classic") ) to get the old figure style back:

import matplotlib.pyplot as plt
plt.style.use("classic")
plt.gca()
plt.show()

在此处输入图片说明

The buttons however are now still different.

In order to change the buttons, you could locate the folder with the buttons,

<path to python>\Lib\site-packages\matplotlib\mpl-data\images

and replace the images in it with the images of your choice. Eg you might want to download an older matplotlib version and take the images from there.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM