mirror of
				https://github.com/neovim/neovim.git
				synced 2025-10-26 12:27:24 +00:00 
			
		
		
		
	| @@ -1214,7 +1214,7 @@ The arguments are optional.  Example: > | ||||
| 							*closure* | ||||
| Lambda expressions can access outer scope variables and arguments.  This is | ||||
| often called a closure.  Example where "i" a and "a:arg" are used in a lambda | ||||
| while they exists in the function scope.  They remain valid even after the | ||||
| while they exist in the function scope.  They remain valid even after the | ||||
| function returns: > | ||||
| 	:function Foo(arg) | ||||
| 	:  let i = 3 | ||||
| @@ -1991,7 +1991,7 @@ cos({expr})			Float	cosine of {expr} | ||||
| cosh({expr})			Float	hyperbolic cosine of {expr} | ||||
| count({list}, {expr} [, {ic} [, {start}]]) | ||||
| 				Number	 count how many {expr} are in {list} | ||||
| cscope_connection([{num} , {dbpath} [, {prepend}]]) | ||||
| cscope_connection([{num}, {dbpath} [, {prepend}]]) | ||||
| 				Number	checks existence of cscope connection | ||||
| cursor({lnum}, {col} [, {off}]) | ||||
| 				Number	move cursor to {lnum}, {col}, {off} | ||||
| @@ -4278,7 +4278,7 @@ getreg([{regname} [, 1 [, {list}]]])			*getreg()* | ||||
| 		The result is a String, which is the contents of register | ||||
| 		{regname}.  Example: > | ||||
| 			:let cliptext = getreg('*') | ||||
| <		When {regname} was not set the result is a empty string. | ||||
| <		When {regname} was not set the result is an empty string. | ||||
|  | ||||
| 		getreg('=') returns the last evaluated value of the expression | ||||
| 		register.  (For use in maps.) | ||||
| @@ -4317,7 +4317,7 @@ gettabinfo([{arg}])					*gettabinfo()* | ||||
| 			nr		tab page number. | ||||
| 			variables	a reference to the dictionary with | ||||
| 					tabpage-local variables | ||||
| 			windows		List of window IDs in the tag page. | ||||
| 			windows		List of window IDs in the tab page. | ||||
|  | ||||
| gettabvar({tabnr}, {varname} [, {def}])				*gettabvar()* | ||||
| 		Get the value of a tab-local variable {varname} in tab page | ||||
| @@ -7404,7 +7404,7 @@ systemlist({cmd} [, {input} [, {keepempty}]])		*systemlist()* | ||||
| tabpagebuflist([{arg}])					*tabpagebuflist()* | ||||
| 		The result is a |List|, where each item is the number of the | ||||
| 		buffer associated with each window in the current tab page. | ||||
| 		{arg} specifies the number of tab page to be used.  When | ||||
| 		{arg} specifies the number of the tab page to be used. When | ||||
| 		omitted the current tab page is used. | ||||
| 		When {arg} is invalid the number zero is returned. | ||||
| 		To get a list of all buffers in all tabs use this: > | ||||
| @@ -7553,9 +7553,9 @@ timer_info([{id}]) | ||||
|  | ||||
| timer_pause({timer}, {paused})				*timer_pause()* | ||||
| 		Pause or unpause a timer.  A paused timer does not invoke its | ||||
| 		callback, while the time it would is not changed.  Unpausing a | ||||
| 		timer may cause the callback to be invoked almost immediately | ||||
| 		if enough time has passed. | ||||
| 		callback when its time expires.  Unpausing a timer may cause | ||||
| 		the callback to be invoked almost immediately if enough time | ||||
| 		has passed. | ||||
|  | ||||
| 		Pausing a timer is useful to avoid the callback to be called | ||||
| 		for a short time. | ||||
| @@ -7564,7 +7564,7 @@ timer_pause({timer}, {paused})				*timer_pause()* | ||||
| 		String, then the timer is paused, otherwise it is unpaused. | ||||
| 		See |non-zero-arg|. | ||||
|  | ||||
| 							*timer_start()* | ||||
| 						*timer_start()* *timer* *timers* | ||||
| timer_start({time}, {callback} [, {options}]) | ||||
| 		Create a timer and return the timer ID. | ||||
|  | ||||
|   | ||||
| @@ -1202,7 +1202,7 @@ tag	      command	      action ~ | ||||
| |:display|	:di[splay]	display registers | ||||
| |:djump|	:dj[ump]	jump to #define | ||||
| |:dl|		:dl		short for |:delete| with the 'l' flag | ||||
| |:dl|		:del[ete]l	short for |:delete| with the 'l' flag | ||||
| |:del|		:del[ete]l	short for |:delete| with the 'l' flag | ||||
| |:dlist|	:dli[st]	list #defines | ||||
| |:doautocmd|	:do[autocmd]	apply autocommands to current buffer | ||||
| |:doautoall|	:doautoa[ll]	apply autocommands for all loaded buffers | ||||
|   | ||||
| @@ -3499,7 +3499,7 @@ A jump table for the options with a short description can be found at |Q_op|. | ||||
| 	if you want to use Vim as a modeless editor. | ||||
| 	These Insert mode commands will be useful: | ||||
| 	- Use the cursor keys to move around. | ||||
| 	- Use CTRL-O to execute one Normal mode command |i_CTRL-O|).  When | ||||
| 	- Use CTRL-O to execute one Normal mode command |i_CTRL-O|.  When | ||||
| 	  this is a mapping, it is executed as if 'insertmode' was off. | ||||
| 	  Normal mode remains active until the mapping is finished. | ||||
| 	- Use CTRL-L to execute a number of Normal mode commands, then use | ||||
|   | ||||
| @@ -3739,7 +3739,7 @@ Whether or not it is actually concealed depends on the value of the | ||||
| 'conceallevel' option.  The 'concealcursor' option is used to decide whether | ||||
| concealable items in the current line are displayed unconcealed to be able to | ||||
| edit the line. | ||||
| Another way to conceal text with with |matchadd()|. | ||||
| Another way to conceal text is with |matchadd()|. | ||||
|  | ||||
| concealends						*:syn-concealends* | ||||
|  | ||||
|   | ||||
| @@ -60,7 +60,7 @@ Support for different systems. | ||||
| 	- Windows (XP SP 2 or greater) | ||||
| 	- OS X | ||||
|  | ||||
| Multi level undo.					|undo| | ||||
| Multi level persistent undo.					|undo| | ||||
| 	'u' goes backward in time, 'CTRL-R' goes forward again.  Set option | ||||
| 	'undolevels' to the number of changes to be remembered (default 1000). | ||||
| 	Set 'undolevels' to 0 for a Vi-compatible one level undo.  Set it to | ||||
| @@ -71,6 +71,9 @@ Multi level undo.					|undo| | ||||
| 	create a branch in the undo tree.  This means you can go back to any | ||||
| 	state of the text, there is no risk of a change causing text to be | ||||
| 	lost forever. |undo-tree| | ||||
| 	The undo information is stored in a file when the 'undofile' option is | ||||
| 	set.  This means you can exit Vim, start Vim on a previously edited | ||||
| 	file and undo changes that were made before exiting Vim. | ||||
|  | ||||
| Graphical User Interface (GUI).				|gui| | ||||
| 	Included support for GUI: menu's, mouse, scrollbars, etc.  You can | ||||
| @@ -124,6 +127,13 @@ Plugins.						|add-plugin| | ||||
| 	right directory.  That's an easy way to start using Vim scripts | ||||
| 	written by others.  Plugins can be for all kind of files, or | ||||
| 	specifically for a filetype. | ||||
| 	Packages make this even easier. |packages| | ||||
|  | ||||
| Asynchronous communication and timers.			|job-control| |timer| | ||||
| 	Vim can exchange messages with other processes in the background. | ||||
| 	Vim can start a job, communicate with it and stop it. |job-control| | ||||
| 	Timers can fire once or repeatedly and invoke a function to do any | ||||
| 	work. |timer| | ||||
|  | ||||
| Repeat a series of commands.				|q| | ||||
| 	"q{c}" starts recording typed characters into named register {c}. | ||||
|   | ||||
| @@ -37,7 +37,7 @@ function s:FindPrevLessIndentedLine(lnum, ...) | ||||
|     let curindent = a:0 ? a:1 : indent(a:lnum) | ||||
|     while           prevlnum | ||||
|                 \&&  indent(prevlnum) >=  curindent | ||||
|                 \&& getline(prevlnum) !~# '^\s*#' | ||||
|                 \&& getline(prevlnum) =~# '^\s*#' | ||||
|         let prevlnum = prevnonblank(prevlnum-1) | ||||
|     endwhile | ||||
|     return prevlnum | ||||
| @@ -51,11 +51,33 @@ function s:FindPrevLEIndentedLineMatchingRegex(lnum, regex) | ||||
|     return plilnum | ||||
| endfunction | ||||
|  | ||||
| let s:mapkeyregex='\v^\s*%(\''%([^'']|'''')*\'''. | ||||
|                 \        '|\"%([^"\\]|\\.)*\"'. | ||||
|                 \        '|%(%(\:\ )@!.)*)\:%(\ |$)' | ||||
| let s:mapkeyregex='\v^\s*\#@!\S@=%(\''%([^'']|\''\'')*\'''. | ||||
|                 \                 '|\"%([^"\\]|\\.)*\"'. | ||||
|                 \                 '|%(%(\:\ )@!.)*)\:%(\ |$)' | ||||
| let s:liststartregex='\v^\s*%(\-%(\ |$))' | ||||
|  | ||||
| let s:c_ns_anchor_char = '\v%([\n\r\uFEFF \t,[\]{}]@!\p)' | ||||
| let s:c_ns_anchor_name = s:c_ns_anchor_char.'+' | ||||
| let s:c_ns_anchor_property =  '\v\&'.s:c_ns_anchor_name | ||||
|  | ||||
| let s:ns_word_char = '\v[[:alnum:]_\-]' | ||||
| let s:ns_tag_char  = '\v%(%\x\x|'.s:ns_word_char.'|[#/;?:@&=+$.~*''()])' | ||||
| let s:c_named_tag_handle     = '\v\!'.s:ns_word_char.'+\!' | ||||
| let s:c_secondary_tag_handle = '\v\!\!' | ||||
| let s:c_primary_tag_handle   = '\v\!' | ||||
| let s:c_tag_handle = '\v%('.s:c_named_tag_handle. | ||||
|             \            '|'.s:c_secondary_tag_handle. | ||||
|             \            '|'.s:c_primary_tag_handle.')' | ||||
| let s:c_ns_shorthand_tag = '\v'.s:c_tag_handle . s:ns_tag_char.'+' | ||||
| let s:c_non_specific_tag = '\v\!' | ||||
| let s:ns_uri_char  = '\v%(%\x\x|'.s:ns_word_char.'\v|[#/;?:@&=+$,.!~*''()[\]])' | ||||
| let s:c_verbatim_tag = '\v\!\<'.s:ns_uri_char.'+\>' | ||||
| let s:c_ns_tag_property = '\v'.s:c_verbatim_tag. | ||||
|             \               '\v|'.s:c_ns_shorthand_tag. | ||||
|             \               '\v|'.s:c_non_specific_tag | ||||
|  | ||||
| let s:block_scalar_header = '\v[|>]%([+-]?[1-9]|[1-9]?[+-])?' | ||||
|  | ||||
| function GetYAMLIndent(lnum) | ||||
|     if a:lnum == 1 || !prevnonblank(a:lnum-1) | ||||
|         return 0 | ||||
| @@ -127,7 +149,10 @@ function GetYAMLIndent(lnum) | ||||
|         " - List with | ||||
|         "   multiline scalar | ||||
|         return previndent+2 | ||||
|     elseif prevline =~# s:mapkeyregex | ||||
|     elseif prevline =~# s:mapkeyregex . '\v\s*%(%('.s:c_ns_tag_property. | ||||
|                 \                              '\v|'.s:c_ns_anchor_property. | ||||
|                 \                              '\v|'.s:block_scalar_header. | ||||
|                 \                             '\v)%(\s+|\s*%(\#.*)?$))*' | ||||
|         " Mapping with: value | ||||
|         "     that is multiline scalar | ||||
|         return previndent+s:shiftwidth() | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Justin M. Keyes
					Justin M. Keyes