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: Eli Zaretskii
Subject: Re: mouse-drag-and-drop-region
Date: Fri, 17 Nov 2017 09:33:16 +0200

> From: Alex <address@hidden>
> Cc: address@hidden,  address@hidden,  address@hidden
> Date: Fri, 17 Nov 2017 00:33:48 -0600
> 
> >> 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?
> >
> > No, it can't.  TTY menus pre-empt the command loop, so they cannot be
> > shown during mouse-tracking, AFAIR.
> 
> I didn't mean to use menus directly, but to use a similar method of
> displaying something "on top of" a TTY frame.  Is displaying the
> rectangle that makes up a menu necessarily incompatible with a regular
> command loop?

Yes, it is incompatible.

> If so, do you know why?

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.  IOW, there's no buffer or display string or
overlay string that the display engine knows about that produce this
text.  So if we let the command loop do its thing, it will eventually
enter redisplay, and the menu will be erased, partially or fully.

> > Does the flickering disappear if you set x-gtk-use-system-tooltips to
> > nil?
> 
> Yes, it appears that only GTK tooltips are affected here.  Should I file
> a bug report?

Yes, of course.  Though I doubt we have the expertise to fix it (or
maybe it's even unfixable as long as we implement the GTK support the
way we do).

> >> There's also a side issue that subsequent mouse-movement events appear
> >> to only be generated after moving a character rather than by a
> >> configurable amount of pixels, which leads to the tooltip movement being
> >> a bit jerky.
> >
> > If that, too, disappears when GTK tooltips are not used, then maybe
> > it's due to the way we show GTK tooltips.
> 
> I don't believe this one has to do with GTK.  If you set `track-mouse' to
> t, then, after the first pixel movement, you will only see
> mouse-movement events when you move the mouse to a whole character
> position.  This might be intentional, but I think it's poor behaviour.

Can you show a Lisp recipe to reproduce this?



reply via email to

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