GNU bug report logs -
#8350
24.0.50; wrong bindings for remapped keys
Previous Next
Reported by: "Drew Adams" <drew.adams <at> oracle.com>
Date: Sat, 26 Mar 2011 20:04:01 UTC
Severity: normal
Merged with 6882,
8351
Found in version 24.0.50
Done: Chong Yidong <cyd <at> stupidchicken.com>
Bug is archived. No further changes may be made.
Full log
Message #11 received at 8350 <at> debbugs.gnu.org (full text, mbox):
> > (define-key ctl-x-map [remap forward-char] 'backward-char)
> > C-x C-h (says C-x f is bound to `forward-char')
>
> But ctl-x-map is never used as one of the active maps, it's always
> limited to being a prefix map bound to C-x, so the define-key
> above will have pretty much no effect.
It was a simplified example. And whether `ctl-x-map' is used as an active map
is irrelevant, I think, to the bugged behavior wrt `PREFIX-KEY C-h' described
here.
In any case, in my own use, where I uncovered this, the keymap is not
`ctl-x-map', just as the commands are not `forward-char' and `backward-char'.
In my use, `bmkp-this-buffer-jump', for example, is remapped to
`icicle-bookmark-this-buffer' in `icicle-mode-map' (a minor mode map). And the
remapping works as expected - `icicle-bookmark-this-buffer' gets called.
And all of the help output is correct - except for `PREFIX-KEY C-h'.
`C-h w bmkp-this-buffer-jump' says:
"bmkp-this-buffer-jump is remapped to icicle-bookmark-this-buffer which is on
C-x j ."
`C-h w icicle-bookmark-this-buffer' says:
"icicle-bookmark-this-buffer is on C-x j ."
`C-h f bmkp-this-buffer-jump' says it is remapped to etc., etc. All of the help
output is correct. Except the output from `C-x j C-h', which shows this:
"C-x j . bmkp-this-buffer-jump"
The code defining the initial binding of `bmkp-this-buffer-jump' includes this:
(define-prefix-command 'bmkp-jump-map)
(define-key ctl-x-map "j" bmkp-jump-map)
(define-key bmkp-jump-map "." 'bmkp-this-buffer-jump)
This bug report was last modified 13 years and 364 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.