emacs-devel
[Top][All Lists]
Advanced

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

Re: feature/icomplete-vertical


From: Eli Zaretskii
Subject: Re: feature/icomplete-vertical
Date: Mon, 05 Oct 2020 22:30:17 +0300

> From: João Távora <joaotavora@gmail.com>
> Cc: ghe@sdf.org,  spacibba@aol.com,  emacs-devel@gnu.org,
>   casouri@gmail.com,  juri@linkov.net
> Date: Mon, 05 Oct 2020 20:19:22 +0100
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> >> From: João Távora <joaotavora@gmail.com>
> >> Cc: ghe@sdf.org,  spacibba@aol.com,  emacs-devel@gnu.org,
> >>   casouri@gmail.com,  juri@linkov.net
> >> Date: Mon, 05 Oct 2020 20:03:32 +0100
> >> 
> >> >> I think the easiest way to make this function is to give it a buffer
> >> >> where text exists as buffer text and truncate-lines is what it it.  Then
> >> >> it can say exactly where it _would_ cut off.
> >> >
> >> > That doesn't work for displaying text with continuation lines, does
> >> > it?
> >> 
> >> I'm not sure what you mean.  Maybe?  Can you provide an example?  The
> >> idea is to use this buffer to "stage" what needs to be displayed, and
> >> gather guiding information from that, not necessarily to _do_ that
> >> displaying on that particular "stage".
> >
> > If the real buffer will be displayed without truncating lines, then
> > each physical line might take more than one screen line.  You need to
> > account for that when you decide where to truncate.
> 
> Yes, but presumably, the (vapourware) function we are talking about
> would interpret the value of truncate-lines "in the stage", and you'd
> set that to the same value that you plan to use in the "real buffer".

I guess I misunderstand your original proposal: did you mean to leave
truncate-lines at its value in the window where the text will be
displayed?  If so, that's OK, but then why did you mentioned that
variable? there are many more that affect the display, and they all
should be left at their values in the window.

In a nutshell, the function we are discussing should get the window in
which the text will be displayed as the argument, so that its layout
calculations are accurate.  The code should be very similar to
window-text-pixel-size, just the stop condition should be different.



reply via email to

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