GNU bug report logs - #18195
24.3.92; window-screen-lines is not accurate

Previous Next

Package: emacs;

Reported by: Dmitry <dgutov <at> yandex.ru>

Date: Tue, 5 Aug 2014 02:01:01 UTC

Severity: normal

Found in version 24.3.92

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Dmitry Gutov <dgutov <at> yandex.ru>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: rudalics <at> gmx.at, 18195 <at> debbugs.gnu.org
Subject: bug#18195: 24.3.92; window-screen-lines is not accurate
Date: Wed, 06 Aug 2014 01:21:56 +0400
On 08/05/2014 05:46 PM, Eli Zaretskii wrote:

> I fixed window-screen-lines.

Thanks!

> For example, AFAIU, your code currently assumes that the font used for
> popup is the same as the one used for the underlying buffer text.  But
> since you provide faces for the popup, a user could legitimately
> customize those faces to use a different font, and thus invalidate
> your calculations, because window-screen-lines uses the metrics of the
> default face's font.

Sure. This doesn't add any constraints over what we've been living with 
for years.

> IMO, instead of overloading existing display features with jobs they
> were never designed to do, and then live forever with the situation
> where development breaks the resulting applications (like the
> pixel-wise resizing of windows did with this one)

pixel-wise resizing wasn't actually the culprit: I've just never tested 
the code with non-zero line-spacing. Even with it, the bug wasn't too 
easy to notice.

> it would be a much
> better investment of energy to come up with requirements for Lisp APIs
> that could be used by applications for laying out text.

That sounds great, but I don't even know where to start. What we're 
trying to emulate, though, is multi-layered display. That sounds 
somewhat different from a "text layout API" to me.




This bug report was last modified 10 years and 289 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.