emacs-devel
[Top][All Lists]
Advanced

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

Re: The future of Follow Mode - a proposal.


From: Eli Zaretskii
Subject: Re: The future of Follow Mode - a proposal.
Date: Fri, 19 Feb 2016 20:45:39 +0200

> Date: Fri, 19 Feb 2016 18:18:34 +0000
> Cc: address@hidden
> From: Alan Mackenzie <address@hidden>
> 
> > > Where and why do you see the need for deep changes?
> 
> > I already explained this above: "the fact that the current display
> > engine doesn't support windows of unequal width".  If you want to lift
> > this limitation, the move_it_* family of functions, which simulate
> > redisplay, and are the workhorse of every decision Emacs makes that
> > concerns layout, cannot switch windows in their inner loops.
> 
> I envisage reinitialising the iterator structure as necessary when
> passing bewteen windows.  The change in width would be handled at a
> relatively high level.  The window start position is known, the window
> end position could be calculated as we progress.

The functions we talk about currently don't know what they are invoked
for.  Your envisioned changes imply that they should behave
differently depending on whether the results will be used for layout
of the current window or the next/previous window in a group.  That's
part of the changes I had in mind.  They are not trivial.  But without
them, what you want to do will not work reliably.

> As an example, `compute_window_start_on_continuation_line' would have to
> use the dimensions of the previous window to determine the window-start.
> Jiggling the various windows around after text changes or scrolling is
> going to be the hard part of the coding.

Yes, and the result will be non-trivial changes in the overall logic,
because redisplaying a window will no longer be independent of other
windows.

It's all doable, of course, but I suggest taking a good look at the
use cases for each of these functions, before you design the way they
should work to support windows of unequal width.



reply via email to

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