1
0
Fork 0

Bind more unbound keys in viins and vicmd to nothing

Unbound keys in viins or vicmd mode have undefined results. Bind
two more of these to nothing to avoid this.
pull/1471/head
Samantha McVey 7 years ago committed by Kaleb Elwert
parent 00f1d92ed8
commit 752f64f085

@ -28,9 +28,11 @@ WORDCHARS='*?_-.[]~&;!#$%^(){}<>'
zmodload zsh/terminfo zmodload zsh/terminfo
typeset -gA key_info typeset -gA key_info
key_info=( key_info=(
'Control' '\C-' 'Control' '\C-'
'ControlLeft' '\e[1;5D \e[5D \e\e[D \eOd' 'ControlLeft' '\e[1;5D \e[5D \e\e[D \eOd'
'ControlRight' '\e[1;5C \e[5C \e\e[C \eOc' 'ControlRight' '\e[1;5C \e[5C \e\e[C \eOc'
'ControlPageUp' '\e[5;5~'
'ControlPageDown' '\e[6;5~'
'Escape' '\e' 'Escape' '\e'
'Meta' '\M-' 'Meta' '\M-'
'Backspace' "^?" 'Backspace' "^?"
@ -305,6 +307,8 @@ unbound_keys=(
"${key_info[F12]}" "${key_info[F12]}"
"${key_info[PageUp]}" "${key_info[PageUp]}"
"${key_info[PageDown]}" "${key_info[PageDown]}"
"${key_info[ControlPageUp]}"
"${key_info[ControlPageDown]}"
) )
for keymap in $unbound_keys; do for keymap in $unbound_keys; do
bindkey -M viins "${keymap}" _prezto-zle-noop bindkey -M viins "${keymap}" _prezto-zle-noop

Loading…
Cancel
Save