diff options
author | Bram Moolenaar <Bram@vim.org> | 2022-10-03 18:04:35 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-10-03 18:04:35 +0100 |
commit | f269eabc6c4f5bdcef989cd5b4b95ba8ccaa4d8a (patch) | |
tree | b302076deeeab8b9884a2912b364f8131ef34949 /runtime/doc | |
parent | eb47d6d20a47707d810360fd1684b21f67d5dec8 (diff) | |
download | vim-git-f269eabc6c4f5bdcef989cd5b4b95ba8ccaa4d8a.tar.gz |
Update runtime files
Diffstat (limited to 'runtime/doc')
-rw-r--r-- | runtime/doc/builtin.txt | 31 | ||||
-rw-r--r-- | runtime/doc/diff.txt | 2 | ||||
-rw-r--r-- | runtime/doc/fold.txt | 7 | ||||
-rw-r--r-- | runtime/doc/insert.txt | 15 | ||||
-rw-r--r-- | runtime/doc/options.txt | 10 | ||||
-rw-r--r-- | runtime/doc/os_vms.txt | 8 | ||||
-rw-r--r-- | runtime/doc/print.txt | 2 | ||||
-rw-r--r-- | runtime/doc/quickref.txt | 2 | ||||
-rw-r--r-- | runtime/doc/syntax.txt | 11 | ||||
-rw-r--r-- | runtime/doc/tags | 11 | ||||
-rw-r--r-- | runtime/doc/todo.txt | 61 | ||||
-rw-r--r-- | runtime/doc/vim9.txt | 14 |
12 files changed, 83 insertions, 91 deletions
diff --git a/runtime/doc/builtin.txt b/runtime/doc/builtin.txt index e5740a587..686cc84cc 100644 --- a/runtime/doc/builtin.txt +++ b/runtime/doc/builtin.txt @@ -1,4 +1,4 @@ -*builtin.txt* For Vim version 9.0. Last change: 2022 Sep 17 +*builtin.txt* For Vim version 9.0. Last change: 2022 Sep 30 VIM REFERENCE MANUAL by Bram Moolenaar @@ -6,9 +6,10 @@ Builtin functions *builtin-functions* -Note: Expression evaluation can be disabled at compile time. If this has been -done, the builtin functions are not available. See |+eval| and -|no-eval-feature|. +Note: Expression evaluation can be disabled at compile time, the builtin +functions are not available then. See |+eval| and |no-eval-feature|. + +For functions grouped by what they are used for see |function-list|. 1. Overview |builtin-function-list| 2. Details |builtin-function-details| @@ -7035,13 +7036,19 @@ reg_recording() *reg_recording()* Returns the single letter name of the register being recorded. Returns an empty string when not recording. See |q|. -reltime([{start} [, {end}]]) *reltime()* +reltime() +reltime({start}) +reltime({start}, {end}) *reltime()* Return an item that represents a time value. The item is a list with items that depend on the system. In Vim 9 script list<any> can be used. The item can be passed to |reltimestr()| to convert it to a - string or |reltimefloat()| to convert to a Float. - + string or |reltimefloat()| to convert to a Float. For + example, to see the time spent in function Work(): > + var startTime = reltime() + Work() + echo startTime->reltime()->reltimestr() +< Without an argument reltime() returns the current time (the representation is system-dependent, it can not be used as the wall-clock time, see |localtime()| for that). @@ -7162,8 +7169,8 @@ remote_peek({serverid} [, {retvar}]) *remote_peek()* This function is not available in the |sandbox|. {only available when compiled with the |+clientserver| feature} Examples: > - :let repl = "" - :echo "PEEK: " .. remote_peek(id, "repl") .. ": " .. repl + :let repl = "" + :echo "PEEK: " .. remote_peek(id, "repl") .. ": " .. repl < Can also be used as a |method|: > ServerId()->remote_peek() @@ -7223,7 +7230,8 @@ remote_startserver({name}) < {only available when compiled with the |+clientserver| feature} -remove({list}, {idx} [, {end}]) *remove()* +remove({list}, {idx}) +remove({list}, {idx}, {end}) *remove()* Without {end}: Remove the item at {idx} from |List| {list} and return the item. With {end}: Remove items from {idx} to {end} (inclusive) and @@ -7241,7 +7249,8 @@ remove({list}, {idx} [, {end}]) *remove()* Can also be used as a |method|: > mylist->remove(idx) -remove({blob}, {idx} [, {end}]) +remove({blob}, {idx}) +remove({blob}, {idx}, {end}) Without {end}: Remove the byte at {idx} from |Blob| {blob} and return the byte. With {end}: Remove bytes from {idx} to {end} (inclusive) and diff --git a/runtime/doc/diff.txt b/runtime/doc/diff.txt index e5321c586..1c93de4d7 100644 --- a/runtime/doc/diff.txt +++ b/runtime/doc/diff.txt @@ -1,4 +1,4 @@ -*diff.txt* For Vim version 9.0. Last change: 2022 Jan 22 +*diff.txt* For Vim version 9.0. Last change: 2022 Oct 01 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/fold.txt b/runtime/doc/fold.txt index f11ca0812..7c702ff2d 100644 --- a/runtime/doc/fold.txt +++ b/runtime/doc/fold.txt @@ -1,4 +1,4 @@ -*fold.txt* For Vim version 9.0. Last change: 2022 Jan 22 +*fold.txt* For Vim version 9.0. Last change: 2022 Oct 01 VIM REFERENCE MANUAL by Bram Moolenaar @@ -503,7 +503,7 @@ is evaluated to obtain the text displayed for a closed fold. Example: > This shows the first line of the fold, with "/*", "*/" and "{{{" removed. Note the use of backslashes to avoid some characters to be interpreted by the -":set" command. It's simpler to define a function and call that: > +":set" command. It is much simpler to define a function and call it: > :set foldtext=MyFoldText() :function MyFoldText() @@ -512,6 +512,9 @@ Note the use of backslashes to avoid some characters to be interpreted by the : return v:folddashes .. sub :endfunction +The advantage of using a function call without arguments is that it is faster, +see |expr-option-function|. + Evaluating 'foldtext' is done in the |sandbox|. The current window is set to the window that displays the line. The context is set to the script where the option was last set. diff --git a/runtime/doc/insert.txt b/runtime/doc/insert.txt index 51cfa4697..9e8762696 100644 --- a/runtime/doc/insert.txt +++ b/runtime/doc/insert.txt @@ -1,4 +1,4 @@ -*insert.txt* For Vim version 9.0. Last change: 2022 Apr 06 +*insert.txt* For Vim version 9.0. Last change: 2022 Sep 30 VIM REFERENCE MANUAL by Bram Moolenaar @@ -667,7 +667,7 @@ When the popup menu is displayed there are a few more special keys, see |popupmenu-keys|. Note: The keys that are valid in CTRL-X mode are not mapped. This allows for -":map ^F ^X^F" to work (where ^F is CTRL-F and ^X is CTRL-X). The key that +`:map <C-F> <C-X><C-F>` to work (assuming "<" is not in 'cpo'). The key that ends CTRL-X mode (any key that is not a valid CTRL-X mode command) is mapped. Also, when doing completion with 'complete' mappings apply as usual. @@ -677,11 +677,12 @@ buffer text cannot be changed. Mappings that somehow invoke ":normal i.." will generate an E565 error. The following mappings are suggested to make typing the completion commands -a bit easier (although they will hide other commands): > - :inoremap ^] ^X^] - :inoremap ^F ^X^F - :inoremap ^D ^X^D - :inoremap ^L ^X^L +a bit easier (although they will hide other commands; this requires "<" is not +in 'cpo'): > + :inoremap <C-]> <C-X><C-]> + :inoremap <C-F> <C-X><C-F> + :inoremap <C-D> <C-X><C-D> + :inoremap <C-L> <C-X><C-L> As a special case, typing CTRL-R to perform register insertion (see |i_CTRL-R|) will not exit CTRL-X mode. This is primarily to allow the use of diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 069a0f173..a0098a7bd 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -1,4 +1,4 @@ -*options.txt* For Vim version 9.0. Last change: 2022 Sep 27 +*options.txt* For Vim version 9.0. Last change: 2022 Oct 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -2942,7 +2942,7 @@ A jump table for the options with a short description can be found at |Q_op|. 'display' 'dy' string (default "", set to "truncate" in |defaults.vim|) global - Change the way text is displayed. This is comma-separated list of + Change the way text is displayed. This is a comma-separated list of flags: lastline When included, as much as possible of the last line in a window will be displayed. "@@@" is put in the @@ -7307,8 +7307,10 @@ A jump table for the options with a short description can be found at |Q_op|. local to window Scrolling works with screen lines. When 'wrap' is set and the first line in the window wraps part of it may not be visible, as if it is - above the window. - NOTE: only partly implemented, works with CTRL-E and CTRL-Y. + above the window. "<<<" is displayed at the start of the first line, + highlighted with |hl-NonText|. + NOTE: only partly implemented, currently works with CTRL-E, CTRL-Y + and scrolling with the mouse. *'softtabstop'* *'sts'* 'softtabstop' 'sts' number (default 0) diff --git a/runtime/doc/os_vms.txt b/runtime/doc/os_vms.txt index c55b0e68e..b2a159018 100644 --- a/runtime/doc/os_vms.txt +++ b/runtime/doc/os_vms.txt @@ -1,4 +1,4 @@ -*os_vms.txt* For Vim version 9.0. Last change: 2021 Jan 04 +*os_vms.txt* For Vim version 9.0. Last change: 2022 Sep 30 VIM REFERENCE MANUAL @@ -331,10 +331,10 @@ features, it is worth to choose non GUI executables. 8.1 Backspace/delete There are backspace/delete key inconsistencies with VMS. -:fixdel doesn't do the trick, but the solution is: > +:fixdel doesn't do the trick, but the solution is (without "<" in 'cpo'): > - :inoremap ^? ^H " for terminal mode - :inoremap <Del> ^H " for gui mode + :inoremap <C-?> <C-H> " for terminal mode + :inoremap <Del> <C-H> " for gui mode Read more in ch: 8.6 (Terminal problems). (Bruce Hunsaker <BNHunsaker@chq.byu.edu> Vim 5.3) diff --git a/runtime/doc/print.txt b/runtime/doc/print.txt index 9f8bb2087..53f17e154 100644 --- a/runtime/doc/print.txt +++ b/runtime/doc/print.txt @@ -1,4 +1,4 @@ -*print.txt* For Vim version 9.0. Last change: 2022 Jan 23 +*print.txt* For Vim version 9.0. Last change: 2022 Oct 01 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/quickref.txt b/runtime/doc/quickref.txt index 4d13a4788..fab98302f 100644 --- a/runtime/doc/quickref.txt +++ b/runtime/doc/quickref.txt @@ -1,4 +1,4 @@ -*quickref.txt* For Vim version 9.0. Last change: 2022 Sep 14 +*quickref.txt* For Vim version 9.0. Last change: 2022 Oct 02 VIM REFERENCE MANUAL by Bram Moolenaar diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index 1587df5e7..1775af73b 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt* For Vim version 9.0. Last change: 2022 Sep 26 +*syntax.txt* For Vim version 9.0. Last change: 2022 Oct 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -5376,10 +5376,11 @@ ModeMsg 'showmode' message (e.g., "-- INSERT --"). *hl-MoreMsg* MoreMsg |more-prompt| *hl-NonText* -NonText '@' at the end of the window, characters from 'showbreak' - and other characters that do not really exist in the text - (e.g., ">" displayed when a double-wide character doesn't - fit at the end of the line). +NonText '@' at the end of the window, "<<<" at the start of the window + for 'smoothscroll', characters from 'showbreak' and other + characters that do not really exist in the text, such as the + ">" displayed when a double-wide character doesn't fit at the + end of the line. *hl-Normal* Normal Normal text. *hl-Pmenu* diff --git a/runtime/doc/tags b/runtime/doc/tags index 2c4a550de..639938f6f 100644 --- a/runtime/doc/tags +++ b/runtime/doc/tags @@ -714,14 +714,14 @@ $quote eval.txt /*$quote* 'nosmartindent' options.txt /*'nosmartindent'* 'nosmarttab' options.txt /*'nosmarttab'* 'nosmd' options.txt /*'nosmd'* +'nosmoothscroll' options.txt /*'nosmoothscroll'* +'nosms' options.txt /*'nosms'* 'nosn' options.txt /*'nosn'* 'nosol' options.txt /*'nosol'* 'nospell' options.txt /*'nospell'* 'nosplitbelow' options.txt /*'nosplitbelow'* 'nosplitright' options.txt /*'nosplitright'* -'nosplitscroll' options.txt /*'nosplitscroll'* 'nospr' options.txt /*'nospr'* -'nospsc' options.txt /*'nospsc'* 'nosr' options.txt /*'nosr'* 'nossl' options.txt /*'nossl'* 'nosta' options.txt /*'nosta'* @@ -938,6 +938,8 @@ $quote eval.txt /*$quote* 'smarttab' options.txt /*'smarttab'* 'smc' options.txt /*'smc'* 'smd' options.txt /*'smd'* +'smoothscroll' options.txt /*'smoothscroll'* +'sms' options.txt /*'sms'* 'sn' options.txt /*'sn'* 'so' options.txt /*'so'* 'softtabstop' options.txt /*'softtabstop'* @@ -954,12 +956,11 @@ $quote eval.txt /*$quote* 'spf' options.txt /*'spf'* 'spl' options.txt /*'spl'* 'splitbelow' options.txt /*'splitbelow'* +'splitkeep' options.txt /*'splitkeep'* 'splitright' options.txt /*'splitright'* -'splitscroll' options.txt /*'splitscroll'* 'spo' options.txt /*'spo'* 'spr' options.txt /*'spr'* 'sps' options.txt /*'sps'* -'spsc' options.txt /*'spsc'* 'sr' options.txt /*'sr'* 'srr' options.txt /*'srr'* 'ss' options.txt /*'ss'* @@ -4345,6 +4346,7 @@ E1303 map.txt /*E1303* E1304 vim9.txt /*E1304* E1305 textprop.txt /*E1305* E1306 vim9.txt /*E1306* +E1307 vim9.txt /*E1307* E131 userfunc.txt /*E131* E132 userfunc.txt /*E132* E133 userfunc.txt /*E133* @@ -6777,6 +6779,7 @@ expr-lambda eval.txt /*expr-lambda* expr-nesting eval.txt /*expr-nesting* expr-number eval.txt /*expr-number* expr-option eval.txt /*expr-option* +expr-option-function vim9.txt /*expr-option-function* expr-quote eval.txt /*expr-quote* expr-register eval.txt /*expr-register* expr-star eval.txt /*expr-star* diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt index 75aef3101..0e125204c 100644 --- a/runtime/doc/todo.txt +++ b/runtime/doc/todo.txt @@ -1,4 +1,4 @@ -*todo.txt* For Vim version 9.0. Last change: 2022 Sep 27 +*todo.txt* For Vim version 9.0. Last change: 2022 Oct 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -38,55 +38,40 @@ browser use: https://github.com/vim/vim/issues/1234 *known-bugs* -------------------- Known bugs and current work ----------------------- -From test_global - Found errors in Test_interrupt_global(): - Run 1, 02:16:22 - 02:16:27: - command line..script /home/mool/vim/vim90/src/testdir/runtest.vim[469]..function RunTheTest[44]..Test_interrupt_global[13]..WaitForAssert[2]..<SNR>7_WaitForCommon[11]..<lambda>20 line 1: Pattern 'Interrupted' does not match 'Type :qa! and press...l changes and exit Vim 1,1 All' - command line..script /home/mool/vim/vim90/src/testdir/runtest.vim[469]..function RunTheTest[44]..Test_interrupt_global[20]..WaitForAssert[2]..<SNR>7_WaitForCommon[11]..<lambda>21 line 1: Pattern 'Interrupted' does not match 'Entering Ex mode. Type "visual" to go to Normal mode.' +'smoothscroll': +- computing 'scrolloff' position row use w_skipcol + +Add a string to the 'display' option ("smoothscroll" ?) to make CTRL-E and +CTRL-Y scroll one screen line, also if this means the first line doesn't start +with the first character (like what happens with a last line that doesn't +fit). Display "<<<" at the start of the first visible line (like "@@@" is +displayed in the last line). (Arseny Nasokin, #5154) +Neovim PR: https://github.com/neovim/neovim/pull/11014 Use :defer command: - Use "D" flag of writefile() and mkdir() in tests. - (testdir/test_e*.vim done) + (testdir/test_p*.vim done) + +Fix for powershell: #11257 + +Change boolean 'splitscroll' into string 'splitkeep'. #11258 -New Vim indent script: #11079 OK? Further Vim9 improvements, possibly after launch: -- For map(), reduce() and filter() use a specific implementation if the second - argument is a compiled function. #11163 - Use Vim9 for more runtime files. -- Check performance with callgrind and kcachegrind. - getline()/substitute()/setline() in #5632 -- Better implementation for partial and tests for that. -- when using "const" mark the variable type as const with TTFLAG_CONST, so - that an error is given at compile time when trying to change it. E.g. for a - const list and trying to call add(). -- Compile options that are an expression, e.g. "expr:" in 'spellsuggest', - 'foldexpr', 'foldtext', 'printexpr', 'diffexpr', 'patchexpr', 'charconvert', - 'balloonexpr', 'includeexpr', 'indentexpr', 'formatexpr'. - Give an error if compilation fails. (#7625) - Alternatively: Detect a compiled function call and skip the expression - evaluation. - Use the location where the option was set for deciding whether it's to be - evaluated in Vim9 script context. - implement :type - implement :enum - implement :class and :interface: See |vim9-classes| -- For range: make table of first ASCII character with flag to quickly check if - it can be a Vim9 command. E.g. "+" can, but "." can't. - Inline call to map() and filter(), better type checking. -- Make accessing varargs faster: arg[expr] - EVAL expr - LOADVARARG (varargs idx) - When evaluating constants for script variables, some functions could work: has(featureName), len(someString) - Implement as part of an expression: ++expr, --expr, expr++, expr--. Popup windows: -- Preview popup not properly updated when it overlaps with completion menu. - (Yegappan Lakshmanan, 2021 May 22) -- Scrollbar thumb sometimes not visible #10492 - Add a function to redraw a specific popup window. Esp. to be used when editing the command line, when screen updating doesn't happen. (Shougo) + #10210 Probably need to update all popup windows (they may overlap) + If the display is scrolled need to redraw everything later. - Add a flag to make a popup window focusable? CTRL-W P cycle over any preview window or focusable popup, end up back in current window. @@ -113,8 +98,6 @@ Popup windows: - put popup menu also in popup_mask? - Match does not have right BG color if line length equals popup width. (#5658) -- Any other commands to disable in a popup window? - Use ERROR_IF_POPUP_WINDOW for these. - Figure out the size and position better if wrapping inserts indent 'incsearch' with :s: @@ -203,13 +186,6 @@ Add BufDeletePost. #11041 Test property disappears when using CR twice in a row. OK when some text was entered. (#11151) -Add a string to the 'display' option ("smoothscroll" ?) to make CTRL-E and -CTRL-Y scroll one screen line, also if this means the first line doesn't start -with the first character (like what happens with a last line that doesn't -fit). Display "<<<" at the start of the first visible line (like "@@@" is -displayed in the last line). (Arseny Nasokin, #5154) -Neovim PR: https://github.com/neovim/neovim/pull/11014 - NFA regexp does not handle composing characters well: #10286 [ɔ̃] matches both ɔ and ɔ̃ \(ɔ\|ɔ̃\) matches ɔ and not ɔ̃ @@ -681,9 +657,6 @@ when possible. (Dylan Lloyd, #3973) Make ":interactive !cmd" stop termcap mode, also when used in an autocommand. (#3692) -matchaddpos() gets slow with many matches. Proposal by Rick Howe, 2018 Jul -19. - Add something like 'fillchars' local to window, but allow for specifying a highlight name. Esp. for the statusline. And "extends" and "precedes" are also useful without 'list' set. Also in diff --git a/runtime/doc/vim9.txt b/runtime/doc/vim9.txt index 15e9a702b..f3a2ab6ee 100644 --- a/runtime/doc/vim9.txt +++ b/runtime/doc/vim9.txt @@ -1,4 +1,4 @@ -*vim9.txt* For Vim version 9.0. Last change: 2022 Sep 19 +*vim9.txt* For Vim version 9.0. Last change: 2022 Oct 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -502,7 +502,7 @@ How constants work varies between languages. Some consider a variable that can't be assigned another value a constant. JavaScript is an example. Others also make the value immutable, thus when a constant uses a list, the list cannot be changed. In Vim9 we can use both. - *E1021* + *E1021* *E1307* `:const` is used for making both the variable and the value a constant. Use this for composite structures that you want to make sure will not be modified. Example: > @@ -1413,11 +1413,11 @@ to a Vim9 function: Calling a function in an expr option ~ *expr-option-function* -A few options, such as 'foldexpr', are an expresison that is evaluated to get -a value. The evaluation can have quite a bit of overhead. One way to -minimize the overhead, and also to keep the option value very simple, is to -defined a compiled function and set the option to call it without arguments. -Example: > +The value of a few options, such as 'foldexpr', is an expression that is +evaluated to get a value. The evaluation can have quite a bit of overhead. +One way to minimize the overhead, and also to keep the option value very +simple, is to define a compiled function and set the option to call it +without arguments. Example: > vim9script def MyFoldFunc(): any ... compute fold level for line v:lnum |