Hi list, I'm under windows XP SP2 using python 2.3.5,
> matplotlib 0.80 and pygtk 2.6.0. I'm trying to program
> a viewer of data using matplotlib. I want to be able to
> save end reuse current graphic context (figure, title,
There is some tutorial information on using OO mpl at
> axes, labels...). I decided to explore the matplotlib
> code. But I'm not sure how i can get the current
Exploring the code is always a good way to start, as is reading the
class documentation for the classes you are working with, eg,
Note that the concept of "the current figure" does not exist in the OO
API -- this is a pylab construct. You create a figure with
fig = Figure(args...)
and then it is your responsibility to save it and use it where you
want, eg in as a class variable
self.fig = Figure(args...)
> I want to be able to save the current graphic context,
> draw a figure, then reload other data and add them to
> the current figure already drawn.
> Has anyone done that before? John, can you explain me
> how to proceed?
This sounds eminently doable -- try writing some example code and if
you get stuck post the code and a description of what you are trying
to do and we can help out.