[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#14793: 23.4; Cannot bind a function to a sequence of two mouse keys
From: |
Eli Zaretskii |
Subject: |
bug#14793: 23.4; Cannot bind a function to a sequence of two mouse keys |
Date: |
Tue, 03 Oct 2017 17:33:06 +0300 |
> From: Alex <agrambot@gmail.com>
> Cc: 14793@debbugs.gnu.org, npostavs@users.sourceforge.net,
> regularclockwork@gmail.com
> Date: Mon, 02 Oct 2017 21:59:37 -0600
>
> > I just asked that question because my reading of the code is that this
> > is not supported. Maybe I'm misreading: keyboard.c:read_char is not
> > for the faint at heart.
>
> Yeah, I'm having trouble going through it. Is there a way to make it
> supported, though? For example, what about catching the error around
> read_char_x_menu_prompt (keyboard.c:L2683) and not exiting if an error
> was thrown?
That's hardly a clean solution. A clean solution would avoid calling
Fx_popup_menu when it detects the situation we are talking about.
> >> Also, "(emacs) Mouse Buttons" states that "You can put more than one
> >> mouse button in a key sequence, but it isn’t usual to do so.".
> >>
> >> How would one do this if a mouse click can't be a prefix key?
> >
> > By making a menu, I presume.
>
> Do you mean those mentioned in "(emacs) Menu Mouse Clicks"? Does
> clicking in those menus count as key sequences?
Yes, of course. You can see that with "C-h l", for example. Also,
every non-leaf menu item is a keymap.