On Thursday 13 March 2008 05:02:36 pm Ted Drain wrote:
> I'm working on improving the plotting speed of one of our applications.  As
> part of that, I was looking at how quickly the QtAgg backend is drawing.  I
> added some print out's to the backend and noticed that it seems to be
> drawing everything twice.  In the code:
>
> backend_qtagg.py: FigureCanvasQTAgg class:
>
>     def draw( self ):
>         """
>         Draw the figure when xwindows is ready for the update
>         """
>
>         if DEBUG: print "FigureCanvasQtAgg.draw", self
>         self.replot = True
>         FigureCanvasAgg.draw(self)
>         self.repaint( False )
>
>
>
> FigureCanvasAgg.draw() will cause a draw the repaint call will cause a
> draw. If I comment out the FCAgg.draw() call, my application (QtAgg
> embedded in a PyQt program) works fine.  I've also run several of the
> various example scripts and they seem to work fine as well.  Panning,
> zooming, redraws, resize, and file saving seem to be unaffected.
>
> Does anyone know why the extra draw call might be necessary?

Thank you for pointing this out, Ted. It actually solves a problem I was 
seeing with the qt4agg backend, where the widgets.Cursor crosshairs were not 
being drawn when blitting was disabled.

I removed the lines from qtagg and qt4agg, and saw no problems in the examples 
or my own application, so I checked in the changes - svn 5002.

Darren

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to