forked from aniani/vim
Update runtime files.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
*eval.txt* For Vim version 8.2. Last change: 2021 Feb 10
|
||||
*eval.txt* For Vim version 8.2. Last change: 2021 Mar 10
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -5300,6 +5300,9 @@ getcharpos({expr})
|
||||
Get the position for {expr}. Same as |getpos()| but the column
|
||||
number in the returned List is a character index instead of
|
||||
a byte index.
|
||||
If |getpos()| returns a very large column number, such as
|
||||
2147483647, then getcharpos() will return the character index
|
||||
of the last character.
|
||||
|
||||
Example:
|
||||
With the cursor on '세' in line 5 with text "여보세요": >
|
||||
@@ -5779,6 +5782,8 @@ getpos({expr}) Get the position for {expr}. For possible values of {expr}
|
||||
The column number in the returned List is the byte position
|
||||
within the line. To get the character position in the line,
|
||||
use |getcharpos()|
|
||||
The column number can be very large, e.g. 2147483647, in which
|
||||
case it means "after the end of the line".
|
||||
This can be used to save and restore the position of a mark: >
|
||||
let save_a_mark = getpos("'a")
|
||||
...
|
||||
@@ -7450,7 +7455,8 @@ matchaddpos({group}, {pos} [, {priority} [, {id} [, {dict}]]])
|
||||
to be used when fast match additions and deletions are
|
||||
required, for example to highlight matching parentheses.
|
||||
|
||||
The list {pos} can contain one of these items:
|
||||
{pos} is a list of positions. Each position can be one of
|
||||
these:
|
||||
- A number. This whole line will be highlighted. The first
|
||||
line has number 1.
|
||||
- A list with one number, e.g., [23]. The whole line with this
|
||||
@@ -7463,7 +7469,7 @@ matchaddpos({group}, {pos} [, {priority} [, {id} [, {dict}]]])
|
||||
- A list with three numbers, e.g., [23, 11, 3]. As above, but
|
||||
the third number gives the length of the highlight in bytes.
|
||||
|
||||
The maximum number of positions is 8.
|
||||
The maximum number of positions in {pos} is 8.
|
||||
|
||||
Example: >
|
||||
:highlight MyGroup ctermbg=green guibg=green
|
||||
@@ -7472,8 +7478,7 @@ matchaddpos({group}, {pos} [, {priority} [, {id} [, {dict}]]])
|
||||
:call matchdelete(m)
|
||||
|
||||
< Matches added by |matchaddpos()| are returned by
|
||||
|getmatches()| with an entry "pos1", "pos2", etc., with the
|
||||
value a list like the {pos} item.
|
||||
|getmatches()|.
|
||||
|
||||
Can also be used as a |method|: >
|
||||
GetGroup()->matchaddpos([23, 11])
|
||||
@@ -10273,7 +10278,8 @@ str2nr({expr} [, {base} [, {quoted}]]) *str2nr()*
|
||||
|
||||
strcharpart({src}, {start} [, {len}]) *strcharpart()*
|
||||
Like |strpart()| but using character index and length instead
|
||||
of byte index and length.
|
||||
of byte index and length. Composing characters are counted
|
||||
separately.
|
||||
When a character index is used where a character does not
|
||||
exist it is assumed to be one character. For example: >
|
||||
strcharpart('abc', -1, 2)
|
||||
@@ -13142,7 +13148,7 @@ text...
|
||||
Cannot be followed by a comment.
|
||||
Examples: >
|
||||
:execute "buffer" nextbuf
|
||||
:execute "normal" count . "w"
|
||||
:execute "normal" count .. "w"
|
||||
<
|
||||
":execute" can be used to append a command to commands
|
||||
that don't accept a '|'. Example: >
|
||||
@@ -13158,8 +13164,8 @@ text...
|
||||
file names. The |fnameescape()| function can be used
|
||||
for Vim commands, |shellescape()| for |:!| commands.
|
||||
Examples: >
|
||||
:execute "e " . fnameescape(filename)
|
||||
:execute "!ls " . shellescape(filename, 1)
|
||||
:execute "e " .. fnameescape(filename)
|
||||
:execute "!ls " .. shellescape(filename, 1)
|
||||
<
|
||||
Note: The executed string may be any command-line, but
|
||||
starting or ending "if", "while" and "for" does not
|
||||
|
||||
Reference in New Issue
Block a user