0
0
mirror of https://github.com/vim/vim.git synced 2025-07-26 11:04:33 -04:00

Update runtime files.

This commit is contained in:
Bram Moolenaar 2020-08-07 19:54:59 +02:00
parent 95dd9f2571
commit e7b1ea0276
38 changed files with 400 additions and 162 deletions

View File

@ -5,8 +5,8 @@
This is an experimental side of [Vim](https://github.com/vim/vim). This is an experimental side of [Vim](https://github.com/vim/vim).
It explores ways of making Vim script faster and better. It explores ways of making Vim script faster and better.
WARNING: The Vim9 script features are in the early stages of development, WARNING: The Vim9 script features are still under development, anything can
anything can break! break!
# Why Vim9? # Why Vim9?
@ -52,7 +52,7 @@ we can gain, and also that Vim script can be faster than builtin
interfaces. interfaces.
In practice the script would not do something useless as counting but change In practice the script would not do something useless as counting but change
the text. For example, re-indent all the lines: the text. For example, reindent all the lines:
``` vim ``` vim
let totallen = 0 let totallen = 0
@ -91,9 +91,9 @@ Instead of using script language support in Vim:
with them. The job and channel support already makes this possible. with them. The job and channel support already makes this possible.
Really any language can be used, also Java and Go, which are not Really any language can be used, also Java and Go, which are not
available built-in. available built-in.
* Phase out the built-in language interfaces, make maintenance a bit easier * No priority for the built-in language interfaces. They will have to be kept
and executables easier to build. They will be kept for backwards for backwards compatibility, but many users won't need a Vim build with these
compatibility, no new features. interfaces.
* Improve the Vim script language, it is used to communicate with the external * Improve the Vim script language, it is used to communicate with the external
tool and implements the Vim side of the interface. Also, it can be used when tool and implements the Vim side of the interface. Also, it can be used when
an external tool is undesired. an external tool is undesired.
@ -140,6 +140,9 @@ Taking this one step further is also dropping "s:" for script-local variables;
everything at the script level is script-local by default. Since this is not everything at the script level is script-local by default. Since this is not
backwards compatible it requires a new script style: Vim9 script! backwards compatible it requires a new script style: Vim9 script!
To avoid having more variations, the syntax inside a compiled function is the
same as in Vim9 script. Thus you have legacy syntax and Vim9 syntax.
It should be possible to convert code from other languages to Vim It should be possible to convert code from other languages to Vim
script. We can add functionality to make this easier. This still needs script. We can add functionality to make this easier. This still needs
to be discussed, but we can consider adding type checking and a simple to be discussed, but we can consider adding type checking and a simple

View File

@ -1,7 +1,9 @@
" Vim completion script " Vim completion script
" Language: Java Script " Language: Java Script
" Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl ) " Maintainer: Jay Sitter (jay@jaysitter.com)
" Last Change: 2017 Mar 04 " URL: https://github.com/jsit/javascriptcomplete.vim/
" Previous Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl )
" Last Change: 2020 Jul 30
function! javascriptcomplete#CompleteJS(findstart, base) function! javascriptcomplete#CompleteJS(findstart, base)
if a:findstart if a:findstart
@ -154,12 +156,30 @@ function! javascriptcomplete#CompleteJS(findstart, base)
\ 'text', 'vLink'] \ 'text', 'vLink']
let bodys = bodyprop let bodys = bodyprop
" Document - document. " Document - document.
let docuprop = ['anchors', 'applets', 'childNodes', 'embeds', 'forms', 'images', 'links', 'stylesheets', let docuprop = ['anchors', 'body', 'characterSet', 'doctype',
\ 'body', 'cookie', 'documentElement', 'domain', 'lastModified', 'referrer', 'title', 'URL'] \ 'documentElement', 'documentURI', 'embeds', 'fonts', 'forms',
let documeth = ['close', 'createAttribute', 'createElement', 'createTextNode', 'focus', 'getElementById', \ 'head', 'hidden', 'images', 'implementation', 'lastStyleSheetSet',
\ 'getElementsByName', 'getElementsByTagName', 'open', 'write', 'writeln', \ 'links', 'plugins', 'preferredStyleSheetSet', 'scripts',
\ 'onClick', 'onDblClick', 'onFocus', 'onKeyDown', 'onKeyPress', 'onKeyUp', \ 'scrollingElement', 'selectedStyleSheetSet', 'styleSheetSets',
\ 'onMouseDown', 'onMouseMove', 'onMouseOut', 'onMouseOver', 'onMouseUp', 'onResize'] \ 'timeline', 'visibilityState', 'cookie', 'defaultView',
\ 'designMode', 'dir', 'domain', 'lastModified', 'location',
\ 'readyState', 'referrer', 'title', 'URL', 'activeElement',
\ 'fullscreenElement', 'styleSheets']
let documeth = ['adoptNode', 'close', 'createAttribute',
\ 'createAttributeNS', 'createCDATASection', 'createComment',
\ 'createDocumentFragment', 'createElement', 'createElementNS',
\ 'createEvent', 'createExpression', 'createNSResolver',
\ 'createNodeIterator', 'createProcessingInstruction', 'createRange',
\ 'createTextNode', 'createTouchList', 'createTreeWalker',
\ 'enableStyleSheetsForSet', 'evaluate', 'focus', 'getElementById',
\ 'getElementById', 'getElementsByClassName', 'getElementsByName',
\ 'getElementsByTagName', 'getElementsByTagNameNS',
\ 'hasStorageAccess', 'importNode', 'onClick', 'onDblClick',
\ 'onFocus', 'onKeyDown', 'onKeyPress', 'onKeyUp', 'onMouseDown',
\ 'onMouseMove', 'onMouseOut', 'onMouseOver', 'onMouseUp',
\ 'onResize', 'open', 'querySelector', 'querySelectorAll',
\ 'requestStorageAccess', 'write', 'writeln']
call map(documeth, 'v:val."("') call map(documeth, 'v:val."("')
let docuxprop = ['attributes', 'childNodes', 'doctype', 'documentElement', 'firstChild', let docuxprop = ['attributes', 'childNodes', 'doctype', 'documentElement', 'firstChild',
\ 'implementation', 'namespaceURI', 'nextSibling', 'nodeName', 'nodeType', \ 'implementation', 'namespaceURI', 'nextSibling', 'nodeName', 'nodeType',
@ -368,9 +388,11 @@ function! javascriptcomplete#CompleteJS(findstart, base)
let xdomelemprop = ['attributes', 'childNodes', 'firstChild', 'lastChild', let xdomelemprop = ['attributes', 'childNodes', 'firstChild', 'lastChild',
\ 'namespaceURI', 'nextSibling', 'nodeName', 'nodeType', 'nodeValue', \ 'namespaceURI', 'nextSibling', 'nodeName', 'nodeType', 'nodeValue',
\ 'ownerDocument', 'parentNode', 'prefix', 'previousSibling', 'tagName'] \ 'ownerDocument', 'parentNode', 'prefix', 'previousSibling', 'tagName']
let xdomelemmeth = ['appendChild', 'cloneNode', 'getAttribute', 'getAttributeNode', let xdomelemmeth = ['appendChild', 'addEventListener', 'cloneNode',
\ 'getElementsByTagName', 'hasChildNodes', 'insertBefore', 'normalize', \ 'dispatchEvent', 'getAttribute', 'getAttributeNode',
\ 'removeAttribute', 'removeAttributeNode', 'removeChild', 'replaceChild', \ 'getElementsByTagName', 'hasChildNodes', 'insertBefore',
\ 'normalize', 'removeAttribute', 'removeAttributeNode',
\ 'removeChild', 'removeEventListener', 'replaceChild',
\ 'setAttribute', 'setAttributeNode'] \ 'setAttribute', 'setAttributeNode']
call map(xdomelemmeth, 'v:val."("') call map(xdomelemmeth, 'v:val."("')
let xdomelems = xdomelemprop + xdomelemmeth let xdomelems = xdomelemprop + xdomelemmeth

View File

@ -1,4 +1,4 @@
*autocmd.txt* For Vim version 8.2. Last change: 2020 Jun 10 *autocmd.txt* For Vim version 8.2. Last change: 2020 Aug 02
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -1425,8 +1425,8 @@ name!
:aug[roup]! {name} Delete the autocmd group {name}. Don't use :aug[roup]! {name} Delete the autocmd group {name}. Don't use
this if there is still an autocommand using this if there is still an autocommand using
this group! You will get a warning if doing this group! You will get a warning if doing
it anyway. when the group is the current group it anyway. When the group is the current
you will get error E936. group you will get error E936.
To enter autocommands for a specific group, use this method: To enter autocommands for a specific group, use this method:
1. Select the group with ":augroup {name}". 1. Select the group with ":augroup {name}".

View File

@ -1,4 +1,4 @@
*develop.txt* For Vim version 8.2. Last change: 2020 Apr 13 *develop.txt* For Vim version 8.2. Last change: 2020 Jul 27
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -34,8 +34,8 @@ balance must be found between them.
VIM IS... VI COMPATIBLE *design-compatible* VIM IS... VI COMPATIBLE *design-compatible*
First of all, it should be possible to use Vim as a drop-in replacement for First of all, it should be possible to use Vim as a drop-in replacement for
Vi. When the user wants to, he can use Vim in compatible mode and hardly Vi. When the user wants to, Vim can be used in compatible mode and hardly
notice any difference with the original Vi. any differences with the original Vi will be noticed.
Exceptions: Exceptions:
- We don't reproduce obvious Vi bugs in Vim. - We don't reproduce obvious Vi bugs in Vim.

View File

@ -1,4 +1,4 @@
*eval.txt* For Vim version 8.2. Last change: 2020 Aug 01 *eval.txt* For Vim version 8.2. Last change: 2020 Aug 07
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -4895,31 +4895,32 @@ getbufinfo([{dict}])
Each returned List item is a dictionary with the following Each returned List item is a dictionary with the following
entries: entries:
bufnr buffer number. bufnr Buffer number.
changed TRUE if the buffer is modified. changed TRUE if the buffer is modified.
changedtick number of changes made to the buffer. changedtick Number of changes made to the buffer.
hidden TRUE if the buffer is hidden. hidden TRUE if the buffer is hidden.
lastused timestamp in seconds, like lastused Timestamp in seconds, like
|localtime()|, when the buffer was |localtime()|, when the buffer was
last used. last used.
{only with the |+viminfo| feature} {only with the |+viminfo| feature}
listed TRUE if the buffer is listed. listed TRUE if the buffer is listed.
lnum current line number in buffer. lnum Line number used for the buffer when
linecount number of lines in the buffer (only opened in the current window.
linecount Number of lines in the buffer (only
valid when loaded) valid when loaded)
loaded TRUE if the buffer is loaded. loaded TRUE if the buffer is loaded.
name full path to the file in the buffer. name Full path to the file in the buffer.
signs list of signs placed in the buffer. signs List of signs placed in the buffer.
Each list item is a dictionary with Each list item is a dictionary with
the following fields: the following fields:
id sign identifier id sign identifier
lnum line number lnum line number
name sign name name sign name
variables a reference to the dictionary with variables A reference to the dictionary with
buffer-local variables. buffer-local variables.
windows list of |window-ID|s that display this windows List of |window-ID|s that display this
buffer buffer
popups list of popup |window-ID|s that popups List of popup |window-ID|s that
display this buffer display this buffer
Examples: > Examples: >
@ -5446,7 +5447,7 @@ getloclist({nr} [, {what}]) *getloclist()*
:echo getloclist(5, {'filewinid': 0}) :echo getloclist(5, {'filewinid': 0})
getmarklist([{expr}] *getmarklist()* getmarklist([{expr}]) *getmarklist()*
Without the {expr} argument returns a |List| with information Without the {expr} argument returns a |List| with information
about all the global marks. |mark| about all the global marks. |mark|
@ -8709,7 +8710,8 @@ searchcount([{options}]) *searchcount()*
pos |List| `[lnum, col, off]` value pos |List| `[lnum, col, off]` value
when recomputing the result. when recomputing the result.
this changes "current" result this changes "current" result
value. see |cursor()|, |getpos() value. see |cursor()|,
|getpos()|
(default: cursor's position) (default: cursor's position)
@ -9111,7 +9113,7 @@ setqflist({list} [, {action} [, {what}]]) *setqflist()*
argument is ignored. See below for the supported items in argument is ignored. See below for the supported items in
{what}. {what}.
*setqflist-what* *setqflist-what*
When {what} is not present, the items in {list} or used. Each When {what} is not present, the items in {list} are used. Each
item must be a dictionary. Non-dictionary items in {list} are item must be a dictionary. Non-dictionary items in {list} are
ignored. Each dictionary item can contain the following ignored. Each dictionary item can contain the following
entries: entries:
@ -9332,7 +9334,7 @@ settagstack({nr}, {dict} [, {action}]) *settagstack()*
Returns zero for success, -1 for failure. Returns zero for success, -1 for failure.
Examples (for more examples see |tagstack-examples||): Examples (for more examples see |tagstack-examples|):
Empty the tag stack of window 3: > Empty the tag stack of window 3: >
call settagstack(3, {'items' : []}) call settagstack(3, {'items' : []})
@ -10132,7 +10134,7 @@ swapname({expr}) *swapname()*
The result is the swap file path of the buffer {expr}. The result is the swap file path of the buffer {expr}.
For the use of {expr}, see |bufname()| above. For the use of {expr}, see |bufname()| above.
If buffer {expr} is the current buffer, the result is equal to If buffer {expr} is the current buffer, the result is equal to
|:swapname| (unless no swap file). |:swapname| (unless there is no swap file).
If buffer {expr} has no swap file, returns an empty string. If buffer {expr} has no swap file, returns an empty string.
Can also be used as a |method|: > Can also be used as a |method|: >

View File

@ -451,7 +451,7 @@ with the Intellimouse driver 2.2 and when "Universal Scrolling" is turned on.
XPM support *w32-xpm-support* XPM support *w32-xpm-support*
GVim can be build on MS-Windows with support for XPM files. |+xpm_w32| GVim can be built on MS-Windows with support for XPM files. |+xpm_w32|
See the Make_mvc.mak file for instructions, search for XPM. See the Make_mvc.mak file for instructions, search for XPM.
To try out if XPM support works do this: > To try out if XPM support works do this: >

View File

@ -1,4 +1,4 @@
*helphelp.txt* For Vim version 8.2. Last change: 2020 Mar 01 *helphelp.txt* For Vim version 8.2. Last change: 2020 Jul 27
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -369,14 +369,16 @@ highlighting. So do these:
You can find the details in $VIMRUNTIME/syntax/help.vim You can find the details in $VIMRUNTIME/syntax/help.vim
*inclusion* *inclusion*
Some people make a big deal about using "his" when referring to the user, Vim is for everybody, no matter race, gender or anything. Some people make a
thinking it means we assume the user is male. That is of course not the case, big deal about using "he" or "his" when referring to the user, thinking it
it's just a habit of writing help text, which quite often is many years old. means we assume the user is male. That is not the case, it's just a habit of
Also, a lot of the text is written by contributors for who English is not writing help text, which quite often is many years old. Also, a lot of the
their first language. We do not make any assumptions about the gender of the text is written by contributors for whom English is not their first language.
user, no matter how the text is phrased. And we do not want to waste time on We do not make any assumptions about the gender of the user, no matter how the
this discussion. The goal is that the reader understands how Vim works, the text is phrased. Some people have suggested using "they", but that is not
exact wording is secondary. regular English. We do not want to spend much time on this discussion. The
goal is that the reader understands how Vim works, the exact wording is
secondary.
vim:tw=78:ts=8:noet:ft=help:norl: vim:tw=78:ts=8:noet:ft=help:norl:

View File

@ -199,8 +199,8 @@ Vim evaluation and command execution, and others.
returns it. Note that the buffer is not set as returns it. Note that the buffer is not set as
current. current.
vim.call({name} [,{args}]) vim.call({name} [, {args}])
Proxy to call Vim function named {name} with Proxy to call Vim function named {name} with
arguments {args}. Example: > arguments {args}. Example: >
:lua print(vim.call('has', 'timers')) :lua print(vim.call('has', 'timers'))
< <

View File

@ -275,7 +275,7 @@ Options:
$win delcmd {cmd} *tcl-window-delcmd* $win delcmd {cmd} *tcl-window-delcmd*
Registers the Tcl command {cmd} as a deletion callback for the window. Registers the Tcl command {cmd} as a deletion callback for the window.
This command is executed (in the global scope) just before the window This command is executed (in the global scope) just before the window
is closed. Complex commands should be build with "list": > is closed. Complex commands should be built with "list": >
$win delcmd [list puts vimerr "window deleted"] $win delcmd [list puts vimerr "window deleted"]
< See also |tcl-buffer-delcmd|. < See also |tcl-buffer-delcmd|.
@ -357,7 +357,7 @@ Options:
$buf delcmd {cmd} *tcl-buffer-delcmd* $buf delcmd {cmd} *tcl-buffer-delcmd*
Registers the Tcl command {cmd} as a deletion callback for the buffer. Registers the Tcl command {cmd} as a deletion callback for the buffer.
This command is executed (in the global scope) just before the buffer This command is executed (in the global scope) just before the buffer
is deleted. Complex commands should be build with "list": > is deleted. Complex commands should be built with "list": >
$buf delcmd [list puts vimerr "buffer [$buf number] gone"] $buf delcmd [list puts vimerr "buffer [$buf number] gone"]
< See also |tcl-window-delcmd|. < See also |tcl-window-delcmd|.

View File

@ -414,11 +414,11 @@ The examples below assume a 'shiftwidth' of 4.
< <
*cino-(* *cino-(*
(N When in unclosed parentheses, indent N characters from the line (N When in unclosed parentheses, indent N characters from the line
with the unclosed parentheses. Add a 'shiftwidth' for every with the unclosed parenthesis. Add a 'shiftwidth' for every
extra unclosed parentheses. When N is 0 or the unclosed extra unclosed parentheses. When N is 0 or the unclosed
parentheses is the first non-white character in its line, line parenthesis is the first non-white character in its line, line
up with the next non-white character after the unclosed up with the next non-white character after the unclosed
parentheses. (default 'shiftwidth' * 2). parenthesis. (default 'shiftwidth' * 2).
cino= cino=(0 > cino= cino=(0 >
if (c1 && (c2 || if (c1 && (c2 || if (c1 && (c2 || if (c1 && (c2 ||
@ -439,7 +439,7 @@ The examples below assume a 'shiftwidth' of 4.
< <
*cino-U* *cino-U*
UN When N is non-zero, do not ignore the indenting specified by UN When N is non-zero, do not ignore the indenting specified by
( or u in case that the unclosed parentheses is the first ( or u in case that the unclosed parenthesis is the first
non-white character in its line. (default 0). non-white character in its line. (default 0).
cino= or cino=(s cino=(s,U1 > cino= or cino=(s cino=(s,U1 >
@ -452,8 +452,8 @@ The examples below assume a 'shiftwidth' of 4.
*cino-w* *cino-w*
wN When in unclosed parentheses and N is non-zero and either wN When in unclosed parentheses and N is non-zero and either
using "(0" or "u0", respectively, or using "U0" and the unclosed using "(0" or "u0", respectively, or using "U0" and the unclosed
parentheses is the first non-white character in its line, line parenthesis is the first non-white character in its line, line
up with the character immediately after the unclosed parentheses up with the character immediately after the unclosed parenthesis
rather than the first non-white character. (default 0). rather than the first non-white character. (default 0).
cino=(0 cino=(0,w1 > cino=(0 cino=(0,w1 >
@ -464,11 +464,11 @@ The examples below assume a 'shiftwidth' of 4.
< <
*cino-W* *cino-W*
WN When in unclosed parentheses and N is non-zero and either WN When in unclosed parentheses and N is non-zero and either
using "(0" or "u0", respectively and the unclosed parentheses is using "(0" or "u0", respectively and the unclosed parenthesis is
the last non-white character in its line and it is not the the last non-white character in its line and it is not the
closing parentheses, indent the following line N characters closing parenthesis, indent the following line N characters
relative to the outer context (i.e. start of the line or the relative to the outer context (i.e. start of the line or the
next unclosed parentheses). (default: 0). next unclosed parenthesis). (default: 0).
cino=(0 cino=(0,W4 > cino=(0 cino=(0,W4 >
a_long_line( a_long_line( a_long_line( a_long_line(
@ -495,8 +495,8 @@ The examples below assume a 'shiftwidth' of 4.
< <
*cino-m* *cino-m*
mN When N is non-zero, line up a line starting with a closing mN When N is non-zero, line up a line starting with a closing
parentheses with the first character of the line with the parenthesis with the first character of the line with the
matching opening parentheses. (default 0). matching opening parenthesis. (default 0).
cino=(s cino=(s,m1 > cino=(s cino=(s,m1 >
c = c1 && ( c = c1 && ( c = c1 && ( c = c1 && (
@ -510,7 +510,7 @@ The examples below assume a 'shiftwidth' of 4.
< <
*cino-M* *cino-M*
MN When N is non-zero, line up a line starting with a closing MN When N is non-zero, line up a line starting with a closing
parentheses with the first character of the previous line. parenthesis with the first character of the previous line.
(default 0). (default 0).
cino= cino=M1 > cino= cino=M1 >
@ -569,7 +569,7 @@ The examples below assume a 'shiftwidth' of 4.
recognize preprocessor lines; right-shifting lines that start recognize preprocessor lines; right-shifting lines that start
with "#" does not work. with "#" does not work.
*cino-P*
PN When N is non-zero recognize C pragmas, and indent them like any PN When N is non-zero recognize C pragmas, and indent them like any
other code; does not concern other preprocessor directives. other code; does not concern other preprocessor directives.
When N is zero (default): don't recognize C pragmas, treating When N is zero (default): don't recognize C pragmas, treating
@ -996,7 +996,7 @@ Indent after a nested paren: >
Indent for a continuation line: > Indent for a continuation line: >
let g:pyindent_continue = 'shiftwidth() * 2' let g:pyindent_continue = 'shiftwidth() * 2'
The method uses |searchpair()| to look back for unclosed parenthesis. This The method uses |searchpair()| to look back for unclosed parentheses. This
can sometimes be slow, thus it timeouts after 150 msec. If you notice the can sometimes be slow, thus it timeouts after 150 msec. If you notice the
indenting isn't correct, you can set a larger timeout in msec: > indenting isn't correct, you can set a larger timeout in msec: >
let g:pyindent_searchpair_timeout = 500 let g:pyindent_searchpair_timeout = 500

View File

@ -1,4 +1,4 @@
*map.txt* For Vim version 8.2. Last change: 2020 Apr 23 *map.txt* For Vim version 8.2. Last change: 2020 Aug 01
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar

View File

@ -1,4 +1,4 @@
*options.txt* For Vim version 8.2. Last change: 2020 Jul 18 *options.txt* For Vim version 8.2. Last change: 2020 Aug 07
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -2715,6 +2715,11 @@ A jump table for the options with a short description can be found at |Q_op|.
for Unix: ".,~/tmp,/var/tmp,/tmp") for Unix: ".,~/tmp,/var/tmp,/tmp")
global global
List of directory names for the swap file, separated with commas. List of directory names for the swap file, separated with commas.
Recommended value: ".,~/vimswap//" - this will put the swap file next
to the edited file if possible, and in your personal swap directory
otherwise. Make sure "~/vimswap//" is only readable for you.
Possible items:
- The swap file will be created in the first directory where this is - The swap file will be created in the first directory where this is
possible. possible.
- Empty means that no swap file will be used (recovery is - Empty means that no swap file will be used (recovery is
@ -2749,9 +2754,10 @@ A jump table for the options with a short description can be found at |Q_op|.
the same file twice will result in a warning. Using "/tmp" on Unix is the same file twice will result in a warning. Using "/tmp" on Unix is
discouraged: When the system crashes you lose the swap file. discouraged: When the system crashes you lose the swap file.
"/var/tmp" is often not cleared when rebooting, thus is a better "/var/tmp" is often not cleared when rebooting, thus is a better
choice than "/tmp". But it can contain a lot of files, your swap choice than "/tmp". But others on the computer may be able to see the
files get lost in the crowd. That is why a "tmp" directory in your files, and it can contain a lot of files, your swap files get lost in
home directory is tried first. the crowd. That is why a "tmp" directory in your home directory is
tried first.
The use of |:set+=| and |:set-=| is preferred when adding or removing The use of |:set+=| and |:set-=| is preferred when adding or removing
directories from the list. This avoids problems when a future version directories from the list. This avoids problems when a future version
uses another default. uses another default.
@ -8368,7 +8374,7 @@ A jump table for the options with a short description can be found at |Q_op|.
>= 14 Anything pending in a ":finally" clause. >= 14 Anything pending in a ":finally" clause.
>= 15 Every executed Ex command from a script (truncated at 200 >= 15 Every executed Ex command from a script (truncated at 200
characters). characters).
>= 16 Every executed Ex command >= 16 Every executed Ex command.
This option can also be set with the "-V" argument. See |-V|. This option can also be set with the "-V" argument. See |-V|.
This option is also set by the |:verbose| command. This option is also set by the |:verbose| command.
@ -8907,7 +8913,7 @@ A jump table for the options with a short description can be found at |Q_op|.
{only available when compiled with the |terminal| {only available when compiled with the |terminal|
feature on MS-Windows} feature on MS-Windows}
Specifies the name of the winpty shared library, used for the Specifies the name of the winpty shared library, used for the
|:terminal| command. The default depends on whether was build as a |:terminal| command. The default depends on whether Vim was built as a
32-bit or 64-bit executable. If not found, "winpty.dll" is tried as 32-bit or 64-bit executable. If not found, "winpty.dll" is tried as
a fallback. a fallback.
Environment variables are expanded |:set_env|. Environment variables are expanded |:set_env|.

View File

@ -88,7 +88,7 @@ VAX C compiler is not fully ANSI C compatible in pre-processor directives
semantics, therefore you have to use a converter program that will do the lion semantics, therefore you have to use a converter program that will do the lion
part of the job. For detailed instructions read file INSTALLvms.txt part of the job. For detailed instructions read file INSTALLvms.txt
MMS_VIM.EXE is build together with VIM.EXE, but for XXD.EXE you should MMS_VIM.EXE is built together with VIM.EXE, but for XXD.EXE you should
change to a subdirectory and build it separately. change to a subdirectory and build it separately.
CTAGS is not part of the Vim source distribution anymore, however the OpenVMS CTAGS is not part of the Vim source distribution anymore, however the OpenVMS

View File

@ -1,4 +1,4 @@
*popup.txt* For Vim version 8.2. Last change: 2020 May 18 *popup.txt* For Vim version 8.2. Last change: 2020 Jul 27
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -74,9 +74,9 @@ wrapping, lines in the buffer. It can be limited with the "maxheight"
property. You can use empty lines to increase the height or the "minheight" property. You can use empty lines to increase the height or the "minheight"
property. property.
The width of the window is normally equal to the longest line in the buffer. The width of the window is normally equal to the longest visible line in the
It can be limited with the "maxwidth" property. You can use spaces to buffer. It can be limited with the "maxwidth" property. You can use spaces
increase the width or use the "minwidth" property. to increase the width or use the "minwidth" property.
By default the 'wrap' option is set, so that no text disappears. Otherwise, By default the 'wrap' option is set, so that no text disappears. Otherwise,
if there is not enough space then the window is shifted left in order to if there is not enough space then the window is shifted left in order to

View File

@ -179,7 +179,7 @@ name on the 'VimRegistry' property on the root window.
A non GUI Vim with access to the X11 display (|xterm-clipboard| enabled), can A non GUI Vim with access to the X11 display (|xterm-clipboard| enabled), can
also act as a command server if a server name is explicitly given with the also act as a command server if a server name is explicitly given with the
--servername argument, or when Vim was build with the |+autoservername| --servername argument, or when Vim was built with the |+autoservername|
feature. feature.
An empty --servername argument will cause the command server to be disabled. An empty --servername argument will cause the command server to be disabled.

View File

@ -1,4 +1,4 @@
*syntax.txt* For Vim version 8.2. Last change: 2020 Jul 08 *syntax.txt* For Vim version 8.2. Last change: 2020 Jul 28
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -3648,7 +3648,7 @@ DEFINING FOLDLEVEL *:syn-foldlevel*
start: Use level of item containing start of line. start: Use level of item containing start of line.
minimum: Use lowest local-minimum level of items on line. minimum: Use lowest local-minimum level of items on line.
The default is 'start'. Use 'minimum' to search a line horizontally The default is "start". Use "minimum" to search a line horizontally
for the lowest level contained on the line that is followed by a for the lowest level contained on the line that is followed by a
higher level. This produces more natural folds when syntax items higher level. This produces more natural folds when syntax items
may close and open horizontally within a line. may close and open horizontally within a line.
@ -3795,9 +3795,9 @@ DEFINING REGIONS *:syn-region* *:syn-start* *:syn-skip* *:syn-end*
[keepend] [keepend]
[extend] [extend]
[excludenl] [excludenl]
start={start_pattern} .. start={start-pattern} ..
[skip={skip_pattern}] [skip={skip-pattern}]
end={end_pattern} .. end={end-pattern} ..
[{options}] [{options}]
This defines one region. It may span several lines. This defines one region. It may span several lines.
@ -3819,12 +3819,12 @@ DEFINING REGIONS *:syn-region* *:syn-start* *:syn-skip* *:syn-end*
extend a containing match or item. Only extend a containing match or item. Only
useful for end patterns. Must be given before useful for end patterns. Must be given before
the patterns it applies to. |:syn-excludenl| the patterns it applies to. |:syn-excludenl|
start={start_pattern} The search pattern that defines the start of start={start-pattern} The search pattern that defines the start of
the region. See |:syn-pattern| below. the region. See |:syn-pattern| below.
skip={skip_pattern} The search pattern that defines text inside skip={skip-pattern} The search pattern that defines text inside
the region where not to look for the end the region where not to look for the end
pattern. See |:syn-pattern| below. pattern. See |:syn-pattern| below.
end={end_pattern} The search pattern that defines the end of end={end-pattern} The search pattern that defines the end of
the region. See |:syn-pattern| below. the region. See |:syn-pattern| below.
Example: > Example: >

View File

@ -5744,6 +5744,7 @@ cino-J indent.txt /*cino-J*
cino-L indent.txt /*cino-L* cino-L indent.txt /*cino-L*
cino-M indent.txt /*cino-M* cino-M indent.txt /*cino-M*
cino-N indent.txt /*cino-N* cino-N indent.txt /*cino-N*
cino-P indent.txt /*cino-P*
cino-U indent.txt /*cino-U* cino-U indent.txt /*cino-U*
cino-W indent.txt /*cino-W* cino-W indent.txt /*cino-W*
cino-^ indent.txt /*cino-^* cino-^ indent.txt /*cino-^*

View File

@ -1,4 +1,4 @@
*todo.txt* For Vim version 8.2. Last change: 2020 Jul 26 *todo.txt* For Vim version 8.2. Last change: 2020 Aug 05
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -39,10 +39,9 @@ browser use: https://github.com/vim/vim/issues/1234
-------------------- Known bugs and current work ----------------------- -------------------- Known bugs and current work -----------------------
Making everything work: Making everything work:
- more items in https://github.com/vim/vim/issues/6507
- More "goto failed" with check for trylevel.
- memory leak in test_vim9_script
- Check that when sourcing a Vim9 script, only the global items can be used. - Check that when sourcing a Vim9 script, only the global items can be used.
- Make string indexes character indexes instead of byte indexes. (#6574)
explain how to use byte index when needed. Use blob?
- :put with a "=" register argument doesn't work, need to find the expression - :put with a "=" register argument doesn't work, need to find the expression
and compile it. (#6397) and compile it. (#6397)
- At the script level, keep script variables local to the block they are - At the script level, keep script variables local to the block they are
@ -51,6 +50,8 @@ Making everything work:
- Implement { } block at the script level. - Implement { } block at the script level.
- need to check type when a declaration specifies a type: #6507 - need to check type when a declaration specifies a type: #6507
let nr: number = 'asdf' let nr: number = 'asdf'
- Make sure that in vim9script a function call without namespace only finds
the script-local function, not a global one.
- Make map() give an error if the resulting type is wrong. - Make map() give an error if the resulting type is wrong.
Add mapnew() to create a new List/Dict for the result, which can have a Add mapnew() to create a new List/Dict for the result, which can have a
different value type. different value type.
@ -169,7 +170,7 @@ Popup windows:
- Figure out the size and position better if wrapping inserts indent - Figure out the size and position better if wrapping inserts indent
Text properties: Text properties:
- :goto does not go to the right place when test properties are present. - :goto does not go to the right place when text properties are present.
(#5930) (#5930)
- "cc" does not call inserted_bytes(). (Axel Forsman, #5763) - "cc" does not call inserted_bytes(). (Axel Forsman, #5763)
- Get E685 with a sequence of commands. (#5674) - Get E685 with a sequence of commands. (#5674)
@ -200,7 +201,7 @@ Terminal debugger:
an already running program. (M. Kelly) an already running program. (M. Kelly)
- When only gdb window exists, on "quit" edit another buffer. - When only gdb window exists, on "quit" edit another buffer.
- Use a sign group - Use a sign group
- Termdebug does not work when Vim was build with mzscheme: gdb hangs just - Termdebug does not work when Vim was built with mzscheme: gdb hangs just
after "run". Everything else works, including communication channel. Not after "run". Everything else works, including communication channel. Not
initializing mzscheme avoid the problem, thus it's not some #ifdef. initializing mzscheme avoid the problem, thus it's not some #ifdef.
- Add support for lldb? issue #3565 - Add support for lldb? issue #3565
@ -255,10 +256,15 @@ Terminal emulator window:
Error numbers available: Error numbers available:
E610, E611, E653 E610, E611, E653
Clean up empty entries in testdir/Make_all.mak
Remove SPACE_IN_FILENAME ? It is only used for completion. Remove SPACE_IN_FILENAME ? It is only used for completion.
Patch to use collaction based sorting. (Christian Brabandt, #6229) Patch to use collaction based sorting. (Christian Brabandt, #6229)
Add 'termguiattr' option, use "gui=" attributes in the terminal? Would work
with 'termguicolors'. #1740
Can we detect true color support? https://gist.github.com/XVilka/8346728 Can we detect true color support? https://gist.github.com/XVilka/8346728
Try setting a color then request the current color, like using t_u7. Try setting a color then request the current color, like using t_u7.
@ -333,6 +339,9 @@ character. (#6154)
undo result wrong: Masato Nishihata, #4798 undo result wrong: Masato Nishihata, #4798
After recovering from a swap file the undofile should not be used, it causes
corruption. (#6631)
When 'lazyredraw' is set sometimes the title is not updated. When 'lazyredraw' is set sometimes the title is not updated.
(Jason Franklin, 2020 Feb 3) Looks like a race condition. (Jason Franklin, 2020 Feb 3) Looks like a race condition.
@ -1471,7 +1480,7 @@ Zero-out krypt key information when no longer in use. (Ben Fritz, 2017 May 15)
Add stronger encryption. Could use libsodium (NaCl). Add stronger encryption. Could use libsodium (NaCl).
https://github.com/jedisct1/libsodium/ https://github.com/jedisct1/libsodium/
Possibly include the needed code so that it can be build everywhere. Possibly include the needed code so that it can be built everywhere.
Add a way to restart a timer. It's similar to timer_stop() and timer_start(), Add a way to restart a timer. It's similar to timer_stop() and timer_start(),
but the reference remains valid. but the reference remains valid.
@ -3833,8 +3842,6 @@ Macintosh:
8 When write_viminfo() is used while there are many orphaned viminfo 8 When write_viminfo() is used while there are many orphaned viminfo
tempfiles writing the viminfo file fails. Give a clear error message so tempfiles writing the viminfo file fails. Give a clear error message so
that the user knows he has to delete the files. that the user knows he has to delete the files.
7 It's possible to redefine a script-local function with ":func
<SNR>123_Test()". (Krishna) Disallow this.
I can't reproduce these (if you can, let me know how!): I can't reproduce these (if you can, let me know how!):
@ -5673,7 +5680,7 @@ Buffer list:
Also for other windows: ":inwin {winnr} {cmd}". How to make sure that Also for other windows: ":inwin {winnr} {cmd}". How to make sure that
this works properly for all commands, and still be able to return to the this works properly for all commands, and still be able to return to the
current buffer/window? E.g.: ":inbuf xxx only". current buffer/window? E.g.: ":inbuf xxx only".
8 Add File.{recent_files} menu entries: Recently edited files. 8 Add File.{recent-files} menu entries: Recently edited files.
Ron Aaron has a plugin for this: mru.vim. Ron Aaron has a plugin for this: mru.vim.
8 Unix: Check all uses of fnamecmp() and fnamencmp() if they should check 8 Unix: Check all uses of fnamecmp() and fnamencmp() if they should check
inode too. inode too.

View File

@ -161,7 +161,7 @@ line break.
============================================================================== ==============================================================================
*04.3* Repeating a change *04.3* Repeating a change
The "." command is one of the most simple yet powerful commands in Vim. It The "." command is one of the simplest yet powerful commands in Vim. It
repeats the last change. For instance, suppose you are editing an HTML file repeats the last change. For instance, suppose you are editing an HTML file
and want to delete all the <B> tags. You position the cursor on the first < and want to delete all the <B> tags. You position the cursor on the first <
and delete the <B> with the command "df>". You then go to the < of the next and delete the <B> with the command "df>". You then go to the < of the next

View File

@ -58,8 +58,8 @@ This initializes Vim for new users (as opposed to traditional Vi users). See
|defaults.vim| for the details. |defaults.vim| for the details.
The vimrc file can contain all the commands that you type after a colon. The The vimrc file can contain all the commands that you type after a colon. The
most simple ones are for setting options. For example, if you want Vim to simplest ones are for setting options. For example, if you want Vim to always
always start with the 'incsearch' option on, add this line your vimrc file: > start with the 'incsearch' option on, add this line your vimrc file: >
set incsearch set incsearch

View File

@ -327,10 +327,10 @@ for next.
============================================================================== ==============================================================================
*20.5* Command line window *20.5* Command line window
Typing the text in the command line works different from typing text in Insert Typing the text in the command line works differently from typing text in
mode. It doesn't allow many commands to change the text. For most commands Insert mode. It doesn't allow many commands to change the text. For most
that's OK, but sometimes you have to type a complicated command. That's where commands that's OK, but sometimes you have to type a complicated command.
the command line window is useful. That's where the command line window is useful.
Open the command line window with this command: > Open the command line window with this command: >

View File

@ -336,7 +336,7 @@ How to do that is explained here: |indent-expression|.
============================================================================== ==============================================================================
*30.4* Other indenting *30.4* Other indenting
The most simple form of automatic indenting is with the 'autoindent' option. The simplest form of automatic indenting is with the 'autoindent' option.
It uses the indent from the previous line. A bit smarter is the 'smartindent' It uses the indent from the previous line. A bit smarter is the 'smartindent'
option. This is useful for languages where no indent file is available. option. This is useful for languages where no indent file is available.
'smartindent' is not as smart as 'cindent', but smarter than 'autoindent'. 'smartindent' is not as smart as 'cindent', but smarter than 'autoindent'.

View File

@ -1,4 +1,4 @@
*usr_31.txt* For Vim version 8.2. Last change: 2007 May 08 *usr_31.txt* For Vim version 8.2. Last change: 2020 Jul 28
VIM USER MANUAL - by Bram Moolenaar VIM USER MANUAL - by Bram Moolenaar
@ -198,9 +198,9 @@ is not possible in most terminals.
You can start the X-Windows version of gvim with an argument to specify the You can start the X-Windows version of gvim with an argument to specify the
size and position of the window: > size and position of the window: >
gvim -geometry {width}x{height}+{x_offset}+{y_offset} gvim -geometry {width}x{height}+{x-offset}+{y-offset}
{width} and {height} are in characters, {x_offset} and {y_offset} are in {width} and {height} are in characters, {x-offset} and {y-offset} are in
pixels. Example: > pixels. Example: >
gvim -geometry 80x25+100+300 gvim -geometry 80x25+100+300

View File

@ -1,4 +1,4 @@
*usr_40.txt* For Vim version 8.2. Last change: 2013 Aug 05 *usr_40.txt* For Vim version 8.2. Last change: 2020 Jul 28
VIM USER MANUAL - by Bram Moolenaar VIM USER MANUAL - by Bram Moolenaar
@ -453,12 +453,12 @@ matching BufWritePre autocommands and executes them, and then it
performs the ":write". performs the ":write".
The general form of the :autocmd command is as follows: > The general form of the :autocmd command is as follows: >
:autocmd [group] {events} {file_pattern} [nested] {command} :autocmd [group] {events} {file-pattern} [nested] {command}
The [group] name is optional. It is used in managing and calling the commands The [group] name is optional. It is used in managing and calling the commands
(more on this later). The {events} parameter is a list of events (comma (more on this later). The {events} parameter is a list of events (comma
separated) that trigger the command. separated) that trigger the command.
{file_pattern} is a filename, usually with wildcards. For example, using {file-pattern} is a filename, usually with wildcards. For example, using
"*.txt" makes the autocommand be used for all files whose name end in ".txt". "*.txt" makes the autocommand be used for all files whose name end in ".txt".
The optional [nested] flag allows for nesting of autocommands (see below), and The optional [nested] flag allows for nesting of autocommands (see below), and
finally, {command} is the command to be executed. finally, {command} is the command to be executed.
@ -489,7 +489,7 @@ See |autocmd-events| for a complete list of events.
PATTERNS PATTERNS
The {file_pattern} argument can actually be a comma-separated list of file The {file-pattern} argument can actually be a comma-separated list of file
patterns. For example: "*.c,*.h" matches files ending in ".c" and ".h". patterns. For example: "*.c,*.h" matches files ending in ".c" and ".h".
The usual file wildcards can be used. Here is a summary of the most often The usual file wildcards can be used. Here is a summary of the most often
used ones: used ones:

View File

@ -44,7 +44,7 @@ script file. You can think of other uses yourself.
If you are familiar with Python, you can find a comparison between If you are familiar with Python, you can find a comparison between
Python and Vim script here, with pointers to other documents: Python and Vim script here, with pointers to other documents:
https://gist.github.com/yegappan/16d964a37ead0979b05e655aa036cad0 https://gist.github.com/yegappan/16d964a37ead0979b05e655aa036cad0
And if you are familiar with Javascript: And if you are familiar with JavaScript:
https://w0rp.com/blog/post/vim-script-for-the-javascripter/ https://w0rp.com/blog/post/vim-script-for-the-javascripter/
Let's start with a simple example: > Let's start with a simple example: >
@ -2108,7 +2108,7 @@ Thus when a user types "\a", this sequence is invoked: >
\a -> <Plug>TypecorrAdd -> <SID>Add -> :call <SID>Add() \a -> <Plug>TypecorrAdd -> <SID>Add -> :call <SID>Add()
If another script would also map <SID>Add, it would get another script ID and If another script was also map <SID>Add, it would get another script ID and
thus define another mapping. thus define another mapping.
Note that instead of s:Add() we use <SID>Add() here. That is because the Note that instead of s:Add() we use <SID>Add() here. That is because the

View File

@ -210,8 +210,8 @@ argument: >
:amenu <silent> Mine.Next\ File :call <SID>NextFile()<CR> :amenu <silent> Mine.Next\ File :call <SID>NextFile()<CR>
Don't use "<silent>" too often. It is not needed for short commands. If you Don't use "<silent>" too often. It is not needed for short commands. If you
make a menu for someone else, being able the see the executed command will make a menu for someone else, being able to see the executed command will give
give him a hint about what he could have typed, instead of using the mouse. him a hint about what he could have typed, instead of using the mouse.
LISTING MENUS LISTING MENUS

View File

@ -34,7 +34,7 @@ That makes very clear what is defined where.
Let's start with an example, a script that exports one function and has one Let's start with an example, a script that exports one function and has one
private function: > private function: >
vim9script " This indicates a Vim9 script file, vim9script " This indicates a Vim9 script file.
export def GetMessage(): string export def GetMessage(): string
let result = '' let result = ''

View File

@ -333,7 +333,7 @@ Make Vim work as you like it.
|44.11| Installing a syntax file |44.11| Installing a syntax file
|44.12| Portable syntax file layout |44.12| Portable syntax file layout
|usr_45.txt| Select your language |usr_45.txt| Select your language (locale)
|45.1| Language for Messages |45.1| Language for Messages
|45.2| Language for Menus |45.2| Language for Menus
|45.3| Using another encoding |45.3| Using another encoding

View File

@ -1,4 +1,4 @@
*vim9.txt* For Vim version 8.2. Last change: 2020 Jul 25 *vim9.txt* For Vim version 8.2. Last change: 2020 Aug 01
VIM REFERENCE MANUAL by Bram Moolenaar VIM REFERENCE MANUAL by Bram Moolenaar
@ -14,7 +14,7 @@ features in Vim9 script.
THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
1 What is Vim9 script? |vim9-script| 1. What is Vim9 script? |vim9-script|
2. Differences |vim9-differences| 2. Differences |vim9-differences|
3. New style functions |fast-functions| 3. New style functions |fast-functions|
4. Types |vim9-types| 4. Types |vim9-types|
@ -119,11 +119,12 @@ Functions and variables are script-local by default ~
When using `:function` or `:def` to specify a new function at the script level When using `:function` or `:def` to specify a new function at the script level
in a Vim9 script, the function is local to the script, as if "s:" was in a Vim9 script, the function is local to the script, as if "s:" was
prefixed. Using the "s:" prefix is optional. To define or use a global prefixed. Using the "s:" prefix is optional. To define or use a global
function or variable the "g:" prefix must be used. For functions in an function or variable the "g:" prefix should be used. For functions in an
autoload script the "name#" prefix is sufficient. > autoload script the "name#" prefix is sufficient. >
def ThisFunction() # script-local def ThisFunction() # script-local
def s:ThisFunction() # script-local def s:ThisFunction() # script-local
def g:ThatFunction() # global def g:ThatFunction() # global
def ThatFunction() # global if no local ThatFunction()
def scriptname#function() # autoload def scriptname#function() # autoload
When using `:function` or `:def` to specify a new function inside a function, When using `:function` or `:def` to specify a new function inside a function,
@ -132,16 +133,14 @@ script-local function inside a function. It is possible to define a global
function, using the "g:" prefix. function, using the "g:" prefix.
When referring to a function and no "s:" or "g:" prefix is used, Vim will When referring to a function and no "s:" or "g:" prefix is used, Vim will
search for the function in this order: prefer using a local function (in the function scope, script scope or
- Local to the current scope and outer scopes up to the function scope. imported) before looking for a global function.
- Local to the current script file.
- Imported functions, see `:import`.
In all cases the function must be defined before used. That is when it is In all cases the function must be defined before used. That is when it is
first called or when `:defcompile` causes the call to be compiled. first called or when `:defcompile` causes the call to be compiled.
The result is that functions and variables without a namespace can always be The result is that functions and variables without a namespace can usually be
found in the script, either defined there or imported. Global functions and found in the script, either defined there or imported. Global functions and
variables could be defined anywhere (good luck finding where!). variables could be defined anywhere (good luck finding out where!).
Global functions can be still be defined and deleted at nearly any time. In Global functions can be still be defined and deleted at nearly any time. In
Vim9 script script-local functions are defined once when the script is sourced Vim9 script script-local functions are defined once when the script is sourced
@ -193,7 +192,8 @@ declaration. Global, window, tab, buffer and Vim variables can only be used
without `:let`, because they are not really declared, they can also be deleted without `:let`, because they are not really declared, they can also be deleted
with `:unlet`. with `:unlet`.
Variables cannot shadow previously defined variables. Variables and functions cannot shadow previously defined or imported variables
and functions.
Variables may shadow Ex commands, rename the variable if needed. Variables may shadow Ex commands, rename the variable if needed.
Global variables and user defined functions must be prefixed with "g:", also Global variables and user defined functions must be prefixed with "g:", also
@ -232,11 +232,11 @@ identifier or can't be an Ex command. Examples: >
'foobar'->Process() 'foobar'->Process()
('foobar')->Process() ('foobar')->Process()
In rare case there is ambiguity between a function name and an Ex command, use In rare case there is ambiguity between a function name and an Ex command,
":" to make clear you want to use the Ex command. For example, there is both prepend ":" to make clear you want to use the Ex command. For example, there
the `:substitute` command and the `substitute()` function. When the line is both the `:substitute` command and the `substitute()` function. When the
starts with `substitute(` this will use the function. Prepend a colon to use line starts with `substitute(` this will use the function. Prepend a colon to
the command instead: > use the command instead: >
:substitute(pattern (replacement ( :substitute(pattern (replacement (
Note that while variables need to be defined before they can be used, Note that while variables need to be defined before they can be used,
@ -261,8 +261,8 @@ number of arguments and any return type. The function can be defined later.
Automatic line continuation ~ Automatic line continuation ~
In many cases it is obvious that an expression continues on the next line. In In many cases it is obvious that an expression continues on the next line. In
those cases there is no need to prefix the line with a backslash. For those cases there is no need to prefix the line with a backslash
example, when a list spans multiple lines: > |line-continuation|. For example, when a list spans multiple lines: >
let mylist = [ let mylist = [
'one', 'one',
'two', 'two',
@ -452,6 +452,11 @@ Ex command ranges need to be prefixed with a colon. >
'text'->func() " Vim9: method call 'text'->func() " Vim9: method call
:'t " legacy Vim: jump to mark m :'t " legacy Vim: jump to mark m
Some Ex commands can be confused with assignments in Vim9 script: >
g:name = value # assignment
g:pattern:cmd # invalid command - ERROR
:g:pattern:cmd # :global command
Functions defined with `:def` compile the whole function. Legacy functions Functions defined with `:def` compile the whole function. Legacy functions
can bail out, and the following lines are not parsed: > can bail out, and the following lines are not parsed: >
func Maybe() func Maybe()

View File

@ -125,7 +125,7 @@ gN Like |gn| but searches backward, like with `N`.
*<LeftMouse>* *<LeftMouse>*
<LeftMouse> Set the current cursor position. If Visual mode is <LeftMouse> Set the current cursor position. If Visual mode is
active it is stopped. Only when 'mouse' option is active it is stopped. Only when 'mouse' option
contains 'n' or 'a'. If the position is within 'so' contains 'n' or 'a'. If the position is within 'so'
lines from the last line on the screen the text is lines from the last line on the screen the text is
scrolled up. If the position is within 'so' lines from scrolled up. If the position is within 'so' lines from
@ -136,7 +136,7 @@ gN Like |gn| but searches backward, like with `N`.
<RightMouse> Start Visual mode if it is not active. The text from <RightMouse> Start Visual mode if it is not active. The text from
the cursor position to the position of the click is the cursor position to the position of the click is
highlighted. If Visual mode was already active move highlighted. If Visual mode was already active move
the start or end of the highlighted text, which ever the start or end of the highlighted text, whichever
is closest, to the position of the click. Only when is closest, to the position of the click. Only when
'mouse' option contains 'n' or 'a'. 'mouse' option contains 'n' or 'a'.
@ -236,7 +236,7 @@ The objects that can be used are:
is inner sentence |v_is| is inner sentence |v_is|
ap a paragraph (with white space) |v_ap| ap a paragraph (with white space) |v_ap|
ip inner paragraph |v_ip| ip inner paragraph |v_ip|
ab a () block (with parenthesis) |v_ab| ab a () block (with parentheses) |v_ab|
ib inner () block |v_ib| ib inner () block |v_ib|
aB a {} block (with braces) |v_aB| aB a {} block (with braces) |v_aB|
iB inner {} block |v_iB| iB inner {} block |v_iB|
@ -347,7 +347,7 @@ Visual-block Shift *v_b_>*
The block is shifted by 'shiftwidth'. The RHS of the block is irrelevant. The The block is shifted by 'shiftwidth'. The RHS of the block is irrelevant. The
LHS of the block determines the point from which to apply a right shift, and LHS of the block determines the point from which to apply a right shift, and
padding includes TABs optimally according to 'ts' and 'et'. The LHS of the padding includes TABs optimally according to 'ts' and 'et'. The LHS of the
block determines the point upto which to shift left. block determines the point up to which to shift left.
See |v_b_>_example|. See |v_b_>_example|.
See |v_b_<_example|. See |v_b_<_example|.

View File

@ -1,7 +1,7 @@
" Vim support file to detect file types " Vim support file to detect file types
" "
" Maintainer: Bram Moolenaar <Bram@vim.org> " Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2020 Jun 25 " Last Change: 2020 Aug 04
" Listen very carefully, I will say this only once " Listen very carefully, I will say this only once
if exists("did_load_filetypes") if exists("did_load_filetypes")

View File

@ -83,7 +83,7 @@ endif
if exists("loaded_matchit") if exists("loaded_matchit")
let b:match_ignorecase = 0 let b:match_ignorecase = 0
let b:match_words = let b:match_words =
\ '\<\%(fu\%[nction]\|def\)\>[^(]:\<retu\%[rn]\>:\<\%(endf\%[unction]\|enddef\)\>,' . \ '\<\%(fu\%[nction]\|def\)\>)\@!:\<retu\%[rn]\>:\<\%(endf\%[unction]\|enddef\)\>,' .
\ '\<\(wh\%[ile]\|for\)\>:\<brea\%[k]\>:\<con\%[tinue]\>:\<end\(w\%[hile]\|fo\%[r]\)\>,' . \ '\<\(wh\%[ile]\|for\)\>:\<brea\%[k]\>:\<con\%[tinue]\>:\<end\(w\%[hile]\|fo\%[r]\)\>,' .
\ '\<if\>:\<el\%[seif]\>:\<en\%[dif]\>,' . \ '\<if\>:\<el\%[seif]\>:\<en\%[dif]\>,' .
\ '{:},' . \ '{:},' .

View File

@ -0,0 +1,114 @@
" Vim keymap file for Turkish F layout
" Maintainer: Emir SARI <bitigchi@me.com>
" Last changed: 5 August 2020
scriptencoding utf-8
let b:keymap_name = "tr-f"
loadkeymap
F A LATIN CAPITAL LETTER A
< B LATIN CAPITAL LETTER B
V C LATIN CAPITAL LETTER C
B Ç LATIN CAPITAL LETTER C WITH CEDILLA
Y D LATIN CAPITAL LETTER D
D E LATIN CAPITAL LETTER E
Q F LATIN CAPITAL LETTER F
W G LATIN CAPITAL LETTER G
E Ğ LATIN CAPITAL LETTER G WITH BREVE
O H LATIN CAPITAL LETTER H
R I LATIN CAPITAL LETTER I
S İ LATIN CAPITAL LETTER I WITH DOT ABOVE
Z J LATIN CAPITAL LETTER J
J K LATIN CAPITAL LETTER K
K M LATIN CAPITAL LETTER M
I N LATIN CAPITAL LETTER N
T O LATIN CAPITAL LETTER O
X Ö LATIN CAPITAL LETTER O WITH DIAERESIS
U R LATIN CAPITAL LETTER R
M S LATIN CAPITAL LETTER S
\" Ş LATIN CAPITAL LETTER S WITH CEDILLA
H T LATIN CAPITAL LETTER T
A U LATIN CAPITAL LETTER U
G Ü LATIN CAPITAL LETTER U WITH DIAERESIS
C V LATIN CAPITAL LETTER V
: Y LATIN CAPITAL LETTER Y
N Z LATIN CAPITAL LETTER Z
{ Q LATIN CAPITAL LETTER Q
} W LATIN CAPITAL LETTER W
| X LATIN CAPITAL LETTER X
± * ASTERISK
@ " QUOTATION MARK
# ^ CIRCUMFLEX ACCENT
^ & AMPERSAND
& ' APOSTROPHE
* ( LEFT PARENTHESIS
( ) RIGHT PARENTHESIS
) = EQUALS SIGN
_ ? QUESTION MARK
+ _ LOW LINE
> : COLON
? ; SEMICOLON
~ > GREATER-THAN SIGN
Å Û LATIN CAPITAL LETTER U WITH CIRCUMFLEX
Í Î LATIN CAPITAL LETTER I WITH CIRCUMFLEX
Ï Â LATIN CAPITAL LETTER A WITH CIRCUMFLEX
` » RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK
f a LATIN SMALL LETTER A
, b LATIN SMALL LETTER B
v c LATIN SMALL LETTER C
b ç LATIN SMALL LETTER C WITH CEDILLA
y d LATIN SMALL LETTER D
d e LATIN SMALL LETTER E
q f LATIN SMALL LETTER F
w g LATIN SMALL LETTER G
e ğ LATIN SMALL LETTER G WITH BREVE
o h LATIN SMALL LETTER H
r ı LATIN SMALL LETTER I
s i LATIN SMALL LETTER I WITH DOT ABOVE
z j LATIN SMALL LETTER J
j k LATIN SMALL LETTER K
k m LATIN SMALL LETTER M
i n LATIN SMALL LETTER N
t o LATIN SMALL LETTER O
x ö LATIN SMALL LETTER O WITH DIAERESIS
u r LATIN SMALL LETTER R
m s LATIN SMALL LETTER S
\' ş LATIN SMALL LETTER S WITH CEDILLA
h t LATIN SMALL LETTER T
a u LATIN SMALL LETTER U
g ü LATIN SMALL LETTER U WITH DIAERESIS
c v LATIN SMALL LETTER V
; y LATIN SMALL LETTER Y
n z LATIN SMALL LETTER Z
[ q LATIN SMALL LETTER Q
] w LATIN SMALL LETTER W
\\ x LATIN SMALL LETTER X
§ + PLUS SIGN
- / SOLIDUS
= - HYPHEN-MINUS
/ , COMMA
` < LESS-THAN SIGN
£ # NUMBER SIGN
¶ { LEFT CURLY BRACKET
• [ LEFT SQUARE BRACKET
ª ] RIGHT SQUARE BRACKET
º } RIGHT CURLY BRACKET
\ REVERSE SOLIDUS
| VERTICAL LINE
œ @ COMMERCIAL AT
~ TILDE
å û LATIN SMALL LETTER U WITH CIRCUMFLEX
ß î LATIN SMALL LETTER I WITH CIRCUMFLEX
∂ € EURO SIGN
ƒ â LATIN SMALL LETTER A WITH CIRCUMFLEX
˙ ₺ TURKISH LIRA SIGN
¬ £ POUND SIGN
… ¥ YEN SIGN
` « LEFT-POINTING DOUBLE ANGLE QUOTATION MARK

View File

@ -0,0 +1,62 @@
" Vim keymap file for Turkish Q layout
" Maintainer: Emir SARI <bitigchi@me.com>
" Last changed: 5 August 2020
scriptencoding utf-8
let b:keymap_name = "tr-q"
loadkeymap
\> Ç LATIN CAPITAL LETTER C WITH CEDILLA
\{ Ğ LATIN CAPITAL LETTER G WITH BREVE
\" İ LATIN CAPITAL LETTER I WITH DOT ABOVE
\< Ö LATIN CAPITAL LETTER O WITH DIAERESIS
\: Ş LATIN CAPITAL LETTER S WITH CEDILLA
\} Ü LATIN CAPITAL LETTER U WITH DIAERESIS
± é LATIN SMALL LETTER E WITH ACUTE
@ ' APOSTROPHE
# ^ CIRCUMFLEX ACCENT
$ + PLUS SIGN
^ & AMPERSAND
& / SOLIDUS
* ( LEFT PARENTHESIS
( ) RIGHT PARENTHESIS
) = EQUAL SIGN
_ ? QUESTION MARK
+ _ LOW LINE
~ > GREATER-THAN SIGN
| ; SEMICOLON
? : COLON
\. ç LATIN SMALL LETTER C WITH CEDILLA
\[ ğ LATIN SMALL LETTER G WITH BREVE
\' i LATIN SMALL LETTER I
\, ö LATIN SMALL LETTER O WITH DIAERESIS
\; ş LATIN SMALL LETTER S WITH CEDILLA
\] ü LATIN SMALL LETTER U WITH DIAERESIS
i ı LATIN SMALL LETTER DOTLESS I
§ " QUOTATION MARK
- * ASTERISK
= - HYPHEN-MINUS
\\ , COMMA
\/ . FULL STOP
` < LESS-THAN SIGN
™ £ POUND SIGN
£ # NUMBER SIGN
¢ $ DOLLAR SIGN
∞ ½ VULGAR FRACTION ONE HALF
¶ { LEFT CURLY BRACKET
• [ LEFT SQUARE BRACKET
ª ] RIGHT SQUARE BRACKET
º } RIGHT CURLY BRACKET
\ REVERSE SOLIDUS
| VERTICAL LINE
œ @ COMMERCIAL AT
´EURO SIGN
† ₺ TURKISH LIRA SIGN
¥ ¥ YEN SIGN
~ TILDE
´ ACUTE ACCENT
« ` GRAVE ACCENT

View File

@ -1,11 +1,12 @@
" Vim syntax file " Vim syntax file
" Language: Cascading Style Sheets " Language: Cascading Style Sheets
" Previous Contributor List: " Previous Contributor List:
" Jules Wang <w.jq0722@gmail.com>
" Claudio Fleiner <claudio@fleiner.com> (Maintainer) " Claudio Fleiner <claudio@fleiner.com> (Maintainer)
" Yeti (Add full CSS2, HTML4 support) " Yeti (Add full CSS2, HTML4 support)
" Nikolai Weibull (Add CSS2 support) " Nikolai Weibull (Add CSS2 support)
" URL: https://github.com/JulesWang/css.vim " URL: https://github.com/jsit/css.vim
" Maintainer: Jules Wang <w.jq0722@gmail.com> " Maintainer: Jay Sitter <jay@jaysitter.com>
" Last Change: 2019 Jul. 29 " Last Change: 2019 Jul. 29
" quit when a syntax file was already loaded " quit when a syntax file was already loaded
@ -68,7 +69,7 @@ endtry
" digits " digits
syn match cssValueInteger contained "[-+]\=\d\+" contains=cssUnitDecorators syn match cssValueInteger contained "[-+]\=\d\+" contains=cssUnitDecorators
syn match cssValueNumber contained "[-+]\=\d\+\(\.\d*\)\=" contains=cssUnitDecorators syn match cssValueNumber contained "[-+]\=\d\+\(\.\d*\)\=" contains=cssUnitDecorators
syn match cssValueLength contained "[-+]\=\d\+\(\.\d*\)\=\(mm\|cm\|in\|pt\|pc\|em\|ex\|px\|rem\|dpi\|dppx\|dpcm\|fr\|vw\|vh\|vmin\|vmax\)\>" contains=cssUnitDecorators syn match cssValueLength contained "[-+]\=\d\+\(\.\d*\)\=\(mm\|cm\|in\|pt\|pc\|em\|ex\|px\|rem\|dpi\|dppx\|dpcm\|fr\|vw\|vh\|vmin\|vmax\|ch\)\>" contains=cssUnitDecorators
syn match cssValueLength contained "[-+]\=\d\+\(\.\d*\)\=%" contains=cssUnitDecorators syn match cssValueLength contained "[-+]\=\d\+\(\.\d*\)\=%" contains=cssUnitDecorators
syn match cssValueAngle contained "[-+]\=\d\+\(\.\d*\)\=\(deg\|grad\|rad\)\>" contains=cssUnitDecorators syn match cssValueAngle contained "[-+]\=\d\+\(\.\d*\)\=\(deg\|grad\|rad\)\>" contains=cssUnitDecorators
syn match cssValueTime contained "+\=\d\+\(\.\d*\)\=\(ms\|s\)\>" contains=cssUnitDecorators syn match cssValueTime contained "+\=\d\+\(\.\d*\)\=\(ms\|s\)\>" contains=cssUnitDecorators
@ -128,12 +129,14 @@ syn region cssFunction contained matchgroup=cssFunctionName start="\<\(rgb\|clip
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(rgba\|hsl\|hsla\|color-stop\|from\|to\)\s*(" end=")" oneline contains=cssColor,cssValueInteger,cssValueNumber,cssValueLength,cssFunctionComma,cssFunction syn region cssFunction contained matchgroup=cssFunctionName start="\<\(rgba\|hsl\|hsla\|color-stop\|from\|to\)\s*(" end=")" oneline contains=cssColor,cssValueInteger,cssValueNumber,cssValueLength,cssFunctionComma,cssFunction
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(linear-\|radial-\)\=\gradient\s*(" end=")" oneline contains=cssColor,cssValueInteger,cssValueNumber,cssValueLength,cssFunction,cssGradientAttr,cssFunctionComma syn region cssFunction contained matchgroup=cssFunctionName start="\<\(linear-\|radial-\)\=\gradient\s*(" end=")" oneline contains=cssColor,cssValueInteger,cssValueNumber,cssValueLength,cssFunction,cssGradientAttr,cssFunctionComma
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(matrix\(3d\)\=\|scale\(3d\|X\|Y\|Z\)\=\|translate\(3d\|X\|Y\|Z\)\=\|skew\(X\|Y\)\=\|rotate\(3d\|X\|Y\|Z\)\=\|perspective\)\s*(" end=")" oneline contains=cssValueInteger,cssValueNumber,cssValueLength,cssValueAngle,cssFunctionComma syn region cssFunction contained matchgroup=cssFunctionName start="\<\(matrix\(3d\)\=\|scale\(3d\|X\|Y\|Z\)\=\|translate\(3d\|X\|Y\|Z\)\=\|skew\(X\|Y\)\=\|rotate\(3d\|X\|Y\|Z\)\=\|perspective\)\s*(" end=")" oneline contains=cssValueInteger,cssValueNumber,cssValueLength,cssValueAngle,cssFunctionComma
syn region cssFunction contained matchgroup=cssFunctionName start="\<\(blur\|brightness\|contrast\|drop-shadow\|grayscale\|hue-rotate\|invert\|opacity\|saturate\|sepia\)\s*(" end=")" oneline contains=cssValueInteger,cssValueNumber,cssValueLength,cssValueAngle,cssFunctionComma
syn keyword cssGradientAttr contained top bottom left right cover center middle ellipse at syn keyword cssGradientAttr contained top bottom left right cover center middle ellipse at
syn match cssFunctionComma contained "," syn match cssFunctionComma contained ","
" Common Prop and Attr " Common Prop and Attr
syn keyword cssCommonAttr contained auto none inherit all default normal syn keyword cssCommonAttr contained auto none inherit all default normal
syn keyword cssCommonAttr contained top bottom center stretch hidden visible syn keyword cssCommonAttr contained top bottom center stretch hidden visible
syn match cssCommonAttr contained "\<\(max-\|min-\|fit-\)content\>"
"------------------------------------------------ "------------------------------------------------
" CSS Animations " CSS Animations
" http://www.w3.org/TR/css3-animations/ " http://www.w3.org/TR/css3-animations/

View File

@ -2,8 +2,8 @@
" Language: fstab file " Language: fstab file
" Maintainer: Radu Dineiu <radu.dineiu@gmail.com> " Maintainer: Radu Dineiu <radu.dineiu@gmail.com>
" URL: https://raw.github.com/rid9/vim-fstab/master/fstab.vim " URL: https://raw.github.com/rid9/vim-fstab/master/fstab.vim
" Last Change: 2019 Jun 06 " Last Change: 2020 Aug 06
" Version: 1.3 " Version: 1.4
" "
" Credits: " Credits:
" David Necas (Yeti) <yeti@physics.muni.cz> " David Necas (Yeti) <yeti@physics.muni.cz>
@ -68,7 +68,7 @@ syn match fsOptionsString /[a-zA-Z0-9_-]\+/
syn keyword fsOptionsYesNo yes no syn keyword fsOptionsYesNo yes no
syn cluster fsOptionsCheckCluster contains=fsOptionsExt2Check,fsOptionsFatCheck syn cluster fsOptionsCheckCluster contains=fsOptionsExt2Check,fsOptionsFatCheck
syn keyword fsOptionsSize 512 1024 2048 syn keyword fsOptionsSize 512 1024 2048
syn keyword fsOptionsGeneral async atime auto bind current defaults dev devgid devmode devmtime devuid dirsync exec force fstab kudzu loop mand move noatime noauto noclusterr noclusterw nodev nodevmtime nodiratime noexec nomand norelatime nosuid nosymfollow nouser owner rbind rdonly relatime remount ro rq rw suid suiddir supermount sw sync union update user users wxallowed xx nofail syn keyword fsOptionsGeneral async atime auto bind current defaults dev devgid devmode devmtime devuid dirsync exec force fstab kudzu loop mand move noatime noauto noclusterr noclusterw nodev nodevmtime nodiratime noexec nomand norelatime nosuid nosymfollow nouser owner rbind rdonly relatime remount ro rq rw suid suiddir supermount sw sync union update user users wxallowed xx nofail failok
syn match fsOptionsGeneral /_netdev/ syn match fsOptionsGeneral /_netdev/
" Options: adfs " Options: adfs

View File

@ -1,7 +1,7 @@
" Vim syntax file " Vim syntax file
" Language: Vim help file " Language: Vim help file
" Maintainer: Bram Moolenaar (Bram@vim.org) " Maintainer: Bram Moolenaar (Bram@vim.org)
" Last Change: 2020 Mar 06 " Last Change: 2020 Jul 28
" Quit when a (custom) syntax file was already loaded " Quit when a (custom) syntax file was already loaded
if exists("b:current_syntax") if exists("b:current_syntax")

View File

@ -1,7 +1,8 @@
" Vim syntax file " Vim syntax file
" Language: pam(8) configuration file " Language: pam(8) configuration file
" Previous Maintainer: Nikolai Weibull <now@bitwi.se> " Previous Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2011-08-03 " Latest Revision: 2020/08/04
" Changes By: Haochen Tong
if exists("b:current_syntax") if exists("b:current_syntax")
@ -11,23 +12,32 @@ endif
let s:cpo_save = &cpo let s:cpo_save = &cpo
set cpo&vim set cpo&vim
syn match pamconfService '^[[:graph:]]\+' let s:has_service_field = exists("b:pamconf_has_service_field")
\ nextgroup=pamconfType, \ ? b:pamconf_has_service_field
\ pamconfServiceLineCont skipwhite \ : expand('%:t') == 'pam.conf' ? 1 : 0
syn match pamconfType '-\?[[:alpha:]]\+'
\ contains=pamconfTypeKeyword
\ nextgroup=pamconfControl,
\ pamconfTypeLineCont skipwhite
syn keyword pamconfTypeKeyword contained account auth password session
if s:has_service_field
syn match pamconfService '^[[:graph:]]\+'
\ nextgroup=pamconfType,
\ pamconfServiceLineCont skipwhite
syn match pamconfServiceLineCont contained '\\$'
\ nextgroup=pamconfType,
\ pamconfServiceLineCont skipwhite skipnl
endif
syn keyword pamconfTodo contained TODO FIXME XXX NOTE syn keyword pamconfTodo contained TODO FIXME XXX NOTE
syn region pamconfComment display oneline start='#' end='$' syn region pamconfComment display oneline start='#' end='$'
\ contains=pamconfTodo,@Spell \ contains=pamconfTodo,@Spell
syn match pamconfServiceLineCont contained '\\$'
\ nextgroup=pamconfType,
\ pamconfServiceLineCont skipwhite skipnl
syn keyword pamconfType account auth password session
\ nextgroup=pamconfControl,
\ pamconfTypeLineCont skipwhite
syn match pamconfTypeLineCont contained '\\$' syn match pamconfTypeLineCont contained '\\$'
\ nextgroup=pamconfControl, \ nextgroup=pamconfControl,
\ pamconfTypeLineCont skipwhite skipnl \ pamconfTypeLineCont skipwhite skipnl
@ -98,7 +108,8 @@ hi def link pamconfTodo Todo
hi def link pamconfComment Comment hi def link pamconfComment Comment
hi def link pamconfService Statement hi def link pamconfService Statement
hi def link pamconfServiceLineCont Special hi def link pamconfServiceLineCont Special
hi def link pamconfType Type hi def link pamconfType Special
hi def link pamconfTypeKeyword Type
hi def link pamconfTypeLineCont pamconfServiceLineCont hi def link pamconfTypeLineCont pamconfServiceLineCont
hi def link pamconfControl Macro hi def link pamconfControl Macro
hi def link pamconfControlBegin Delimiter hi def link pamconfControlBegin Delimiter