bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#52142: 28.0.60; `posn-object-width-height' does not reflect actual d


From: Eli Zaretskii
Subject: bug#52142: 28.0.60; `posn-object-width-height' does not reflect actual dimensions of object when confronted by display string
Date: Sat, 27 Nov 2021 15:03:11 +0200

> From: Po Lu <luangruo@yahoo.com>
> Cc: 52142@debbugs.gnu.org
> Date: Sat, 27 Nov 2021 20:47:07 +0800
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > That's a feature.  Maybe it isn't documented clearly enough, but
> > basically as long as there's a character displayed at that position,
> > WIDTH and HEIGHT give the dimensions of that character's glyph on
> > display.
> 
> Hmm, okay.  I think the documentation in (elisp)Click Events could do
> with some improvement:

Thanks, fixed.

> > Remember: this stuff was originally designed for mouse clicks, where
> > it's important to know what did you click on.
> 
> Thanks.  On a slightly unrelated topic, what would be the appropriate
> method to obtain the height of such a display string?  I'm trying to
> make the pixel scrolling machinery work with such text, and while
> scrolling down already works, I have no idea how to implement scrolling
> up, which currently relies on going to the last screen line, then
> adjusting vscroll the remainder of the way, which naturally requires a
> way to fetch the height of the display string.

Did you try window-text-pixel-size?





reply via email to

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