unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Robert Pluim <rpluim@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: Didier <didibus@gmail.com>, 49803@debbugs.gnu.org
Subject: bug#49803: 27.2; Mouse wheel on MacOS is reported as mouse-4 and mouse-5, but Emacs mwheel seems to use wheel-up/wheel-down instead
Date: Mon, 09 Aug 2021 12:29:32 +0200	[thread overview]
Message-ID: <87k0kusygj.fsf@gmail.com> (raw)
In-Reply-To: <83r1fcm6rh.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 02 Aug 2021 14:21:38 +0300")

>>>>> On Mon, 02 Aug 2021 14:21:38 +0300, Eli Zaretskii <eliz@gnu.org> said:

    >> From: Didier <didibus@gmail.com>
    >> Date: Sun, 1 Aug 2021 23:44:05 -0700
    >> Cc: 49803@debbugs.gnu.org
    >> 
    >> In macOS, when running Emacs in GUI, the wheel is received as <wheel-up> and <wheel-down> and it all
    >> works.
    >> 
    >> But in macOS, when running inside a terminal such as Terminal.app or iTerm2, the wheel is received as
    >> <mouse-4> and <mouse-5> and it no longer works, because the defcustom is not smart enough to check if
    >> we are running in GUI or not.
    >>

Hmm, I receive those as 'up' and 'down' in Terminal.app. And in iTerm2
Emacs doesnʼt receive them at all, even with 'mouse event reporting'
turned on. Does it depend on the configured terminal type?

    >> So I think it should be modified to something like:
    >> 
    >> (if (or (featurep 'w32-win) (and (display-graphic-p) (featurep 'ns-win)))
    >> 'wheel-down
    >> 'mouse-5)

    Eli> Did you try that?

    Eli> The problem here is that the initial frame is not a GUI frame even in
    Eli> a GUI session, so the defcustom could pick up the wrong value.

If we knew where and how the events were being received by emacs we
could map them to wheel-{up,down}, but Iʼve not succeeded there.

Robert
-- 





  reply	other threads:[~2021-08-09 10:29 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-01  2:27 bug#49803: 27.2; Mouse wheel on MacOS is reported as mouse-4 and mouse-5, but Emacs mwheel seems to use wheel-up/wheel-down instead Didier
2021-08-01  6:18 ` Eli Zaretskii
2021-08-02  6:44   ` Didier
2021-08-02 11:21     ` Eli Zaretskii
2021-08-09 10:29       ` Robert Pluim [this message]
2021-08-10 12:44         ` Eli Zaretskii
2021-08-11  9:24           ` Robert Pluim
2021-08-11 12:03             ` Eli Zaretskii
2021-08-11 14:59               ` Robert Pluim
2021-08-11 16:41                 ` Eli Zaretskii
2021-08-11 17:10                   ` Robert Pluim
2021-08-11 17:38                     ` Eli Zaretskii
2021-08-12  7:48                       ` Robert Pluim
2021-08-12  8:11                         ` Eli Zaretskii
2021-08-12  9:54                           ` Robert Pluim
2022-08-22 10:38                     ` Lars Ingebrigtsen
2022-08-22 11:59                       ` Robert Pluim
2022-08-22 12:03                         ` Lars Ingebrigtsen
2022-08-22 12:12                       ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-08-22 12:14                         ` Lars Ingebrigtsen
2022-08-22 13:14                           ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k0kusygj.fsf@gmail.com \
    --to=rpluim@gmail.com \
    --cc=49803@debbugs.gnu.org \
    --cc=didibus@gmail.com \
    --cc=eliz@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).