Memory usage

Note that all of the above still have problems if I do:

    > self.figure = Figure(frameon=False)

The first thing to be drawn to the figure is the figure frame , a
matplotlib.patches.Rectangle instance. This is what "clears" the
background. If you want to clear the background to a certain color,
set the facecolor of the figure frame to that color and it will be
done. If you don't like the thin edge around the frame, set the
rectangle edgecolor to be the same as the facecolor. If you want the
figure to be transparent to overlay some other image, set the
rectangle alpha to be 0. It will still clear the pixel buffer, but
will be transparent.

In other words, you should be able to get any desired effect by
leaving the frame on and setting its properties.

See for more
information on Patch/Rectangle properties.