Commit f0c21ff7 authored by Yori Fournier's avatar Yori Fournier
Browse files

I realized that from matplotlib 2.0.0 they changed back to the tkinter of six.

So I added the switch so that it works with modern version of matplotlib
parent 705580bc
Pipeline #410 failed with stage
in 1 minute and 29 seconds
......@@ -62,14 +62,18 @@ from matplotlib.backends.backend_tkagg import FigureManagerTkAgg, FigureCanvasTk
# Test mpl version:
from matplotlib import __version__ as mplvers
print('VERSION of Matplotlib:' + str(mplvers))
if int(mplvers.replace('.','')[:3]) < 150 :
import six
from six.moves import tkinter as Tk
elif if int(mplvers.replace('.','')[:3]) > 200 :
import six
from six.moves import tkinter as Tk
else :
from matplotlib.externals import six
from matplotlib.externals.six.moves import tkinter as Tk
# Class MyWin Overwriting the disgusting Matplotlib.FigureManager class
class MyWin_TkAgg(FigureManagerTkAgg):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment