Re: Muffling widget repaints



When I say "repaint" I just mean that the there is a visible change in the
widget.  I guess I'm not using the word in its conventional GTK sense.

FWIW, I did connect to the expose signal of the container and found that it's
only called once, after the widget switchover is finished.  Which I guess is
ideal.  But the container still appears to be being updated ("repainted" in
my incorrect terminology) many times during the switchover.  For example, I
can sometimes see the the container's children repositioning themselves.

On Sat, Aug 21, 2004 at 02:22:56PM -0400, Paul Davis wrote:
> >I have a container which periodically loses some of its widgets and gains
> >others, sometimes on the order of hundreds.  The changeover happens all at
> >once (i.e. there's a big loop which does all the adding and destroying), but
> >it's still pretty ugly and slow because sometimes many repaints are done.  I
> >only care about the final repaint.
> 
> by "repaint" do you mean an "expose" signal? you should only be
> drawing within an expose handler (there is one exception: drawing into
> an off-screen drawable, typically a pixmap). drawing at any other time
> is just not the correct model.
> 
> --p
> 
> 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]