GNU bug report logs - #11680
flyspell should use mouse-3 instead of mouse-2

Previous Next

Package: emacs;

Reported by: Le Wang <l26wang <at> gmail.com>

Date: Tue, 12 Jun 2012 12:28:01 UTC

Severity: minor

Fixed in version 28.1

Done: Stefan Kangas <stefan <at> marxist.se>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 11680 in the body.
You can then email your comments to 11680 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Tue, 12 Jun 2012 12:28:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Le Wang <l26wang <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Tue, 12 Jun 2012 12:28:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Le Wang <l26wang <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: flyspell should use mouse-3 instead of mouse-2
Date: Tue, 12 Jun 2012 20:23:54 +0800
[Message part 1 (text/plain, inline)]
This makes sense because it's a context menu which is mouse-3 in modern UIs.

See Stefan's answer here:
http://stackoverflow.com/questions/10973000/emacs-23-4-mouse-2-behaviour-on-os-x-10-7

-- 
Le
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Fri, 01 Nov 2019 18:22:02 GMT) Full text and rfc822 format available.

Message #8 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Le Wang <l26wang <at> gmail.com>
Cc: 11680 <at> debbugs.gnu.org
Subject: Re: flyspell should use mouse-3 instead of mouse-2
Date: Fri, 01 Nov 2019 19:21:35 +0100
[Message part 1 (text/plain, inline)]
Le Wang <l26wang <at> gmail.com> writes:

> This makes sense because it's a context menu which is mouse-3 in
> modern UIs.
>
> See Stefan's answer here:
> http://stackoverflow.com/questions/10973000/emacs-23-4-mouse-2-behaviour-on-os-x-10-7

So Stefan writes at the link: "Rather flyspell needs to be fixed to
pop up its menu on mouse-3 since it's really more like a context
menu. I.e. I recommend a M-x report-emacs-bug about it."

I agree with this.  Any objections to the attached patch?

Best regards,
Stefan Kangas

[0001-Move-flyspell-correct-word-to-mouse-3.patch (text/x-diff, inline)]
From f9b06855b129f4472908893d411d70b20fd0edfe Mon Sep 17 00:00:00 2001
From: Stefan Kangas <stefankangas <at> gmail.com>
Date: Thu, 31 Oct 2019 02:15:56 +0100
Subject: [PATCH] Move flyspell-correct-word to mouse-3

