[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: unexpected result with keymap inheritance

From: Alex Kost
Subject: Re: unexpected result with keymap inheritance
Date: Wed, 23 Nov 2016 12:05:03 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.95 (gnu/linux)

Edward Flanigan (2016-11-23 05:43 +0000) wrote:

> I use unbind-key quite a bit. It is in bind-key.el from the external 
> "use-package"
> (unbind-key "C-'"     org-mode-map)        ;; org-cycle-agenda-files

If you look at "C-h v org-mode-map", you'll find there something like


previously it was:

  (67108903 . org-cycle-agenda-files)

and my wish is to remove this sexp from 'org-mode-map' completely.

> See if that fits your use case.

No, it doesn't: 'bind-key' (thus 'unbind-key') is just a wrapper for
'define-key', and as Stefan wrote, 'define-key' does not remove a key
from a keymap, it just binds it to nil.  So when you press the key, you
get "<key> is undefined", while I want to remove the key (to make a key
from a parent map take precedence).


reply via email to

[Prev in Thread] Current Thread [Next in Thread]