Christopher Brown wrote: > Hi, > > If I have a figure: > > h = pp.figure(num=14) > > What is the best way to check to see if Figure 14 exists? I'm writing a > function that adds plots to a figure window. I want the function to > check if the figure exists, and if so, turn off autoscaling (using > Eric's suggested axes.set_autoscale_on(False)) in case the user has zoomed. >
I added two functions to pyplot in svn: fignum_exists(num) and get_fignums() so that with future releases you won't have to delve into _pylab_helpers for this information. Eric ------------------------------------------------------------------------------ Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA -OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise -Strategies to boost innovation and cut costs with open source participation -Receive a $600 discount off the registration fee with the source code: SFAD http://p.sf.net/sfu/XcvMzF8H _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users