[Top][All Lists]

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

Re: The unwarranted scrolling assumption

From: Eli Zaretskii
Subject: Re: The unwarranted scrolling assumption
Date: Sat, 19 Jun 2010 11:36:12 +0300

> From: Lennart Borgman <address@hidden>
> Date: Fri, 18 Jun 2010 23:25:21 +0200
> Cc: address@hidden
> On Fri, Jun 18, 2010 at 9:00 PM, Eli Zaretskii <address@hidden> wrote:
> >> From: Lennart Borgman <address@hidden>
> >> Date: Fri, 18 Jun 2010 19:31:30 +0200
> >> Cc: address@hidden
> >>
> >> +  if ((w->current_matrix->begv != b->begv) || (w->current_matrix->zv != 
> >> b->zv))
> >> +    b->clip_changed = 1;
> >
> > You cannot safely use w->current_matrix if w->window_end_valid is nil.
> So you say that w->current_matrix->begv is not valid unless
> window_end_valid is non-nil.

I'm saying that _none_ of the members of w->current_matrix is safe to
use when the window_end_valid flag is nil.  This flag being nil means
that the current matrix is not yet up to date, so its various members
are not completely computed and do not reflect what's on the screen.

> Are you saying that w->current_matrix->begv/zv is set before the
> redisplay is finished?

The definition of ``redisplay is finished'' for each window is
precisely that this flag is set.  Obviously, the other members of the
current_matrix struct are computed before that, and not in a single
place.  So yes, the begv/zv members are computed before redisplay is

> If you are saying that then what you are saying above seems correct to
> me. But on the other hand then I think what you said before about that
> the redisplay engine had enough information for setting clip_changed
> is false.

Yes, because it makes sure the window_end_valid flag is non-nil.  Then
the information is valid and can be used.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]