* lisp/textmodes/flyspell.el (flyspell-mouse-map): Bind
'flyspell-correct-word' to 'mouse-3' instead of 'mouse-2'.
(Bug#11680)

* doc/emacs/fixit.texi (Spelling): Document it.
* etc/NEWS: Announce it.
---
 doc/emacs/fixit.texi       | 2 +-
 etc/NEWS                   | 9 +++++++++
 lisp/textmodes/flyspell.el | 2 +-
 3 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/doc/emacs/fixit.texi b/doc/emacs/fixit.texi
index fc610583c8..90110e5b41 100644
--- a/doc/emacs/fixit.texi
+++ b/doc/emacs/fixit.texi
@@ -441,7 +441,7 @@ Spelling
 @findex flyspell-auto-correct-word
 @findex flyspell-correct-word-before-point
   When Flyspell mode highlights a word as misspelled, you can click on
-it with @kbd{mouse-2} (@code{flyspell-correct-word}) to display a menu
+it with @kbd{mouse-3} (@code{flyspell-correct-word}) to display a menu
 of possible corrections and actions.  In addition, @kbd{C-.} or
 @kbd{@key{ESC}-@key{TAB}} (@code{flyspell-auto-correct-word}) will
 propose various successive corrections for the word at point, and
diff --git a/etc/NEWS b/etc/NEWS
index cd1e46bb87..21c118e6ae 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -2197,6 +2197,15 @@ file-local variable, you may need to update the value.
 *** Declare 'define-overload' and 'define-child-mode' as obsolete
 *** Rename several internal functions to use a ''mode-local-' prefix
 
++++
+** Flyspell mode
+
+*** Corrections and actions menu is now bound to mouse-3.
+When Flyspell mode highlights a word as misspelled, you can click on
+it to display a menu of possible corrections and actions.  This was
+previously bound to mouse-2 (usually the middle mouse button), but has
+now been moved to mouse-3 (usually the right mouse button).
+
 
 * New Modes and Packages in Emacs 27.1
 
diff --git a/lisp/textmodes/flyspell.el b/lisp/textmodes/flyspell.el
index ce788207cf..36da29b6ac 100644
--- a/lisp/textmodes/flyspell.el
+++ b/lisp/textmodes/flyspell.el
@@ -460,7 +460,7 @@ flyspell-prog-mode
 ;;*---------------------------------------------------------------------*/
 (defvar flyspell-mouse-map
   (let ((map (make-sparse-keymap)))
-    (define-key map [mouse-2] 'flyspell-correct-word)
+    (define-key map [mouse-3] 'flyspell-correct-word)
     map)
   "Keymap for Flyspell to put on erroneous words.")
 
-- 
2.20.1


Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Fri, 01 Nov 2019 19:08:01 GMT) Full text and rfc822 format available.

Message #11 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Fri, 01 Nov 2019 21:07:44 +0200
> From: Stefan Kangas <stefan <at> marxist.se>
> Date: Fri, 01 Nov 2019 19:21:35 +0100
> Cc: 11680 <at> debbugs.gnu.org
> 
> > This makes sense because it's a context menu which is mouse-3 in
> > modern UIs.
> >
> > See Stefan's answer here:
> > http://stackoverflow.com/questions/10973000/emacs-23-4-mouse-2-behaviour-on-os-x-10-7
> 
> So Stefan writes at the link: "Rather flyspell needs to be fixed to
> pop up its menu on mouse-3 since it's really more like a context
> menu. I.e. I recommend a M-x report-emacs-bug about it."
> 
> I agree with this.  Any objections to the attached patch?

This would be a backward-incompatible change, so we cannot just change
it because someone asked for that.  I, for example, use that menu on
mouse-2 all the time.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Sat, 02 Nov 2019 00:26:01 GMT) Full text and rfc822 format available.

Message #14 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Sat, 2 Nov 2019 01:25:01 +0100
Eli Zaretskii <eliz <at> gnu.org> writes:
> This would be a backward-incompatible change, so we cannot just change
> it because someone asked for that.  I, for example, use that menu on
> mouse-2 all the time.

OK.  How about adding the mouse-3 key binding without removing the mouse-2 one?

Best regards,
Stefan Kangas




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Sat, 02 Nov 2019 07:52:01 GMT) Full text and rfc822 format available.

Message #17 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Sat, 02 Nov 2019 09:51:14 +0200
> From: Stefan Kangas <stefan <at> marxist.se>
> Date: Sat, 2 Nov 2019 01:25:01 +0100
> Cc: l26wang <at> gmail.com, 11680 <at> debbugs.gnu.org
> 
> Eli Zaretskii <eliz <at> gnu.org> writes:
> > This would be a backward-incompatible change, so we cannot just change
> > it because someone asked for that.  I, for example, use that menu on
> > mouse-2 all the time.
> 
> OK.  How about adding the mouse-3 key binding without removing the mouse-2 one?

Fine with me, but that button is already bound to
mouse-save-then-kill.  I never use it, but what will those who do say?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Thu, 16 Jan 2020 01:51:02 GMT) Full text and rfc822 format available.

Message #20 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: l26wang <at> gmail.com, 11680 <at> debbugs.gnu.org
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Thu, 16 Jan 2020 02:50:19 +0100
[Message part 1 (text/plain, inline)]
Eli Zaretskii <eliz <at> gnu.org> writes:

>> Eli Zaretskii <eliz <at> gnu.org> writes:
>> > This would be a backward-incompatible change, so we cannot just change
>> > it because someone asked for that.  I, for example, use that menu on
>> > mouse-2 all the time.
>> 
>> OK.  How about adding the mouse-3 key binding without removing the mouse-2 one?
>
> Fine with me, but that button is already bound to
> mouse-save-then-kill.  I never use it, but what will those who do say?

