[Top][All Lists]

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

Re: The unwarranted scrolling assumption

From: Lennart Borgman
Subject: Re: The unwarranted scrolling assumption
Date: Fri, 18 Jun 2010 15:56:38 +0200

On Fri, Jun 18, 2010 at 3:45 PM, Eli Zaretskii <address@hidden> wrote:
>> From: Lennart Borgman <address@hidden>
>> Date: Thu, 17 Jun 2010 06:55:17 +0200
>> Cc: Stefan Monnier <address@hidden>, address@hidden, address@hidden,
>>       address@hidden
>> > At least it works. I just tested. First time I am using Emacs without
>> > "jumping scrolling"! :-)
>> >
>> > If you think this is the right way to fix it I will send patches later
>> > when I cleaned up a bit.
>> >
>> > There is one more similar problem which I do not know how to handle,
>> > in fileio.c. In the function Finsert_file_contents clip_changed is set
>> > to 1. I am not quite sure of the impact of this but it looks wrong to
>> > me to do this. I think the display engine should be told, but it must
>> > decide what to do with redisplay, not fileio.
>> Here is the patch (without the fileio.c part which I leave until I got
>> some comments).
> This patch is not correct, IMO, because it does not consider the value
> of the window's window_end_valid flag.  The function
> reconsider_clip_changes, which you try to side-step, does the same as
> this test in your patch:
>> +  if ((buffer->clip_begv != buffer->begv) || (buffer->clip_zv != 
>> buffer->zv))
>> +    buffer->clip_changed = 1;
> but it also considers the window_end_valid flag, without which your
> patched version could try reusing portions of the current glyph matrix
> when the matrix is not guaranteed to be up to date.

I think you are wrong here, but I am not sure.

What I have done in the patch is trying to avoid setting clip_changed
whenever `narrow_to_region' or `widen' is called. I do this by
comparing clipping the next time redisplay happens with the clipping
that was in effect the last redisplay happened.

Can you please explain why window_end_valid flag should be involved?

Can you please also comment on the point where to check if clipping
has changed? Is not the entry of redisplay_window the right point for

reply via email to

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