unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* mode-local key binding of S-drag-mouse-1
@ 2011-10-12 11:22 Roland Winkler
  2011-10-12 13:03 ` Stefan Monnier
  0 siblings, 1 reply; 3+ messages in thread
From: Roland Winkler @ 2011-10-12 11:22 UTC (permalink / raw)
  To: emacs-devel

I'd like to have a mode-local key binding of S-drag-mouse-1.
But somehow this does not work because S-down-mouse-1 is globally
bound to mouse-appearance-menu and such down-mouse bindings seem to
take precedence over drag-mouse bindings. (I guess a down-mouse
binding could not work otherwise.)

But then what can I do to suppress the binding of S-drag-mouse-1?
Even if I try to unbind S-down-mouse-1 locally, this has no effect
because emacs will then look into the global keymap where it still
finds the global binding of S-down-mouse-1 (which I'd like to keep).

Any help is appreciated!

Roland



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: mode-local key binding of S-drag-mouse-1
  2011-10-12 11:22 mode-local key binding of S-drag-mouse-1 Roland Winkler
@ 2011-10-12 13:03 ` Stefan Monnier
  2011-10-12 14:01   ` Roland Winkler
  0 siblings, 1 reply; 3+ messages in thread
From: Stefan Monnier @ 2011-10-12 13:03 UTC (permalink / raw)
  To: Roland Winkler; +Cc: emacs-devel

> But then what can I do to suppress the binding of S-drag-mouse-1?
> Even if I try to unbind S-down-mouse-1 locally, this has no effect
> because emacs will then look into the global keymap where it still
> finds the global binding of S-down-mouse-1 (which I'd like to keep).

I think you can bind S-down-mouse-1 to `ignore'.


        Stefan



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: mode-local key binding of S-drag-mouse-1
  2011-10-12 13:03 ` Stefan Monnier
@ 2011-10-12 14:01   ` Roland Winkler
  0 siblings, 0 replies; 3+ messages in thread
From: Roland Winkler @ 2011-10-12 14:01 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: emacs-devel

On Wed Oct 12 2011 Stefan Monnier wrote:
> > But then what can I do to suppress the binding of S-drag-mouse-1?
> > Even if I try to unbind S-down-mouse-1 locally, this has no effect
> > because emacs will then look into the global keymap where it still
> > finds the global binding of S-down-mouse-1 (which I'd like to keep).
> 
> I think you can bind S-down-mouse-1 to `ignore'.

Thanks a lot! Maybe this should be mentioned in the elisp manual as
a useful alternative to locally unbinding a key.

Roland



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-10-12 14:01 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-12 11:22 mode-local key binding of S-drag-mouse-1 Roland Winkler
2011-10-12 13:03 ` Stefan Monnier
2011-10-12 14:01   ` Roland Winkler

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).