about summary refs log tree commit diff
path: root/Completion/Core/_main_complete
diff options
context:
space:
mode:
authorSven Wischnowsky <wischnow@users.sourceforge.net>2000-04-18 07:36:55 +0000
committerSven Wischnowsky <wischnow@users.sourceforge.net>2000-04-18 07:36:55 +0000
commitfe65ab1dd85195ae0bef29f11aea74209c00cb8b (patch)
tree1e435897e589f4e0e66f89ef6128bd5752b4e056 /Completion/Core/_main_complete
parent59da43689af6ca1048f2e956f10c18cd17774f2a (diff)
downloadzsh-fe65ab1dd85195ae0bef29f11aea74209c00cb8b.tar.gz
zsh-fe65ab1dd85195ae0bef29f11aea74209c00cb8b.tar.xz
zsh-fe65ab1dd85195ae0bef29f11aea74209c00cb8b.zip
completion list scrolling cleanup; *STATUS renamed to *PROMPT, styles for new used parameters, use local keymap when waiting at list-prompt (10801)
Diffstat (limited to 'Completion/Core/_main_complete')
-rw-r--r--Completion/Core/_main_complete10
1 files changed, 10 insertions, 0 deletions
diff --git a/Completion/Core/_main_complete b/Completion/Core/_main_complete
index 795fe7442..0c0bd05b6 100644
--- a/Completion/Core/_main_complete
+++ b/Completion/Core/_main_complete
@@ -56,6 +56,16 @@ _def_menu_style=( "$_last_menu_style[@]"
                 )
 _last_menu_style=()
 
+if zstyle -s ":completion:${curcontext}:default" list-prompt LISTPROMPT &&
+   [[ -n "$LISTPROMPT" ]]; then
+  zmodload -i zsh/complist
+  compstate[list_max]=scroll
+fi
+zstyle -s ":completion:${curcontext}:default" select-prompt SELECTPROMPT ||
+    SELECTPROMPT='%SScrolling active: current selection at %p'
+zstyle -s ":completion:${curcontext}:default" select-scroll SELECTSCROLL ||
+    SELECTSCROLL=1
+
 # Get the names of the completers to use in the positional parameters.
 
 if (( $# )); then