forked from aniani/vim
patch 7.4.2170
Problem: Cannot get information about timers. Solution: Add timer_info().
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
*eval.txt* For Vim version 7.4. Last change: 2016 Aug 02
|
||||
*eval.txt* For Vim version 7.4. Last change: 2016 Aug 06
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -2339,6 +2339,7 @@ test_null_list() List null value for testing
|
||||
test_null_partial() Funcref null value for testing
|
||||
test_null_string() String null value for testing
|
||||
test_settime({expr}) none set current time for testing
|
||||
timer_info([{id}]) List information about timers
|
||||
timer_start({time}, {callback} [, {options}])
|
||||
Number create a timer
|
||||
timer_stop({timer}) none stop a timer
|
||||
@@ -3392,9 +3393,13 @@ exepath({expr}) *exepath()*
|
||||
an empty string is returned.
|
||||
|
||||
*exists()*
|
||||
exists({expr}) The result is a Number, which is |TRUE| if {expr} is
|
||||
defined, zero otherwise. The {expr} argument is a string,
|
||||
which contains one of these:
|
||||
exists({expr}) The result is a Number, which is |TRUE| if {expr} is defined,
|
||||
zero otherwise.
|
||||
|
||||
For checking for a supported feature use |has()|.
|
||||
For checking if a file exists use |filereadable()|.
|
||||
|
||||
The {expr} argument is a string, which contains one of these:
|
||||
&option-name Vim option (only checks if it exists,
|
||||
not if it really works)
|
||||
+option-name Vim option that works.
|
||||
@@ -3442,7 +3447,6 @@ exists({expr}) The result is a Number, which is |TRUE| if {expr} is
|
||||
event and pattern.
|
||||
##event autocommand for this event is
|
||||
supported.
|
||||
For checking for a supported feature use |has()|.
|
||||
|
||||
Examples: >
|
||||
exists("&shortname")
|
||||
@@ -5476,7 +5480,8 @@ matchadd({group}, {pattern}[, {priority}[, {id}[, {dict}]]])
|
||||
available from |getmatches()|. All matches can be deleted in
|
||||
one operation by |clearmatches()|.
|
||||
|
||||
matchaddpos({group}, {pos}[, {priority}[, {id}[, {dict}]]]) *matchaddpos()*
|
||||
*matchaddpos()*
|
||||
matchaddpos({group}, {pos}[, {priority}[, {id}[, {dict}]]])
|
||||
Same as |matchadd()|, but requires a list of positions {pos}
|
||||
instead of a pattern. This command is faster than |matchadd()|
|
||||
because it does not require to handle regular expressions and
|
||||
@@ -7536,6 +7541,23 @@ test_settime({expr}) *test_settime()*
|
||||
{expr} must evaluate to a number. When the value is zero the
|
||||
normal behavior is restored.
|
||||
|
||||
*timer_info()*
|
||||
timer_info([{id}])
|
||||
Return a list with information about timers.
|
||||
When {id} is given only information about this timer is
|
||||
returned. When timer {id} does not exist an empty list is
|
||||
returned.
|
||||
When {id} is omitted information about all timers is returned.
|
||||
|
||||
For each timer the information is stored in a Dictionary with
|
||||
these items:
|
||||
"id" the timer ID
|
||||
"time" time the timer was started with
|
||||
"remaining" time until the timer fires
|
||||
"repeat" number of times the timer will still fire;
|
||||
-1 means forever
|
||||
"callback" the callback
|
||||
|
||||
*timer_start()*
|
||||
timer_start({time}, {callback} [, {options}])
|
||||
Create a timer and return the timer ID.
|
||||
@@ -7566,7 +7588,7 @@ timer_start({time}, {callback} [, {options}])
|
||||
timer_stop({timer}) *timer_stop()*
|
||||
Stop a timer. The timer callback will no longer be invoked.
|
||||
{timer} is an ID returned by timer_start(), thus it must be a
|
||||
Number.
|
||||
Number. If {timer} does not exist there is no error.
|
||||
|
||||
tolower({expr}) *tolower()*
|
||||
The result is a copy of the String given, with all uppercase
|
||||
|
||||
Reference in New Issue
Block a user