* More bindkey weirdness in 3.0.5
@ 1998-03-24 18:06 Bart Schaefer
0 siblings, 0 replies; only message in thread
From: Bart Schaefer @ 1998-03-24 18:06 UTC (permalink / raw)
To: zsh-workers
You can probably guess what got me started on this. Anyway, consider the
output of the following function (which must be run in a freshly-started
zsh -f or it is likely to exit prematurely due to the previous bug):
bindfoo () {
bindkey -v
# If the next line is uncommented, zsh crashes a few commands later
# bindkey -r '\e'
echo +++ BEGIN +++ ; bindkey
bindkey -r '\e[A'
bindkey -r '\e[B'
bindkey -r '\e[C'
bindkey -r '\e[D'
echo +++ REMOVED +++ ; bindkey
bindkey "[A" up-line-or-history
bindkey "[B" down-line-or-history
bindkey "[C" forward-char
bindkey "[D" backward-char
echo +++ ADDED 1 +++ ; bindkey
bindkey -a "[A" up-line-or-history
bindkey -a "[B" down-line-or-history
bindkey -a "[C" forward-char
bindkey -a "[D" backward-char
echo +++ ADDED 2 +++ ; bindkey
bindkey -a '\e[A' up-line-or-history
bindkey -a '\e[B' down-line-or-history
bindkey -a '\e[C' forward-char
bindkey -a '\e[D' backward-char
echo +++ ADDED 3 +++ ; bindkey
bindkey -e
}
Following "+++ BEGIN +++", we have (in part):
"^[" prefix
"^[" vi-cmd-mode
"^[[A" up-line-or-history
"^[[B" down-line-or-history
"^[[C" forward-char
"^[[D" backward-char
Following "+++ REMOVED +++" (so far so good):
"^[" vi-cmd-mode
Following "+++ ADDED 1 +++" (first bug):
"^[" vi-cmd-mode
"[" prefix
"[A" self-insert <--- WHAT?
"[B" down-line-or-history
"[C" forward-char
"[D" backward-char
Following "+++ ADDED 2 +++" (where'd "[A" go?):
"^[" vi-cmd-mode
"[" prefix
"[B" down-line-or-history
"[C" forward-char
"[D" backward-char
Finally, following "+++ ADDED 3 +++':
"^[" vi-cmd-mode
"[" prefix
"^[[A" vi-cmd-mode <-- WHAT?
"^[[B" down-line-or-history
"^[[C" forward-char
"^[[D" backward-char
"[B" down-line-or-history
"[C" forward-char
"[D" backward-char
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1998-03-24 18:09 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-03-24 18:06 More bindkey weirdness in 3.0.5 Bart Schaefer
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
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 NNTP newsgroup(s).