[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: unexpected result with keymap inheritance
From: |
Stefan Monnier |
Subject: |
Re: unexpected result with keymap inheritance |
Date: |
Mon, 21 Nov 2016 09:12:58 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) |
> (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.
Stefan
- unexpected result with keymap inheritance, Ernest Adrogué, 2016/11/20
- Re: unexpected result with keymap inheritance,
Stefan Monnier <=
- Re: unexpected result with keymap inheritance, Alex Kost, 2016/11/21
- Re: unexpected result with keymap inheritance, Stefan Monnier, 2016/11/22
- Re: unexpected result with keymap inheritance, Alex Kost, 2016/11/22
- Re: unexpected result with keymap inheritance, Stefan Monnier, 2016/11/22
- Re: unexpected result with keymap inheritance, Alex Kost, 2016/11/23
- Re: unexpected result with keymap inheritance, Stefan Monnier, 2016/11/23
- Re: unexpected result with keymap inheritance, Alex Kost, 2016/11/23
- Re: unexpected result with keymap inheritance, Stefan Huchler, 2016/11/24
- Re: unexpected result with keymap inheritance, Ernest Adrogué, 2016/11/23
- Re: unexpected result with keymap inheritance, Stefan Monnier, 2016/11/23