Hello,
I did some quick tests of using pylab.figure() to create a figure
window, and then accessing the canvas to do blitted animation, which
is working well. I also reimplemented the resizeEvent handler to
update the region to be blitted. However, I have one major problem,
that when I click the X on the figure window, the window closes and
then my application wittingly tries to blit it and gives the error:
self.SpecCanvas.blit(self.total_bbox)
File "/usr/lib/python2.5/site-packages/matplotlib/backends/backend_qt4agg.py",
line 144, in blit
self.update(l, self.renderer.height-t, w, h)
RuntimeError: underlying C/C++ object has been deleted
I tried reimplementing the closeEvent handler, but my new handler
never seems to be executed. I am setting the close event handler like
this:
self.SpecCanvas.closeEvent = closePyl
def closePyl(self,event):
print "hi"
event.ignore()
self.parent().SpecCanvas = None
Any ideas about how to keep the window from being destroyed before I
have a chance to know about it?
Also, should I be using ion() or ioff() for this type of application?
It seems that either works fine, and I can zoom/pan even while
blitting.
Thanks,
Glenn
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Matplotlib-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-users