Since this key binding is only in flyspell-mouse-map, it will only be
rebound when the mouse pointer is over a misspelled word.  Note that
mouse-2 is normally bound to mouse-yank-primary.

I therefore don't think it will be a big problem in practice.  On the
contrary, I believe that having the context menu on the right mouse
button will feel more natural and be more discoverable to users.

I have attached an updated patch below.  If there are no objections to
it, would this change be safe for the release branch, or should it go
to master?

Best regards,
Stefan Kangas

[0001-Bind-flyspell-correct-word-to-mouse-3-also.patch (text/x-diff, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Thu, 16 Jan 2020 14:47:02 GMT) Full text and rfc822 format available.

Message #23 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: l26wang <at> gmail.com, 11680 <at> debbugs.gnu.org
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Thu, 16 Jan 2020 16:46:45 +0200
> From: Stefan Kangas <stefan <at> marxist.se>
> Cc: 11680 <at> debbugs.gnu.org,  l26wang <at> gmail.com
> Date: Thu, 16 Jan 2020 02:50:19 +0100
> 
> > Fine with me, but that button is already bound to
> > mouse-save-then-kill.  I never use it, but what will those who do say?
> 
> Since this key binding is only in flyspell-mouse-map, it will only be
> rebound when the mouse pointer is over a misspelled word.  Note that
> mouse-2 is normally bound to mouse-yank-primary.

I don't see how this resolves the backward-compatibility issue, sorry.

> I therefore don't think it will be a big problem in practice.  On the
> contrary, I believe that having the context menu on the right mouse
> button will feel more natural and be more discoverable to users.

Once again, we are not talking about adding a new feature from
scratch, we are talking about changing a very old behavior.  So
whether it's more natural or not is of secondary importance for this
decision.

I'm okay with making this conditional on some user option, but I
object to an unconditional change.

> I have attached an updated patch below.  If there are no objections to
> it, would this change be safe for the release branch, or should it go
> to master?

In any case, we don't add new features on the release branch, we only
fix bugs there.

Thanks.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Thu, 13 Aug 2020 06:11:02 GMT) Full text and rfc822 format available.

Message #26 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Wed, 12 Aug 2020 23:10:11 -0700
Eli Zaretskii <eliz <at> gnu.org> writes:

>> From: Stefan Kangas <stefan <at> marxist.se>
>> Cc: 11680 <at> debbugs.gnu.org,  l26wang <at> gmail.com
>> Date: Thu, 16 Jan 2020 02:50:19 +0100
>>
>> > Fine with me, but that button is already bound to
>> > mouse-save-then-kill.  I never use it, but what will those who do say?
>>
>> Since this key binding is only in flyspell-mouse-map, it will only be
>> rebound when the mouse pointer is over a misspelled word.  Note that
>> mouse-2 is normally bound to mouse-yank-primary.
>
> I don't see how this resolves the backward-compatibility issue, sorry.

Sorry for the very late reply here.

The change in behaviour is what it is, but I think that users should be
able to get used to the new behaviour.

In fact, they might even like it more.  I think there is something to be
said about (in this case) aligning ourselves with most other editors or
programs people use: Firefox, LibreOffice, VSCode, etc.

(This goes even for users that don't read NEWS: The words are clearly
highlighted, so it should be intuitive and apparent what is going on (at
least after a while): to invoke mouse-save-then-kill, simply click
slightly to the left or right of the highlighted word.)

> Once again, we are not talking about adding a new feature from
> scratch, we are talking about changing a very old behavior.  So
> whether it's more natural or not is of secondary importance for this
> decision.
>
> I'm okay with making this conditional on some user option, but I
> object to an unconditional change.

That is a good solution, if the default is to enable it.  That would
allow users to easily switch back if they don't like the new behaviour.

