Skip to content

Commit d82c918

Browse files
girishjichrisbra
authored andcommitted
runtime(doc): Improve doc for cmdline-autocomplete
Maybe this was unnecessary, but saw this: vim/vim#17854 Signed-off-by: Christian Brabandt <cb@256bit.org>
1 parent 46ec899 commit d82c918

2 files changed

Lines changed: 11 additions & 4 deletions

File tree

runtime/doc/builtin.txt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*builtin.txt* For Vim version 9.1. Last change: 2025 Aug 06
1+
*builtin.txt* For Vim version 9.1. Last change: 2025 Aug 08
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -12353,6 +12353,11 @@ wildtrigger() *wildtrigger()*
1235312353
To retain normal history navigation (up/down keys): >
1235412354
cnoremap <Up> <C-U><Up>
1235512355
cnoremap <Down> <C-U><Down>
12356+
<
12357+
To set an option specifically when performing a search, e.g.
12358+
to set 'pumheight': >
12359+
autocmd CmdlineEnter [/\?] set pumheight=8
12360+
autocmd CmdlineLeave [/\?] set pumheight&
1235612361
<
1235712362
Return value is always 0.
1235812363

runtime/doc/cmdline.txt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*cmdline.txt* For Vim version 9.1. Last change: 2025 Jul 21
1+
*cmdline.txt* For Vim version 9.1. Last change: 2025 Aug 08
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -927,7 +927,7 @@ to insert special things while typing you can use the CTRL-R command. For
927927
example, "%" stands for the current file name, while CTRL-R % inserts the
928928
current file name right away. See |c_CTRL-R|.
929929

930-
Note: If you want to avoid the effects of special characters in a Vim script
930+
Note: If you want to avoid the effects of special characters in a Vim script
931931
you may want to use |fnameescape()|. Also see |`=|.
932932

933933

@@ -1325,8 +1325,10 @@ Example: >
13251325
:au CmdwinLeave : let &cpt = b:cpt_save
13261326
This sets 'complete' to use completion in the current window for |i_CTRL-N|.
13271327
Another example: >
1328-
:au CmdwinEnter [/?] startinsert
1328+
:au CmdwinEnter [/\?] startinsert
13291329
This will make Vim start in Insert mode in the command-line window.
1330+
Note: The "?" needs to be escaped, as this is a |file-pattern|. See also
1331+
|cmdline-autocompletion|.
13301332

13311333
*cmdwin-char*
13321334
The character used for the pattern indicates the type of command-line:

0 commit comments

Comments
 (0)