matplotlib crashing wxpython gui constantly

You can put your plots almost wherever you want with
wxPython+matplotlib. I have apps in which the plot is inside a panel,

or inside a FlatNotebook, or inside a wxAuiNotebook, a scrolledwindow,
a splitter, a 4-ways splitter and I can’t remember others. Ah, yes,
MDIChildFrame. However, you should look at the matplotlib web site,

under “examples”, there is a demo from which I learnt to use the
wxPython+matplotlib combination. It is called embedding_in_wx.py (with
its friends embedding_in_wx2.py, 3, 4…).

Hi Andrea,

Thanks, I looked at the examples and found the ones you mentioned. But
all those examples show the plot sitting on the frame, not on a panel.
It works for me if I put a plot as a page of a wxNotebook, but I can’t
get it to display the plot when it is sitting on a panel. It just
draws the background, but no figure canvas. I had similar issues with
using pyplot. In fact, in both cases if there is any sort of error, what gets drawn is a small (maybe 32x32) box of the plot. Weird.

Do you know why this is? And how do you get a figure to sit on a panel? Sorry for the confusion.

Thanks,
Che

···

Andrea.

“Imagination Is The Only Weapon In The War Against Reality.”

http://xoomer.virgilio.it/infinity77/


To unsubscribe, e-mail:
wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org