protect figure with gui-neutral widgets

Hi all,

I have been using backend-neutral matplotlib (0.99) widgets to implement
a simple GUI control, which can be opened from IPython pylab session.
The widgets are all contained in a dedicated figure, however if this
figure is the current one, pyplot commands draw through the widget
elements.

Is there any option to lock a matplotlib figure and thus protect it
from pyplot commands? If not, are there any plans to add such
function? I think this would surely make the matplotlib widgets more
useful.

Thank you,

Pavol

PS: Actually, the built-in subplot_tool function seems to suffer from
    the same issue - here is an example which draws a line through the
    Reset button:

$ ipython -pylab
In [1]: subplot_tool()
# click any slider
In [2]: plot(range(2))

Hi all,

I have been using backend-neutral matplotlib (0.99) widgets to implement
a simple GUI control, which can be opened from IPython pylab session.
The widgets are all contained in a dedicated figure, however if this
figure is the current one, pyplot commands draw through the widget
elements.

Is there any option to lock a matplotlib figure and thus protect it
from pyplot commands? If not, are there any plans to add such
function? I think this would surely make the matplotlib widgets more
useful.

Thank you,

Pavol

PS: Actually, the built-in subplot_tool function seems to suffer from
     the same issue - here is an example which draws a line through the
     Reset button:

$ ipython -pylab
In [1]: subplot_tool()
# click any slider
In [2]: plot(range(2))

This looks like a bug. Would you report it on Github as a New Issue, please, noting your mpl version and backend?
Issues · matplotlib/matplotlib · GitHub.

I can replicate it with 1.2.x on Linux.

Thank you.

Eric

···

On 07/02/2012 06:34 AM, Pavol Juhas wrote:

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
matplotlib-users List Signup and Options

Done - https://github.com/matplotlib/matplotlib/issues/984
I guess this means there is currently no way around it, right?

Pavol

Done - protecting figure with matplotlib widgets · Issue #984 · matplotlib/matplotlib · GitHub

Thank you.

I guess this means there is currently no way around it, right?

None that I know of offhand.

Eric

···

On 07/02/2012 12:36 PM, Pavol Juhas wrote:

Pavol

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
matplotlib-users List Signup and Options