emacs-devel
[Top][All Lists]
Advanced

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

Re: mouse-drag-and-drop-region


From: Stefan Monnier
Subject: Re: mouse-drag-and-drop-region
Date: Fri, 17 Nov 2017 10:58:57 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

>> >> That sounds better.  Though I wonder if tooltips could be shown in TTY
>> >> frames using a method similar to how `x-popup-menu' displays a menu in
>> >> them?
[...]
> Because TTY menus are implemented by overwriting parts of the glyph
> matrix with text that comes "out of nowhere", as far as the normal
> redisplay is concerned.

If we really wanted, we could implement some kind of tooltips in
a similar way, tho:

- overwrite parts of the glyph matrix
- register some "pre-redisplay hook"
- return to the normal command loop

the "pre-redisplay hook" would then remove the tooltip-overwrite from the
glyph matrix before the redisplay bumps into it.  Then if we want the
tooltip to last longer than "until the next redisplay" (which sounds
rather likely), we'd need some way to re-add the tooltip after the
redisplay is done.

Sounds pretty ugly/messy, obviously.

A more general solution could be to add two more glyph matrices (one for
overlay thingies like menus and tooltips, and another that combines the
"normal" glyph matrix with the one for overlay thingies (and it's this
one which is then sent to be displayed)).


        Stefan




reply via email to

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