Re: Problems with expose_event->region patch



Alexander Larsson <alla lysator liu se> writes:

> On 9 Mar 2001, Owen Taylor wrote:
> 
> > You should be able to switch this code over to
> >
> >  gdk_window_scroll (clist->clist_window, ...);
> >  gdk_window_process_updates (clist->clist_window, FALSE);
> >
> > [ There is some argument the second call should be
> >   gdk_window_process_all_updates() to make sure that the
> >   scrollbar eventually does get updated ]
> >
> > gdk_window_scroll() keeps an queue of translations, so there
> > is no need to process all graphics exposes before scrolling
> > again.
> 
> This works for gtkclist, patch appended. Same way seems to be ok for
> testgtk. But it seems harder to remove from gtktext.c, but on the other
> hand, I'm totally lost in the gtktext code. Any ideas?

Hmmm, actually, yeah, it would be hard to remove from gtktext.c
since gtktext.c makes the optimization when you insert text
in the middle of the screen of moving the bottom portion
down instead of redrawing that.

Now, the solution is just tot get rid of that optimization - we don't
do it for GtkTextView and it doesn't matter. But consider the code in
gtktext.c, I don't think the advantage of making
gtk_widget_send_expose() private is worth the effort that would take.

Though I like the ratio of - to + in the GtkCList patch...

Regards,
                                        Owen




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