updated for version 7.0208
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
*eval.txt* For Vim version 7.0aa. Last change: 2006 Feb 25
|
||||
*eval.txt* For Vim version 7.0aa. Last change: 2006 Feb 26
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -767,7 +767,7 @@ expr6 + expr6 .. Number addition or |List| concatenation *expr-+*
|
||||
expr6 - expr6 .. Number subtraction *expr--*
|
||||
expr6 . expr6 .. String concatenation *expr-.*
|
||||
|
||||
For |List|s only "+" is possible and then both expr6 must be a list. The
|
||||
For |Lists| only "+" is possible and then both expr6 must be a list. The
|
||||
result is a new list with the two lists Concatenated.
|
||||
|
||||
expr7 * expr7 .. number multiplication *expr-star*
|
||||
@ -1651,11 +1651,11 @@ reverse( {list}) List reverse {list} in-place
|
||||
search( {pattern} [, {flags}]) Number search for {pattern}
|
||||
searchdecl({name} [, {global} [, {thisblock}]])
|
||||
Number search for variable declaration
|
||||
searchpair( {start}, {middle}, {end} [, {flags} [, {skip}]])
|
||||
searchpair( {start}, {middle}, {end} [, {flags} [, {skip} [, {stopline}]]])
|
||||
Number search for other end of start/end pair
|
||||
searchpairpos( {start}, {middle}, {end} [, {flags} [, {skip}]])
|
||||
searchpairpos( {start}, {middle}, {end} [, {flags} [, {skip} [, {stopline}]]])
|
||||
List search for other end of start/end pair
|
||||
searchpos( {pattern} [, {flags}])
|
||||
searchpos( {pattern} [, {flags} [, {stopline}]])
|
||||
List search for {pattern}
|
||||
server2client( {clientid}, {string})
|
||||
Number send reply string
|
||||
@ -1725,7 +1725,7 @@ add({list}, {expr}) *add()*
|
||||
:let alist = add([1, 2, 3], item)
|
||||
:call add(mylist, "woodstock")
|
||||
< Note that when {expr} is a |List| it is appended as a single
|
||||
item. Use |extend()| to concatenate |List|s.
|
||||
item. Use |extend()| to concatenate |Lists|.
|
||||
Use |insert()| to add an item at another position.
|
||||
|
||||
|
||||
@ -2016,7 +2016,7 @@ copy({expr}) Make a copy of {expr}. For Numbers and Strings this isn't
|
||||
When {expr} is a |List| a shallow copy is created. This means
|
||||
that the original |List| can be changed without changing the
|
||||
copy, and vise versa. But the items are identical, thus
|
||||
changing an item changes the contents of both |List|s. Also
|
||||
changing an item changes the contents of both |Lists|. Also
|
||||
see |deepcopy()|.
|
||||
|
||||
count({comp}, {expr} [, {ic} [, {start}]]) *count()*
|
||||
@ -2327,9 +2327,10 @@ expand({expr} [, {flag}]) *expand()*
|
||||
getting the raw output of an external command.
|
||||
|
||||
extend({expr1}, {expr2} [, {expr3}]) *extend()*
|
||||
{expr1} and {expr2} must be both |List|s or both Dictionaries.
|
||||
{expr1} and {expr2} must be both |Lists| or both
|
||||
|Dictionaries|.
|
||||
|
||||
If they are |List|s: Append {expr2} to {expr1}.
|
||||
If they are |Lists|: Append {expr2} to {expr1}.
|
||||
If {expr3} is given insert the items of {expr2} before item
|
||||
{expr3} in {expr1}. When {expr3} is zero insert before the
|
||||
first item. When {expr3} is equal to len({expr1}) then
|
||||
@ -2341,7 +2342,7 @@ extend({expr1}, {expr2} [, {expr3}]) *extend()*
|
||||
two lists into a new list use the + operator: >
|
||||
:let newlist = [1, 2, 3] + [4, 5]
|
||||
<
|
||||
If they are Dictionaries:
|
||||
If they are |Dictionaries|:
|
||||
Add all entries from {expr2} to {expr1}.
|
||||
If a key exists in both {expr1} and {expr2} then {expr3} is
|
||||
used to decide what to do:
|
||||
@ -2486,7 +2487,7 @@ function({name}) *function()* *E700*
|
||||
|
||||
|
||||
garbagecollect() *garbagecollect()*
|
||||
Cleanup unused |List|s and Dictionaries that have circular
|
||||
Cleanup unused |Lists| and |Dictionaries| that have circular
|
||||
references. There is hardly ever a need to invoke this
|
||||
function, as it is automatically done when Vim runs out of
|
||||
memory or is waiting for the user to press a key after
|
||||
@ -3108,7 +3109,7 @@ insert({list}, {item} [, {idx}]) *insert()*
|
||||
:call insert(mylist, 6, len(mylist))
|
||||
< The last example can be done simpler with |add()|.
|
||||
Note that when {item} is a |List| it is inserted as a single
|
||||
item. Use |extend()| to concatenate |List|s.
|
||||
item. Use |extend()| to concatenate |Lists|.
|
||||
|
||||
isdirectory({directory}) *isdirectory()*
|
||||
The result is a Number, which is non-zero when a directory
|
||||
@ -3143,7 +3144,7 @@ join({list} [, {sep}]) *join()*
|
||||
Note that {sep} is not added at the end. You might want to
|
||||
add it there too: >
|
||||
let lines = join(mylist, "\n") . "\n"
|
||||
< String items are used as-is. |List|s and Dictionaries are
|
||||
< String items are used as-is. |Lists| and |Dictionaries| are
|
||||
converted into a string like with |string()|.
|
||||
The opposite function is |split()|.
|
||||
|
||||
@ -3342,7 +3343,7 @@ mapcheck({name}[, {mode}]) *mapcheck()*
|
||||
match({expr}, {pat}[, {start}[, {count}]]) *match()*
|
||||
When {expr} is a |List| then this returns the index of the
|
||||
first item where {pat} matches. Each item is used as a
|
||||
String, |List|s and Dictionaries are used as echoed.
|
||||
String, |Lists| and |Dictionaries| are used as echoed.
|
||||
Otherwise, {expr} is used as a String. The result is a
|
||||
Number, which gives the index (byte offset) in {expr} where
|
||||
{pat} matches.
|
||||
@ -3807,7 +3808,7 @@ reverse({list}) Reverse the order of items in {list} in-place. Returns
|
||||
If you want a list to remain unmodified make a copy first: >
|
||||
:let revlist = reverse(copy(mylist))
|
||||
|
||||
search({pattern} [, {flags}]) *search()*
|
||||
search({pattern} [, {flags} [, {stopline}]]) *search()*
|
||||
Search for regexp pattern {pattern}. The search starts at the
|
||||
cursor position (you can use |cursor()| to set it).
|
||||
{flags} is a String, which can contain these character flags:
|
||||
@ -3823,11 +3824,20 @@ search({pattern} [, {flags}]) *search()*
|
||||
cursor is moved. The 's' flag cannot be combined with the 'n'
|
||||
flag.
|
||||
|
||||
When the {stopline} argument is given then the search stops
|
||||
after searching this line. This is useful to restrict the
|
||||
search to a range of lines. Examples: >
|
||||
let match = search('(', 'b', line("w0"))
|
||||
let end = search('END', '', line("w$"))
|
||||
< When {stopline} is used and it is not zero this also implies
|
||||
that the search does not wrap around the end of the file.
|
||||
|
||||
When a match has been found its line number is returned.
|
||||
The cursor will be positioned at the match, unless the 'n'
|
||||
flag is used).
|
||||
If there is no match a 0 is returned and the cursor doesn't
|
||||
move. No error message is given.
|
||||
To get the column number too use |searchpos()|.
|
||||
|
||||
Example (goes over all files in the argument list): >
|
||||
:let n = 1
|
||||
@ -3865,7 +3875,7 @@ searchdecl({name} [, {global} [, {thisblock}]]) *searchdecl()*
|
||||
endif
|
||||
<
|
||||
*searchpair()*
|
||||
searchpair({start}, {middle}, {end} [, {flags} [, {skip}]])
|
||||
searchpair({start}, {middle}, {end} [, {flags} [, {skip} [, {stopline}]]])
|
||||
Search for the match of a nested start-end pair. This can be
|
||||
used to find the "endif" that matches an "if", while other
|
||||
if/endif pairs in between are ignored.
|
||||
@ -3900,6 +3910,8 @@ searchpair({start}, {middle}, {end} [, {flags} [, {skip}]])
|
||||
When evaluating {skip} causes an error the search is aborted
|
||||
and -1 returned.
|
||||
|
||||
For {stopline} see |search()|.
|
||||
|
||||
The value of 'ignorecase' is used. 'magic' is ignored, the
|
||||
patterns are used like it's on.
|
||||
|
||||
@ -3944,7 +3956,7 @@ searchpair({start}, {middle}, {end} [, {flags} [, {skip}]])
|
||||
\ 'synIDattr(synID(line("."), col("."), 0), "name") =~? "string"')
|
||||
<
|
||||
*searchpairpos()*
|
||||
searchpairpos({start}, {middle}, {end} [, {flags} [, {skip}]])
|
||||
searchpairpos({start}, {middle}, {end} [, {flags} [, {skip} [, {stopline}]]])
|
||||
Same as searchpair(), but returns a |List| with the line and
|
||||
column position of the match. The first element of the |List|
|
||||
is the line number and the second element is the byte index of
|
||||
@ -3955,8 +3967,8 @@ searchpairpos({start}, {middle}, {end} [, {flags} [, {skip}]])
|
||||
<
|
||||
See |match-parens| for a bigger and more useful example.
|
||||
|
||||
searchpos({pattern} [, {flags}]) *searchpos()*
|
||||
Same as search(), but returns a |List| with the line and
|
||||
searchpos({pattern} [, {flags} [, {stopline}]]) *searchpos()*
|
||||
Same as |search()|, but returns a |List| with the line and
|
||||
column position of the match. The first element of the |List|
|
||||
is the line number and the second element is the byte index of
|
||||
the column position of the match. If no match is found,
|
||||
@ -4143,7 +4155,7 @@ sort({list} [, {func}]) *sort()* *E702*
|
||||
want a list to remain unmodified make a copy first: >
|
||||
:let sortedlist = sort(copy(mylist))
|
||||
< Uses the string representation of each item to sort on.
|
||||
Numbers sort after Strings, |List|s after Numbers.
|
||||
Numbers sort after Strings, |Lists| after Numbers.
|
||||
For sorting text in the current buffer use |:sort|.
|
||||
When {func} is given and it is one then case is ignored.
|
||||
When {func} is a |Funcref| or a function name, this function
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
*options.txt* For Vim version 7.0aa. Last change: 2006 Feb 25
|
||||
*options.txt* For Vim version 7.0aa. Last change: 2006 Feb 26
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -2447,6 +2447,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
When reading a file 'fileencoding' will be set from 'fileencodings'.
|
||||
To read a file in a certain encoding it won't work by setting
|
||||
'fileencoding', use the |++enc| argument.
|
||||
For a new file the global value of 'fileencoding' is used.
|
||||
Prepending "8bit-" and "2byte-" has no meaning here, they are ignored.
|
||||
When the option is set, the value is converted to lowercase. Thus
|
||||
you can set it with uppercase values too. '_' characters are
|
||||
@ -2496,9 +2497,11 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
non-blank characters.
|
||||
When the |++enc| argument is used then the value of 'fileencodings' is
|
||||
not used.
|
||||
Note that 'fileencodings' is not used for a new file, 'fileencoding'
|
||||
is always empty then. This means that a non-existing file may get a
|
||||
different encoding than an empty file.
|
||||
Note that 'fileencodings' is not used for a new file, the global value
|
||||
of 'fileencoding' is used instead. You can set it with: >
|
||||
:setglobal fenc=iso-8859-2
|
||||
< This means that a non-existing file may get a different encoding than
|
||||
an empty file.
|
||||
The special value "ucs-bom" can be used to check for a Unicode BOM
|
||||
(Byte Order Mark) at the start of the file. It must not be preceded
|
||||
by "utf-8" or another Unicode encoding for this to work properly.
|
||||
@ -3317,10 +3320,14 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
'guitablabel' 'gtl' string (default empty)
|
||||
global
|
||||
{not in Vi}
|
||||
{only available when compiled with GUI enabled and
|
||||
with the +windows feature}
|
||||
When nonempty describes the text to use in a label of the GUI tab
|
||||
pages line. When empty Vim will use a default label. See
|
||||
pages line. When empty Vim will use a default label. See
|
||||
|setting-guitablabel| for more info.
|
||||
|
||||
The format of this option is like that of 'statusline'.
|
||||
|
||||
Only used when the GUI tab pages line is displayed. 'e' must be
|
||||
present in 'guioptions'. For the non-GUI tab pages line 'tabline' is
|
||||
used.
|
||||
@ -5089,7 +5096,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
feature}
|
||||
When this option is not empty, it determines the content of the ruler
|
||||
string, as displayed for the 'ruler' option.
|
||||
The format of this option, is like that of 'statusline'.
|
||||
The format of this option is like that of 'statusline'.
|
||||
The default ruler width is 17 characters. To make the ruler 15
|
||||
characters wide, put "%15(" at the start and "%)" at the end.
|
||||
Example: >
|
||||
|
||||
@ -5471,7 +5471,6 @@ hebrew hebrew.txt /*hebrew*
|
||||
hebrew.txt hebrew.txt /*hebrew.txt*
|
||||
help various.txt /*help*
|
||||
help-context help.txt /*help-context*
|
||||
help-tags tags 1
|
||||
help-translated various.txt /*help-translated*
|
||||
help-xterm-window various.txt /*help-xterm-window*
|
||||
help.txt help.txt /*help.txt*
|
||||
|
||||
Reference in New Issue
Block a user