Best regards,
Stefan Kangas




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Thu, 13 Aug 2020 13:08:01 GMT) Full text and rfc822 format available.

Message #29 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Thu, 13 Aug 2020 16:07:40 +0300
> From: Stefan Kangas <stefan <at> marxist.se>
> Date: Wed, 12 Aug 2020 23:10:11 -0700
> Cc: l26wang <at> gmail.com, 11680 <at> debbugs.gnu.org
> 
> > I'm okay with making this conditional on some user option, but I
> > object to an unconditional change.
> 
> That is a good solution, if the default is to enable it.  That would
> allow users to easily switch back if they don't like the new behaviour.

I think it should be an opt-in behavior, conditional on a user
option.  We can later see if it is popular enough to make that the
default behavior.

Thanks.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Sat, 15 Aug 2020 01:10:01 GMT) Full text and rfc822 format available.

Message #32 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Fri, 14 Aug 2020 18:08:59 -0700
[Message part 1 (text/plain, inline)]
Eli Zaretskii <eliz <at> gnu.org> writes:

> I think it should be an opt-in behavior, conditional on a user
> option.  We can later see if it is popular enough to make that the
> default behavior.

OK.  How about the attached patch?

Best regards,
Stefan Kangas
[0001-Add-new-option-flyspell-correct-on-mouse-3.patch (text/x-diff, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Sat, 15 Aug 2020 17:54:02 GMT) Full text and rfc822 format available.

Message #35 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Sat, 15 Aug 2020 20:53:21 +0300
> From: Stefan Kangas <stefan <at> marxist.se>
> Date: Fri, 14 Aug 2020 18:08:59 -0700
> Cc: l26wang <at> gmail.com, 11680 <at> debbugs.gnu.org
> 
> OK.  How about the attached patch?

LGTM.

> -@w{@kbd{C-c $}} (@code{flyspell-correct-word-before-point}) will pop up a
> -menu of possible corrections.  Of course, you can always correct the
> -misspelled word by editing it manually in any way you like.
> +@w{@kbd{C-c $}} (@code{flyspell-correct-word-before-point}) will pop
> +up a misspelled word by editing it manually in any way you like.

I don't understand this part of the change: "C-c $" does pop up a menu
for me.

> +*** Corrections and actions menu optionally bound to mouse-3.

"... can be optionally bound to ..." is better, IMO.

> +(defcustom flyspell-correct-on-mouse-3 nil
> +  "Non-nil means to bind `mouse-3' to `flyspell-correct-word'.
> +If this is set, also unbind `mouse-2'."
> +  :type 'boolean
> +  :set 'flyspell--set-correct-on-mouse-3)

:version tag missing here.

Thanks.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Sun, 16 Aug 2020 17:54:01 GMT) Full text and rfc822 format available.

Message #38 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Sun, 16 Aug 2020 10:53:08 -0700
close 11680 28.1
thanks

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

>> OK.  How about the attached patch?
>
> LGTM.

Thanks.  Fixed your comments and pushed to master as commit 1eae0a8784.

Best regards,
Stefan Kangas




bug marked as fixed in version 28.1, send any further explanations to 11680 <at> debbugs.gnu.org and Le Wang <l26wang <at> gmail.com> Request was from Stefan Kangas <stefan <at> marxist.se> to control <at> debbugs.gnu.org. (Sun, 16 Aug 2020 17:54:01 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Mon, 17 Aug 2020 01:11:02 GMT) Full text and rfc822 format available.

Message #43 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Juri Linkov <juri <at> linkov.net>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Mon, 17 Aug 2020 03:38:38 +0300
> +(defcustom flyspell-correct-on-mouse-3 nil
> +  "Non-nil means to bind `mouse-3' to `flyspell-correct-word'.
> +If this is set, also unbind `mouse-2'."
> +  :type 'boolean
> +  :set 'flyspell--set-correct-on-mouse-3)

In the future, a more general option would be preferable
that would enable using the right mouse button to pop up
context menus in more places in Emacs like most other apps do
nowadays, i.e. something like cua-emulation mode but for mouse-3.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Mon, 17 Aug 2020 02:39:01 GMT) Full text and rfc822 format available.

Message #46 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Drew Adams <drew.adams <at> oracle.com>
To: Juri Linkov <juri <at> linkov.net>, Stefan Kangas <stefan <at> marxist.se>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: RE: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Sun, 16 Aug 2020 19:38:35 -0700 (PDT)
> In the future, a more general option would be preferable
> that would enable using the right mouse button to pop up
> context menus in more places in Emacs like most other apps do
> nowadays, i.e. something like cua-emulation mode but for mouse-3.

(Caveat: I haven't followed this thread, at all.)

But if `mouse-3' behavior that allows for context-specific
popup menus is what's sought, then `mouse3.el' fulfills
that need, and with a great deal of flexibility.  This has
been the case since 2010.

Not only does it provide for context menus, but it does so
without sacrificing the other useful vanilla `mouse-3'
behaviors, which are also useful.  It adds to, instead of
replaces, existing `mouse-3' behavior.  It's compatible
with what Emacs users expect in general for `mouse-3'.

https://www.emacswiki.org/emacs/Mouse3

https://www.emacswiki.org/emacs/download/mouse3.el




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Mon, 17 Aug 2020 14:02:02 GMT) Full text and rfc822 format available.

Message #49 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Drew Adams <drew.adams <at> oracle.com>, Juri Linkov <juri <at> linkov.net>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: RE: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Mon, 17 Aug 2020 14:01:37 +0000
Drew Adams <drew.adams <at> oracle.com> writes:

>> In the future, a more general option would be preferable
>> that would enable using the right mouse button to pop up
>> context menus in more places in Emacs like most other apps do
>> nowadays, i.e. something like cua-emulation mode but for mouse-3.

Agreed, that would be very useful.

> (Caveat: I haven't followed this thread, at all.)
>
> But if `mouse-3' behavior that allows for context-specific
> popup menus is what's sought, then `mouse3.el' fulfills
> that need, and with a great deal of flexibility.  This has
> been the case since 2010.
>
> Not only does it provide for context menus, but it does so
> without sacrificing the other useful vanilla `mouse-3'
> behaviors, which are also useful.  It adds to, instead of
> replaces, existing `mouse-3' behavior.  It's compatible
> with what Emacs users expect in general for `mouse-3'.
>
> https://www.emacswiki.org/emacs/Mouse3
>
> https://www.emacswiki.org/emacs/download/mouse3.el

Thanks, I didn't know about this library but will look into it in
detail.  Is there anything stopping us from incuding this library in
Emacs?  Would it be suitable for general use?

Best regards,
Stefan Kangas




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Mon, 17 Aug 2020 15:13:02 GMT) Full text and rfc822 format available.

Message #52 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Drew Adams <drew.adams <at> oracle.com>
To: Stefan Kangas <stefan <at> marxist.se>, Juri Linkov <juri <at> linkov.net>
Cc: 11680 <at> debbugs.gnu.org, l26wang <at> gmail.com
Subject: RE: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Mon, 17 Aug 2020 08:12:18 -0700 (PDT)
> > if `mouse-3' behavior that allows for context-specific
> > popup menus is what's sought, then `mouse3.el' fulfills
> > that need, and with a great deal of flexibility.  This has
> > been the case since 2010.
> >
> > Not only does it provide for context menus, but it does so
> > without sacrificing the other useful vanilla `mouse-3'
> > behaviors, which are also useful.  It adds to, instead of
> > replaces, existing `mouse-3' behavior.  It's compatible
> > with what Emacs users expect in general for `mouse-3'.
> > https://www.emacswiki.org/emacs/Mouse3
> > https://www.emacswiki.org/emacs/download/mouse3.el
> 
> Thanks, I didn't know about this library but will look into it in
> detail.  Is there anything stopping us from incuding this library in
> Emacs?  Would it be suitable for general use?

Yes, no problem.

As is generally the case with my libraries, there can
be code that accommodates backward compatibility, and
there can be code that does something extra/better if
some of my libraries (or some other libraries) have
been loaded.

For vanilla GNU Emacs such conditional code can be
removed or the conditional test can be removed.  E.g.,
(fboundp 'string-insert-rectangle) is for Emacs 24.4+.

Examples of code that makes use of other libraries:

* If library `isearch-prop.el' has been loaded then
  menu items `Isearch' and `Isearch Regexp' are there
  for searching the region.  (Submenu `Search/Replace'.)

* If library `highlight.el' has been loaded then menu
  items `Copy Text Properties' and `Yank Copied Text
  Properties' are available for acting on the region.
  (Submenus `Copy' and `Remove/Replace'.)

* If library `boxquote.el' has been loaded then menu
  items `Boxquote' and `Unboxquote' are there.
  (Submenu `Change Text'.)

* If `unaccent.el' is loaded then item `Remove Accents'.
  (Submenu `Change Text'.)

* If `highlight.el' is loaded then submenu `Highlight'
  is available.

* If `ebnf2ps.el' is loaded then `BNF PostScript Analyze',
  `BNF PostScript Print', and `BNF PostScript Save'.

* If `bookmark+.el' then `Highlight Bookmarks' and
  `Create Bookmarks Matching'.  (Submenu `Misc'.)

* If `help-fns+.el' then `Describe File' and `Describe
  Package'.  (Submenu `Thing at Pointer'.)

* If `highlight.el' then items `Highlight Symbol' and
  `Unhighlight Symbol'.  (Submenu `Thing at Pointer'.)




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Wed, 19 Aug 2020 03:16:02 GMT) Full text and rfc822 format available.

Message #55 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Juri Linkov <juri <at> linkov.net>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: Eli Zaretskii <eliz <at> gnu.org>, l26wang <at> gmail.com, 11680 <at> debbugs.gnu.org
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Wed, 19 Aug 2020 04:07:37 +0300
>> I think it should be an opt-in behavior, conditional on a user
>> option.  We can later see if it is popular enough to make that the
>> default behavior.
>
> OK.  How about the attached patch?

A small problem: after customizing flyspell-use-mouse-3-for-menu to t,
hovering over a misspelled word displays a misleading tooltip
"mouse-2: correct word at point"
 =======




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Wed, 19 Aug 2020 10:01:02 GMT) Full text and rfc822 format available.

Message #58 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Juri Linkov <juri <at> linkov.net>
Cc: Eli Zaretskii <eliz <at> gnu.org>, l26wang <at> gmail.com, 11680 <at> debbugs.gnu.org
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Wed, 19 Aug 2020 10:00:07 +0000
Juri Linkov <juri <at> linkov.net> writes:

> A small problem: after customizing flyspell-use-mouse-3-for-menu to t,
> hovering over a misspelled word displays a misleading tooltip
> "mouse-2: correct word at point"
>  =======

Thanks for reporting that.  I'll look into it.

Best regards,
Stefan Kangas




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#11680; Package emacs. (Thu, 27 Aug 2020 05:15:02 GMT) Full text and rfc822 format available.

Message #61 received at 11680 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Juri Linkov <juri <at> linkov.net>
Cc: Eli Zaretskii <eliz <at> gnu.org>, l26wang <at> gmail.com, 11680 <at> debbugs.gnu.org
Subject: Re: bug#11680: flyspell should use mouse-3 instead of mouse-2
Date: Wed, 26 Aug 2020 22:14:27 -0700
Stefan Kangas <stefan <at> marxist.se> writes:

> Juri Linkov <juri <at> linkov.net> writes:
>
>> A small problem: after customizing flyspell-use-mouse-3-for-menu to t,
>> hovering over a misspelled word displays a misleading tooltip
>> "mouse-2: correct word at point"
>>  =======
>
> Thanks for reporting that.  I'll look into it.

Fixed on master (commit 15f6c07f15).




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Thu, 24 Sep 2020 11:24:09 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 213 days ago.

Previous Next


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