Too many Configure events

Bernhard Herzog bh at
Sat Jan 5 16:34:07 CET 2002

"Bob Greschke" <bob at> writes:

> I have a Tkinter program that draws a graph.  If the user grabs a
> corner of the frame and resizes it I use the Configure event to clear
> and redraw the graph.  In (UNIX/Solaris) OpenWindows, and FVWM, one
> Configure event gets generated when the user releases the mouse
> button.  But Gnome generates Configure events while the user is
> resizing the frame. 

The best way to handle this is to only redraw in idle time, i.e. when no
more unhandled events are in the queue. Basically, everytime the
window's contents become invalid you add an idle handler which will
start the redraw. Since there can be several events that require a
redraw before the program gets idle, you should check whether you
already started the idle handler.


Intevation GmbH                       

More information about the Python-list mailing list