From: "Ernest Adrogué" <nfdisco@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: unexpected result with keymap inheritance
Date: Tue, 22 Nov 2016 01:30:15 +0100 [thread overview]
Message-ID: <20161122003014.wzywiqst627yyp3l@doriath.local> (raw)
In-Reply-To: <jwv60nh53kv.fsf-monnier+gmane.emacs.help@gnu.org>
2016-11-21, 09:12 (-0500); Stefan Monnier escriu:
> > (set-keymap-parent parent-map global-map)
>
> Since `key-binding` checks global-map after the buffer-local map anyway,
> putting global-map as the parent of your buffer-local map has basically
> no effect.
>
> > (define-key child-map [?a] nil)
>
> This does not *remove* a binding from child-map. Instead it marks the
> key as unbound, thus hiding any potential corresponding binding in
> parent keymaps.
>
> Emacs does not provide a "remove binding" operation on keymaps.
>
> > (key-binding [?a])
> > => self-insert-command
>
> Here the binding was not found in the buffer-local map but in the global
> map instead.
Understood. Thanks for clarifying this.
next prev parent reply other threads:[~2016-11-22 0:30 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-21 0:28 unexpected result with keymap inheritance Ernest Adrogué
2016-11-21 14:12 ` Stefan Monnier
2016-11-21 17:12 ` Alex Kost
2016-11-22 2:55 ` Stefan Monnier
2016-11-22 19:07 ` Alex Kost
2016-11-23 1:12 ` Stefan Monnier
2016-11-23 9:51 ` Alex Kost
2016-11-23 13:42 ` Stefan Monnier
2016-11-23 21:23 ` Alex Kost
2016-11-24 2:20 ` Stefan Huchler
2016-11-23 10:16 ` Ernest Adrogué
2016-11-23 15:02 ` Stefan Monnier
2016-11-22 0:30 ` Ernest Adrogué [this message]
-- strict thread matches above, loose matches on Subject: below --
2016-11-23 5:43 Edward Flanigan
2016-11-23 9:05 ` Alex Kost
2016-11-23 14:47 ` Stefan Monnier
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20161122003014.wzywiqst627yyp3l@doriath.local \
--to=nfdisco@gmail.com \
--cc=help-gnu-emacs@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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.