|
From: Samir P. <sp...@la...> - 2003-10-25 11:34:50
|
Commented out line 43 in _matlab_helpers fix my issue. Is it because I don't
have any window to destroy?
Here is small example (which creates problem without commenting line 43)
from matplotlib import use
use('GD')
from matplotlib.matlab import *
bar([0,1], [0,2])
savefig('test.png', dpi=100)
close('all')
bar([0,1], [1,1])
savefig('test1.png', dpi=100)
close('all')
********************New destroy function in _matlab_helpers (Need a fix if you
have window to destroy
*******************
def destroy(num):
if not GcfBase.has_fignum(num): return
figwin = GcfBase.figs[num]
oldQue = GcfBase._activeQue[:]
GcfBase._activeQue = []
for f in oldQue:
if f != figwin: GcfBase._activeQue.append(f)
del GcfBase.figs[num]
#figwin.window.destroy()
destroy = staticmethod(destroy)
|