Fix matplotlib warning
Harmonise matplotlib backend
This commit is contained in:
parent
d69a2c4df4
commit
21b6108345
|
@ -35,8 +35,10 @@ import Filters
|
|||
import Charset
|
||||
|
||||
try:
|
||||
calluse = not 'matplotlib' in sys.modules
|
||||
import matplotlib
|
||||
matplotlib.use('GTKCairo')
|
||||
if calluse:
|
||||
matplotlib.use('GTKCairo')
|
||||
from matplotlib.figure import Figure
|
||||
from matplotlib.backends.backend_gtk import FigureCanvasGTK as FigureCanvas
|
||||
from matplotlib.backends.backend_gtkagg import NavigationToolbar2GTKAgg as NavigationToolbar
|
||||
|
|
2
pyfpdb/GuiSessionViewer.py
Executable file → Normal file
2
pyfpdb/GuiSessionViewer.py
Executable file → Normal file
|
@ -30,7 +30,7 @@ try:
|
|||
calluse = not 'matplotlib' in sys.modules
|
||||
import matplotlib
|
||||
if calluse:
|
||||
matplotlib.use('GTK')
|
||||
matplotlib.use('GTKCairo')
|
||||
from matplotlib.figure import Figure
|
||||
from matplotlib.backends.backend_gtk import FigureCanvasGTK as FigureCanvas
|
||||
from matplotlib.backends.backend_gtkagg import NavigationToolbar2GTKAgg as NavigationToolbar
|
||||
|
|
|
@ -35,8 +35,10 @@ import Filters
|
|||
import Charset
|
||||
|
||||
try:
|
||||
calluse = not 'matplotlib' in sys.modules
|
||||
import matplotlib
|
||||
matplotlib.use('GTKCairo')
|
||||
if calluse:
|
||||
matplotlib.use('GTKCairo')
|
||||
from matplotlib.figure import Figure
|
||||
from matplotlib.backends.backend_gtk import FigureCanvasGTK as FigureCanvas
|
||||
from matplotlib.backends.backend_gtkagg import NavigationToolbar2GTKAgg as NavigationToolbar
|
||||
|
|
Loading…
Reference in New Issue
Block a user