diff options
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/doc/news.txt | 1 | ||||
-rw-r--r-- | runtime/doc/options.txt | 11 | ||||
-rw-r--r-- | runtime/lua/vim/_meta/options.lua | 17 |
3 files changed, 25 insertions, 4 deletions
diff --git a/runtime/doc/news.txt b/runtime/doc/news.txt index a131934a8e..415a234254 100644 --- a/runtime/doc/news.txt +++ b/runtime/doc/news.txt @@ -329,6 +329,7 @@ OPTIONS • 'completeopt' flag "fuzzy" enables |fuzzy-matching| during |ins-completion|. • 'completeopt' flag "preinsert" highlights text to be inserted. +• 'wildmode' flag "noselect" shows 'wildmenu' without selecting an entry. • 'messagesopt' configures |:messages| and |hit-enter| prompt. • 'tabclose' controls which tab page to focus when closing a tab page. • 'eventignorewin' to persistently ignore events in a window. diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index a6f5f85d37..a3cef8bacb 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -7050,7 +7050,10 @@ A jump table for the options with a short description can be found at |Q_op|. "lastused" When completing buffer names and more than one buffer matches, sort buffers by time last used (other than the current buffer). - When there is only a single match, it is fully completed in all cases. + "noselect" Do not pre-select first menu item and start 'wildmenu' + if it is enabled. + When there is only a single match, it is fully completed in all cases + except when "noselect" is present. Examples of useful colon-separated values: "longest:full" Like "longest", but also start 'wildmenu' if it is @@ -7073,7 +7076,11 @@ A jump table for the options with a short description can be found at |Q_op|. set wildmode=list,full < List all matches without completing, then each full match >vim set wildmode=longest,list -< Complete longest common string, then list alternatives. +< Complete longest common string, then list alternatives >vim + set wildmode=noselect:full +< Display 'wildmenu' without completing, then each full match >vim + set wildmode=noselect:lastused,full +< Same as above, but sort buffers by time last used. More info here: |cmdline-completion|. *'wildoptions'* *'wop'* diff --git a/runtime/lua/vim/_meta/options.lua b/runtime/lua/vim/_meta/options.lua index 8df174a838..8e6acecc28 100644 --- a/runtime/lua/vim/_meta/options.lua +++ b/runtime/lua/vim/_meta/options.lua @@ -7691,7 +7691,10 @@ vim.go.wmnu = vim.go.wildmenu --- "lastused" When completing buffer names and more than one buffer --- matches, sort buffers by time last used (other than --- the current buffer). ---- When there is only a single match, it is fully completed in all cases. +--- "noselect" Do not pre-select first menu item and start 'wildmenu' +--- if it is enabled. +--- When there is only a single match, it is fully completed in all cases +--- except when "noselect" is present. --- --- Examples of useful colon-separated values: --- "longest:full" Like "longest", but also start 'wildmenu' if it is @@ -7729,7 +7732,17 @@ vim.go.wmnu = vim.go.wildmenu --- ```vim --- set wildmode=longest,list --- ``` ---- Complete longest common string, then list alternatives. +--- Complete longest common string, then list alternatives +--- +--- ```vim +--- set wildmode=noselect:full +--- ``` +--- Display 'wildmenu' without completing, then each full match +--- +--- ```vim +--- set wildmode=noselect:lastused,full +--- ``` +--- Same as above, but sort buffers by time last used. --- More info here: `cmdline-completion`. --- --- @type string |