From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: mouse-drag-and-drop-region Date: Sat, 18 Nov 2017 11:07:34 +0200 Message-ID: <8360a8gdk9.fsf@gnu.org> References: <5A0ABD41.5040402@gmx.at> <874lpwobsa.fsf@gmail.com> <5A0C0765.2040908@gmx.at> <87375fl3z1.fsf@gmail.com> <831skzjo2o.fsf@gnu.org> <87y3n7jj2y.fsf@gmail.com> <83r2syi5h6.fsf@gnu.org> <87r2sx4do3.fsf@gmail.com> <837eupiclf.fsf@gnu.org> <87ine8qdz8.fsf@gmail.com> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1510996088 11331 195.159.176.226 (18 Nov 2017 09:08:08 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 18 Nov 2017 09:08:08 +0000 (UTC) Cc: rudalics@gmx.at, tak.kunihiro@gmail.com, emacs-devel@gnu.org To: Alex Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Nov 18 10:08:04 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eFz6X-0002M2-Nn for ged-emacs-devel@m.gmane.org; Sat, 18 Nov 2017 10:08:01 +0100 Original-Received: from localhost ([::1]:49227 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eFz6b-00030o-Ok for ged-emacs-devel@m.gmane.org; Sat, 18 Nov 2017 04:08:05 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45973) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eFz6O-00030e-P2 for emacs-devel@gnu.org; Sat, 18 Nov 2017 04:07:53 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eFz6K-00048g-MK for emacs-devel@gnu.org; Sat, 18 Nov 2017 04:07:52 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:54211) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eFz6K-00048Z-IO; Sat, 18 Nov 2017 04:07:48 -0500 Original-Received: from [176.228.60.248] (port=4236 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1eFz6J-0006oq-Sa; Sat, 18 Nov 2017 04:07:48 -0500 In-reply-to: <87ine8qdz8.fsf@gmail.com> (message from Alex on Sat, 18 Nov 2017 00:48:27 -0600) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:220260 Archived-At: > From: Alex > Date: Sat, 18 Nov 2017 00:48:27 -0600 > Cc: rudalics@gmx.at, tak.kunihiro@gmail.com, emacs-devel@gnu.org > > Eli Zaretskii writes: > >> 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. > > Oh, that's unfortunate. If you or someone else has better ideas for implementing menus on a TTY, let's hear them. > >> 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? > > (setq track-mouse t) > (setq count 0) > > (global-set-key [mouse-movement] > (lambda () > (interactive) > (message "%d" (setq count (1+ count))))) > > This will only message on the first mouse-movement event (after a > non-mouse-movement event), and after moving to a new character position. That's the intended behavior, see note_mouse_movement. > It also messages after a down-click, which feels like a bug. Not here, it doesn't. I only see a message after a movement to another glyph.