diff --git a/pyglance/glance/compare.py b/pyglance/glance/compare.py index 6504dfb5ec242a88da3af27f6f7b8e7dbe1188e6..447a2dbee0799695374cb7a23b1f3626f010f33e 100644 --- a/pyglance/glance/compare.py +++ b/pyglance/glance/compare.py @@ -18,6 +18,12 @@ from pycdf import CDFError from subprocess import check_call as sh from urllib import quote +import matplotlib +if "gui" in sys.argv[1:] : + matplotlib.use('Qt4Agg') +else : + matplotlib.use('Agg') + import glance.io as io import glance.delta as delta import glance.data as dataobj @@ -1922,6 +1928,9 @@ python -m glance colocateToFile_library_call(a_path, b_path, args[2:], tempOptions) + # Note: the figure plotting in the GUI is dependant on having selected an interactive renderer in the first "use" + # statement at the beginning of this module. (It had to be moved into this module to pre-empt other use statempents + # from imports of other glance modules.) def gui (*args) : """start the glance graphical user interface diff --git a/pyglance/glance/gui_figuremanager.py b/pyglance/glance/gui_figuremanager.py index 6c5501cef2461a355da9b57fce9f981ab7699282..2bab61621bbda502f7cd727ff6d998176b632ed6 100644 --- a/pyglance/glance/gui_figuremanager.py +++ b/pyglance/glance/gui_figuremanager.py @@ -9,7 +9,7 @@ Copyright (c) 2011 University of Wisconsin SSEC. All rights reserved. # these first two lines must stay before the pylab import import matplotlib -matplotlib.use('Qt4Agg') # use the Qt Anti-Grain Geometry rendering engine +#matplotlib.use('Qt4Agg') # use the Qt Anti-Grain Geometry rendering engine from pylab import * diff --git a/pyglance/glance/plot.py b/pyglance/glance/plot.py index 55ae9e3f43cd6df1d45186785990972cba4bc685..c64c3666c732e2fbaf4d977de83dd9139779ffb1 100644 --- a/pyglance/glance/plot.py +++ b/pyglance/glance/plot.py @@ -15,7 +15,7 @@ if os.path.isdir(PYQT4_HAX): # these first two lines must stay before the pylab import import matplotlib -matplotlib.use('Qt4Agg') # use the Anti-Grain Geometry rendering engine +#matplotlib.use('Qt4Agg') # use the Anti-Grain Geometry rendering engine from pylab import *