forked from aniani/vim
Update runtime files.
This commit is contained in:
parent
2d54ec92d4
commit
822ff866bd
@ -3,7 +3,7 @@
|
||||
" Maintainer: Dávid Szabó ( complex857 AT gmail DOT com )
|
||||
" Previous Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl )
|
||||
" URL: https://github.com/shawncplus/phpcomplete.vim
|
||||
" Last Change: 2014 May 08
|
||||
" Last Change: 2014 May 30
|
||||
"
|
||||
" OPTIONS:
|
||||
"
|
||||
@ -109,13 +109,12 @@ function! phpcomplete#CompletePHP(findstart, base) " {{{
|
||||
" locate the start of the word
|
||||
let line = getline('.')
|
||||
let start = col('.') - 1
|
||||
let curline = line('.')
|
||||
let compl_begin = col('.') - 2
|
||||
while start >= 0 && line[start - 1] =~ '[\\a-zA-Z_0-9\x7f-\xff$]'
|
||||
let start -= 1
|
||||
endwhile
|
||||
let b:phpbegin = phpbegin
|
||||
let b:compl_context = phpcomplete#GetCurrentInstruction(line('.'), col('.') - 2, phpbegin)
|
||||
let b:compl_context = phpcomplete#GetCurrentInstruction(line('.'), max([0, col('.') - 2]), phpbegin)
|
||||
|
||||
return start
|
||||
" We can be also inside of phpString with HTML tags. Deal with
|
||||
@ -265,11 +264,11 @@ function! phpcomplete#CompleteUse(base) " {{{
|
||||
if base !~ '\'
|
||||
let builtin_classnames = filter(keys(copy(g:php_builtin_classnames)), 'v:val =~? "^'.classname_match_pattern.'"')
|
||||
for classname in builtin_classnames
|
||||
call add(res, {'word': classname, 'kind': 'c'})
|
||||
call add(res, {'word': g:php_builtin_classes[tolower(classname)].name, 'kind': 'c'})
|
||||
endfor
|
||||
let builtin_interfacenames = filter(keys(copy(g:php_builtin_interfacenames)), 'v:val =~? "^'.classname_match_pattern.'"')
|
||||
for interfacename in builtin_interfacenames
|
||||
call add(res, {'word': interfacename, 'kind': 'i'})
|
||||
call add(res, {'word': g:php_builtin_interfaces[tolower(interfacename)].name, 'kind': 'i'})
|
||||
endfor
|
||||
endif
|
||||
|
||||
@ -459,7 +458,7 @@ function! phpcomplete#CompleteGeneral(base, current_namespace, imports) " {{{
|
||||
" Add builtin class names
|
||||
for [classname, info] in items(g:php_builtin_classnames)
|
||||
if classname =~? '^'.base
|
||||
let builtin_classnames[leading_slash.classname] = info
|
||||
let builtin_classnames[leading_slash.g:php_builtin_classes[tolower(classname)].name] = info
|
||||
endif
|
||||
endfor
|
||||
for [interfacename, info] in items(g:php_builtin_interfacenames)
|
||||
@ -832,7 +831,7 @@ function! phpcomplete#CompleteClassName(base, kinds, current_namespace, imports)
|
||||
if has_key(g:php_builtin_classes[tolower(classname)].methods, '__construct')
|
||||
let menu = g:php_builtin_classes[tolower(classname)]['methods']['__construct']['signature']
|
||||
endif
|
||||
call add(res, {'word': leading_slash.classname, 'kind': 'c', 'menu': menu})
|
||||
call add(res, {'word': leading_slash.g:php_builtin_classes[tolower(classname)].name, 'kind': 'c', 'menu': menu})
|
||||
endfor
|
||||
endif
|
||||
|
||||
@ -926,10 +925,10 @@ function! phpcomplete#CompleteUserClass(context, base, sccontent, visibility) "
|
||||
\ 'function\s*&\?\zs[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\ze')
|
||||
let f_args = matchstr(i,
|
||||
\ 'function\s*&\?[a-zA-Z_\x7f-\xff][a-zA-Z_0-9\x7f-\xff]*\s*(\zs.\{-}\ze)\_s*\({\|\_$\)')
|
||||
if f_name != ''
|
||||
if f_name != '' && stridx(f_name, '__') != 0
|
||||
let c_functions[f_name.'('] = f_args
|
||||
if g:phpcomplete_parse_docblock_comments
|
||||
let c_doc[f_name.'('] = phpcomplete#GetDocBlock(a:sccontent, 'function\s*\<'.f_name.'\>')
|
||||
let c_doc[f_name.'('] = phpcomplete#GetDocBlock(a:sccontent, 'function\s*&\?\<'.f_name.'\>')
|
||||
endif
|
||||
endif
|
||||
endfor
|
||||
@ -1049,7 +1048,7 @@ function! phpcomplete#CompleteBuiltInClass(context, classname, base) " {{{
|
||||
if a:context =~ '->$' " complete for everything instance related
|
||||
" methods
|
||||
for [method_name, method_info] in items(class_info.methods)
|
||||
if a:base == '' || method_name =~? '^'.a:base
|
||||
if stridx(method_name, '__') != 0 && (a:base == '' || method_name =~? '^'.a:base)
|
||||
call add(res, {'word':method_name.'(', 'kind': 'f', 'menu': method_info.signature, 'info': method_info.signature })
|
||||
endif
|
||||
endfor
|
||||
@ -1317,7 +1316,7 @@ function! phpcomplete#GetCallChainReturnType(classname_candidate, class_candidat
|
||||
|
||||
return unknown_result
|
||||
|
||||
elseif filereadable(classlocation)
|
||||
elseif classlocation != '' && filereadable(classlocation)
|
||||
" Read the next method from the stack and extract only the name
|
||||
|
||||
let classcontents = phpcomplete#GetCachedClassContents(classlocation, classname_candidate)
|
||||
@ -1325,7 +1324,7 @@ function! phpcomplete#GetCallChainReturnType(classname_candidate, class_candidat
|
||||
" Get Structured information of all classes and subclasses including namespace and includes
|
||||
" try to find the method's return type in docblock comment
|
||||
for classstructure in classcontents
|
||||
let doclock_target_pattern = 'function\s\+'.method.'\|\(public\|private\|protected\|var\).\+\$'.method
|
||||
let doclock_target_pattern = 'function\s\+&\?'.method.'\|\(public\|private\|protected\|var\).\+\$'.method
|
||||
let doc_str = phpcomplete#GetDocBlock(split(classstructure.content, '\n'), doclock_target_pattern)
|
||||
if doc_str != ''
|
||||
break
|
||||
@ -1357,7 +1356,14 @@ function! phpcomplete#GetCallChainReturnType(classname_candidate, class_candidat
|
||||
else
|
||||
let fullnamespace = class_candidate_namespace
|
||||
endif
|
||||
let [classname_candidate, class_candidate_namespace] = phpcomplete#ExpandClassName(returnclass, fullnamespace, a:imports)
|
||||
" make @return self, static, $this the same way
|
||||
" (not exactly what php means by these)
|
||||
if returnclass == 'self' || returnclass == 'static' || returnclass == '$this'
|
||||
let classname_candidate = a:classname_candidate
|
||||
let class_candidate_namespace = a:class_candidate_namespace
|
||||
else
|
||||
let [classname_candidate, class_candidate_namespace] = phpcomplete#ExpandClassName(returnclass, fullnamespace, a:imports)
|
||||
endif
|
||||
endif
|
||||
|
||||
return phpcomplete#GetCallChainReturnType(classname_candidate, class_candidate_namespace, a:imports, methodstack)
|
||||
@ -1496,9 +1502,9 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
|
||||
let return_type = matchstr(g:php_builtin_functions[function_name.'('], '\v\|\s+\zs.+$')
|
||||
let classname_candidate = return_type
|
||||
let class_candidate_namespace = '\'
|
||||
else
|
||||
elseif function_file != '' && filereadable(function_file)
|
||||
let file_lines = readfile(function_file)
|
||||
let docblock_str = phpcomplete#GetDocBlock(file_lines, 'function\s*\<'.function_name.'\>')
|
||||
let docblock_str = phpcomplete#GetDocBlock(file_lines, 'function\s*&\?\<'.function_name.'\>')
|
||||
let docblock = phpcomplete#ParseDocBlock(docblock_str)
|
||||
if has_key(docblock.return, 'type')
|
||||
let classname_candidate = docblock.return.type
|
||||
@ -1514,32 +1520,35 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
|
||||
return (class_candidate_namespace == '\' || class_candidate_namespace == '') ? classname_candidate : class_candidate_namespace.'\'.classname_candidate
|
||||
endif
|
||||
else
|
||||
" extract the variable name from the context
|
||||
let object = methodstack[0]
|
||||
let object_is_array = (object =~ '\v^[^[]+\[' ? 1 : 0)
|
||||
let object = matchstr(object, variable_name_pattern)
|
||||
|
||||
" check Constant lookup
|
||||
let constant_object = matchstr(a:context, '\zs'.class_name_pattern.'\ze::')
|
||||
if constant_object != ''
|
||||
let classname_candidate = constant_object
|
||||
endif
|
||||
|
||||
" extract the variable name from the context
|
||||
let object = methodstack[0]
|
||||
let object_is_array = (object =~ '\v^[^[]+\[' ? 1 : 0)
|
||||
let object = matchstr(object, variable_name_pattern)
|
||||
|
||||
" scan the file backwards from current line for explicit type declaration (@var $variable Classname)
|
||||
let i = 1 " start from the current line - 1
|
||||
while i < a:start_line
|
||||
let line = getline(a:start_line - i)
|
||||
" in file lookup for /* @var $foo Class */
|
||||
if line =~# '@var\s\+'.object.'\s\+'.class_name_pattern
|
||||
let classname_candidate = matchstr(line, '@var\s\+'.object.'\s\+\zs'.class_name_pattern.'\(\[\]\)\?')
|
||||
break
|
||||
elseif line !~ '^\s*$'
|
||||
" type indicator comments should be next to the variable
|
||||
" non empty lines break the search
|
||||
break
|
||||
endif
|
||||
let i += 1
|
||||
endwhile
|
||||
if classname_candidate == ''
|
||||
" scan the file backwards from current line for explicit type declaration (@var $variable Classname)
|
||||
let i = 1 " start from the current line - 1
|
||||
while i < a:start_line
|
||||
let line = getline(a:start_line - i)
|
||||
" in file lookup for /* @var $foo Class */
|
||||
if line =~# '@var\s\+'.object.'\s\+'.class_name_pattern
|
||||
let classname_candidate = matchstr(line, '@var\s\+'.object.'\s\+\zs'.class_name_pattern.'\(\[\]\)\?')
|
||||
let [classname_candidate, class_candidate_namespace] = phpcomplete#ExpandClassName(classname_candidate, a:current_namespace, a:imports)
|
||||
break
|
||||
elseif line !~ '^\s*$'
|
||||
" type indicator comments should be next to the variable
|
||||
" non empty lines break the search
|
||||
break
|
||||
endif
|
||||
let i += 1
|
||||
endwhile
|
||||
endif
|
||||
|
||||
if classname_candidate != ''
|
||||
let [classname_candidate, class_candidate_namespace] = phpcomplete#GetCallChainReturnType(classname_candidate, class_candidate_namespace, class_candidate_imports, methodstack)
|
||||
@ -1549,7 +1558,7 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
|
||||
|
||||
" scan the file backwards from the current line
|
||||
let i = 1
|
||||
while i < a:start_line
|
||||
while i < a:start_line " {{{
|
||||
let line = getline(a:start_line - i)
|
||||
|
||||
" do in-file lookup of $var = new Class
|
||||
@ -1661,9 +1670,9 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
|
||||
let classname_candidate = return_type
|
||||
let class_candidate_namespace = '\'
|
||||
break
|
||||
else
|
||||
elseif function_file != '' && filereadable(function_file)
|
||||
let file_lines = readfile(function_file)
|
||||
let docblock_str = phpcomplete#GetDocBlock(file_lines, 'function\s*\<'.function_name.'\>')
|
||||
let docblock_str = phpcomplete#GetDocBlock(file_lines, 'function\s*&\?\<'.function_name.'\>')
|
||||
let docblock = phpcomplete#ParseDocBlock(docblock_str)
|
||||
if has_key(docblock.return, 'type')
|
||||
let classname_candidate = docblock.return.type
|
||||
@ -1713,7 +1722,7 @@ function! phpcomplete#GetClassName(start_line, context, current_namespace, impor
|
||||
endif
|
||||
|
||||
let i += 1
|
||||
endwhile
|
||||
endwhile " }}}
|
||||
|
||||
if classname_candidate != ''
|
||||
let [classname_candidate, class_candidate_namespace] = phpcomplete#GetCallChainReturnType(classname_candidate, class_candidate_namespace, class_candidate_imports, methodstack)
|
||||
@ -1784,6 +1793,7 @@ function! phpcomplete#GetClassLocation(classname, namespace) " {{{
|
||||
return no_namespace_candidate
|
||||
endif
|
||||
|
||||
return ''
|
||||
endfunction
|
||||
" }}}
|
||||
|
||||
@ -1794,11 +1804,12 @@ function! phpcomplete#GetFunctionLocation(function_name, namespace) " {{{
|
||||
return 'VIMPHP_BUILTINFUNCTION'
|
||||
endif
|
||||
|
||||
|
||||
" do in-file lookup for function definition
|
||||
let i = 1
|
||||
let buffer_lines = getline(1, line('$'))
|
||||
for line in buffer_lines
|
||||
if line =~? '^\s*function\s\+'.a:function_name.'\s*('
|
||||
if line =~? '^\s*function\s\+&\?'.a:function_name.'\s*('
|
||||
return expand('%:p')
|
||||
endif
|
||||
endfor
|
||||
@ -1826,6 +1837,8 @@ function! phpcomplete#GetFunctionLocation(function_name, namespace) " {{{
|
||||
if no_namespace_candidate != ''
|
||||
return no_namespace_candidate
|
||||
endif
|
||||
|
||||
return ''
|
||||
endfunction
|
||||
" }}}
|
||||
|
||||
@ -1916,7 +1929,7 @@ function! phpcomplete#GetClassContentsStructure(file_path, file_lines, class_nam
|
||||
|
||||
silent! below 1new
|
||||
silent! 0put =cfile
|
||||
call search('\(class\|interface\)\s\+'.a:class_name.'\(\>\|$\)')
|
||||
call search('\(class\|interface\)\_s\+'.a:class_name.'\(\>\|$\)')
|
||||
let cfline = line('.')
|
||||
call search('{')
|
||||
let endline = line('.')
|
||||
@ -1949,7 +1962,7 @@ function! phpcomplete#GetClassContentsStructure(file_path, file_lines, class_nam
|
||||
let namespace = '\'
|
||||
endif
|
||||
let classlocation = phpcomplete#GetClassLocation(extends_class, namespace)
|
||||
if filereadable(classlocation)
|
||||
if classlocation != '' && filereadable(classlocation)
|
||||
let full_file_path = fnamemodify(classlocation, ':p')
|
||||
let result += phpcomplete#GetClassContentsStructure(full_file_path, readfile(full_file_path), extends_class)
|
||||
elseif tolower(current_namespace) == tolower(namespace)
|
||||
@ -2266,7 +2279,7 @@ function! phpcomplete#GetCurrentNameSpace(file_lines) " {{{
|
||||
if has_key(g:php_builtin_classnames, tolower(import.name))
|
||||
let import['kind'] = 'c'
|
||||
let import['builtin'] = 1
|
||||
elseif has_key(g:php_builtin_interfaces, import.name)
|
||||
elseif has_key(g:php_builtin_interfacenames, tolower(import.name))
|
||||
let import['kind'] = 'i'
|
||||
let import['builtin'] = 1
|
||||
else
|
||||
@ -2494,7 +2507,7 @@ for [classname, class_info] in items(g:php_builtin_classes)
|
||||
endif
|
||||
endfor
|
||||
|
||||
let g:php_builtin_classnames[class_info.name] = ''
|
||||
let g:php_builtin_classnames[classname] = ''
|
||||
for [method_name, method_info] in items(class_info.methods)
|
||||
let g:php_builtin_object_functions[classname.'::'.method_name.'('] = method_info.signature
|
||||
endfor
|
||||
@ -2513,10 +2526,10 @@ for [interfacename, info] in items(g:php_builtin_interfaces)
|
||||
|
||||
let g:php_builtin_interfacenames[interfacename] = ''
|
||||
for [method_name, method_info] in items(class_info.methods)
|
||||
let g:php_builtin_object_functions[classname.'::'.method_name.'('] = method_info.signature
|
||||
let g:php_builtin_object_functions[interfacename.'::'.method_name.'('] = method_info.signature
|
||||
endfor
|
||||
for [method_name, method_info] in items(class_info.static_methods)
|
||||
let g:php_builtin_object_functions[classname.'::'.method_name.'('] = method_info.signature
|
||||
let g:php_builtin_object_functions[interfacename.'::'.method_name.'('] = method_info.signature
|
||||
endfor
|
||||
endfor
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
*eval.txt* For Vim version 7.4. Last change: 2014 May 07
|
||||
*eval.txt* For Vim version 7.4. Last change: 2014 Jun 12
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -3260,6 +3260,10 @@ getchar([expr]) *getchar()*
|
||||
String when a modifier (shift, control, alt) was used that is
|
||||
not included in the character.
|
||||
|
||||
When [expr] is 0 and Esc is typed, there will be a short delay
|
||||
while Vim waits to see if this is the start of an escape
|
||||
sequence.
|
||||
|
||||
When [expr] is 1 only the first byte is returned. For a
|
||||
one-byte character it is the character itself as a number.
|
||||
Use nr2char() to convert it to a String.
|
||||
@ -3475,6 +3479,34 @@ getmatches() *getmatches()*
|
||||
'pattern': 'FIXME', 'priority': 10, 'id': 2}] >
|
||||
:unlet m
|
||||
<
|
||||
*getpid()*
|
||||
getpid() Return a Number which is the process ID of the Vim process.
|
||||
On Unix and MS-Windows this is a unique number, until Vim
|
||||
exits. On MS-DOS it's always zero.
|
||||
|
||||
*getpos()*
|
||||
getpos({expr}) Get the position for {expr}. For possible values of {expr}
|
||||
see |line()|. For getting the cursor position see
|
||||
|getcurpos()|.
|
||||
The result is a |List| with four numbers:
|
||||
[bufnum, lnum, col, off]
|
||||
"bufnum" is zero, unless a mark like '0 or 'A is used, then it
|
||||
is the buffer number of the mark.
|
||||
"lnum" and "col" are the position in the buffer. The first
|
||||
column is 1.
|
||||
The "off" number is zero, unless 'virtualedit' is used. Then
|
||||
it is the offset in screen columns from the start of the
|
||||
character. E.g., a position within a <Tab> or after the last
|
||||
character.
|
||||
Note that for '< and '> Visual mode matters: when it is "V"
|
||||
(visual line mode) the column of '< is zero and the column of
|
||||
'> is a large number.
|
||||
This can be used to save and restore the position of a mark: >
|
||||
let save_a_mark = getpos("'a")
|
||||
...
|
||||
call setpos(''a', save_a_mark
|
||||
< Also see |getcurpos()| and |setpos()|.
|
||||
|
||||
|
||||
getqflist() *getqflist()*
|
||||
Returns a list with all the current quickfix errors. Each
|
||||
@ -4506,34 +4538,6 @@ nr2char({expr}[, {utf8}]) *nr2char()*
|
||||
characters. nr2char(0) is a real NUL and terminates the
|
||||
string, thus results in an empty string.
|
||||
|
||||
*getpid()*
|
||||
getpid() Return a Number which is the process ID of the Vim process.
|
||||
On Unix and MS-Windows this is a unique number, until Vim
|
||||
exits. On MS-DOS it's always zero.
|
||||
|
||||
*getpos()*
|
||||
getpos({expr}) Get the position for {expr}. For possible values of {expr}
|
||||
see |line()|. For getting the cursor position see
|
||||
|getcurpos()|.
|
||||
The result is a |List| with four numbers:
|
||||
[bufnum, lnum, col, off]
|
||||
"bufnum" is zero, unless a mark like '0 or 'A is used, then it
|
||||
is the buffer number of the mark.
|
||||
"lnum" and "col" are the position in the buffer. The first
|
||||
column is 1.
|
||||
The "off" number is zero, unless 'virtualedit' is used. Then
|
||||
it is the offset in screen columns from the start of the
|
||||
character. E.g., a position within a <Tab> or after the last
|
||||
character.
|
||||
Note that for '< and '> Visual mode matters: when it is "V"
|
||||
(visual line mode) the column of '< is zero and the column of
|
||||
'> is a large number.
|
||||
This can be used to save and restore the position of a mark: >
|
||||
let save_a_mark = getpos("'a")
|
||||
...
|
||||
call setpos(''a', save_a_mark
|
||||
< Also see |getcurpos()| and |setpos()|.
|
||||
|
||||
or({expr}, {expr}) *or()*
|
||||
Bitwise OR on the two arguments. The arguments are converted
|
||||
to a number. A List, Dict or Float argument causes an error.
|
||||
@ -5587,6 +5591,7 @@ sort({list} [, {func} [, {dict}]]) *sort()* *E702*
|
||||
|
||||
If you 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, |Lists| after Numbers.
|
||||
For sorting text in the current buffer use |:sort|.
|
||||
|
@ -1,4 +1,4 @@
|
||||
*intro.txt* For Vim version 7.4. Last change: 2013 Jun 17
|
||||
*intro.txt* For Vim version 7.4. Last change: 2014 May 24
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -136,9 +136,10 @@ http://www.vim.org/maillist.php
|
||||
Bug reports: *bugs* *bug-reports* *bugreport.vim*
|
||||
|
||||
Send bug reports to: Vim Developers <vim_dev@vim.org>
|
||||
This is a maillist, many people will see the message. If you don't want that,
|
||||
e.g. because it is a security issue, send it to <bugs@vim.org>, this only goes
|
||||
to the Vim maintainer (that's Bram).
|
||||
This is a maillist, you need to become a member first and many people will see
|
||||
the message. If you don't want that, e.g. because it is a security issue,
|
||||
send it to <bugs@vim.org>, this only goes to the Vim maintainer (that's Bram).
|
||||
|
||||
Please be brief; all the time that is spent on answering mail is subtracted
|
||||
from the time that is spent on improving Vim! Always give a reproducible
|
||||
example and try to find out which settings or other things influence the
|
||||
|
@ -1,4 +1,4 @@
|
||||
*map.txt* For Vim version 7.4. Last change: 2014 May 10
|
||||
*map.txt* For Vim version 7.4. Last change: 2014 Jun 02
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -60,17 +60,17 @@ modes.
|
||||
{rhs}, is then further scanned for mappings. This
|
||||
allows for nested and recursive use of mappings.
|
||||
|
||||
|
||||
:no[remap] {lhs} {rhs} |mapmode-nvo| *:no* *:noremap*
|
||||
:nn[oremap] {lhs} {rhs} |mapmode-n| *:nn* *:nnoremap*
|
||||
:vn[oremap] {lhs} {rhs} |mapmode-v| *:vn* *:vnoremap*
|
||||
:xn[oremap] {lhs} {rhs} |mapmode-x| *:xn* *:xnoremap*
|
||||
:snor[emap] {lhs} {rhs} |mapmode-s| *:snor* *:snoremap*
|
||||
:ono[remap] {lhs} {rhs} |mapmode-o| *:ono* *:onoremap*
|
||||
:no[remap]! {lhs} {rhs} |mapmode-ic| *:no!* *:noremap!*
|
||||
:ino[remap] {lhs} {rhs} |mapmode-i| *:ino* *:inoremap*
|
||||
:ln[oremap] {lhs} {rhs} |mapmode-l| *:ln* *:lnoremap*
|
||||
:cno[remap] {lhs} {rhs} |mapmode-c| *:cno* *:cnoremap*
|
||||
*:nore* *:norem*
|
||||
:no[remap] {lhs} {rhs} |mapmode-nvo| *:no* *:noremap* *:nor*
|
||||
:nn[oremap] {lhs} {rhs} |mapmode-n| *:nn* *:nnoremap*
|
||||
:vn[oremap] {lhs} {rhs} |mapmode-v| *:vn* *:vnoremap*
|
||||
:xn[oremap] {lhs} {rhs} |mapmode-x| *:xn* *:xnoremap*
|
||||
:snor[emap] {lhs} {rhs} |mapmode-s| *:snor* *:snoremap*
|
||||
:ono[remap] {lhs} {rhs} |mapmode-o| *:ono* *:onoremap*
|
||||
:no[remap]! {lhs} {rhs} |mapmode-ic| *:no!* *:noremap!*
|
||||
:ino[remap] {lhs} {rhs} |mapmode-i| *:ino* *:inoremap*
|
||||
:ln[oremap] {lhs} {rhs} |mapmode-l| *:ln* *:lnoremap*
|
||||
:cno[remap] {lhs} {rhs} |mapmode-c| *:cno* *:cnoremap*
|
||||
Map the key sequence {lhs} to {rhs} for the modes
|
||||
where the map command applies. Disallow mapping of
|
||||
{rhs}, to avoid nested and recursive mappings. Often
|
||||
@ -828,12 +828,10 @@ Here is an example that counts the number of spaces with <F4>: >
|
||||
let &selection = "inclusive"
|
||||
let reg_save = @@
|
||||
|
||||
if a:0 " Invoked from Visual mode, use '< and '> marks.
|
||||
silent exe "normal! `<" . a:type . "`>y"
|
||||
if a:0 " Invoked from Visual mode, use gv command.
|
||||
silent exe "normal! gvy"
|
||||
elseif a:type == 'line'
|
||||
silent exe "normal! '[V']y"
|
||||
elseif a:type == 'block'
|
||||
silent exe "normal! `[\<C-V>`]y"
|
||||
else
|
||||
silent exe "normal! `[v`]y"
|
||||
endif
|
||||
|
@ -1,4 +1,4 @@
|
||||
*options.txt* For Vim version 7.4. Last change: 2014 May 13
|
||||
*options.txt* For Vim version 7.4. Last change: 2014 May 28
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
|
@ -1,4 +1,4 @@
|
||||
*pattern.txt* For Vim version 7.4. Last change: 2014 May 13
|
||||
*pattern.txt* For Vim version 7.4. Last change: 2014 May 28
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -1332,7 +1332,7 @@ Finally, these constructs are unique to Perl:
|
||||
patterns defined by both |matchadd()| and |:match|.
|
||||
|
||||
Highlighting matches using |:match| are limited to three
|
||||
matches (aside from |:match|, |:2match| and |:3match|are
|
||||
matches (aside from |:match|, |:2match| and |:3match| are
|
||||
available). |matchadd()| does not have this limitation and in
|
||||
addition makes it possible to prioritize matches.
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
*syntax.txt* For Vim version 7.4. Last change: 2014 Apr 05
|
||||
*syntax.txt* For Vim version 7.4. Last change: 2014 Jun 03
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -2279,7 +2279,7 @@ files, you may set the 'perl_include_pod' option to 0: >
|
||||
|
||||
:let perl_include_pod = 0
|
||||
|
||||
The reduce the complexity of parsing (and increase performance) you can switch
|
||||
To reduce the complexity of parsing (and increase performance) you can switch
|
||||
off two elements in the parsing of variable names and contents. >
|
||||
|
||||
To handle package references in variable and function names not differently
|
||||
|
@ -2523,6 +2523,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
:noautocmd autocmd.txt /*:noautocmd*
|
||||
:noh pattern.txt /*:noh*
|
||||
:nohlsearch pattern.txt /*:nohlsearch*
|
||||
:nor map.txt /*:nor*
|
||||
:norea map.txt /*:norea*
|
||||
:noreabbrev map.txt /*:noreabbrev*
|
||||
:noremap map.txt /*:noremap*
|
||||
@ -4795,6 +4796,7 @@ argidx() eval.txt /*argidx()*
|
||||
arglist editing.txt /*arglist*
|
||||
arglist-position editing.txt /*arglist-position*
|
||||
arglist-quit usr_07.txt /*arglist-quit*
|
||||
arglistid() eval.txt /*arglistid()*
|
||||
argument-list editing.txt /*argument-list*
|
||||
argv() eval.txt /*argv()*
|
||||
as motion.txt /*as*
|
||||
@ -6128,6 +6130,7 @@ getcharmod() eval.txt /*getcharmod()*
|
||||
getcmdline() eval.txt /*getcmdline()*
|
||||
getcmdpos() eval.txt /*getcmdpos()*
|
||||
getcmdtype() eval.txt /*getcmdtype()*
|
||||
getcurpos() eval.txt /*getcurpos()*
|
||||
getcwd() eval.txt /*getcwd()*
|
||||
getfontname() eval.txt /*getfontname()*
|
||||
getfperm() eval.txt /*getfperm()*
|
||||
|
@ -1,4 +1,4 @@
|
||||
*todo.txt* For Vim version 7.4. Last change: 2014 May 22
|
||||
*todo.txt* For Vim version 7.4. Last change: 2014 Jun 12
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -50,6 +50,8 @@ Regexp problems:
|
||||
Problem that a previous silent ":throw" causes a following try/catch not to
|
||||
work. (ZyX, 2013 Sep 28)
|
||||
|
||||
Completion for :buf does not use 'wildignorecase'. (Akshay H, 2014 May 31)
|
||||
|
||||
":cd C:\Windows\System32\drivers\etc*" does not work, even though the
|
||||
directory exists. (Sergio Gallelli, 2013 Dec 29)
|
||||
|
||||
@ -60,13 +62,28 @@ Setting 'ttymouse' empty causes Dec mouse to be detected. (Elijah Griffin,
|
||||
|
||||
Python: ":py raw_input('prompt')" doesn't work. (Manu Hack)
|
||||
|
||||
Value returned by virtcol() changes depending on how lines wrap. This is
|
||||
inconsistant with the documentation.
|
||||
|
||||
Serbian translation of the vimtutor. (Ivan Nejgebauer, 2014 Jun 2)
|
||||
|
||||
Patch to add matchaddpos(), match using a position instead of a pattern.
|
||||
To be used for matchparen. (Alexey Radkov, 2014 Jun 1)
|
||||
Waiting for tests. Some on Jun 2.
|
||||
|
||||
MS-Windows: Crash opening very long file name starting with "\\".
|
||||
(Christian Brock, 2012 Jun 29)
|
||||
|
||||
Syntax highlighting slow (hangs) in SASS file. (Niek Bosch, 2013 Aug 21)
|
||||
|
||||
Patch to translate 0xce in K_NUL 3. (Yasuhiro Matsumoto, 2014 June 6)
|
||||
Doesn't work yet.
|
||||
|
||||
Adding "~" to 'cdpath' doesn't work for completion? (Davido, 2013 Aug 19)
|
||||
|
||||
"hi link" does not respect groups with GUI settings only. (Mark Lodato, 2014
|
||||
Jun 8)
|
||||
|
||||
Syntax file for gnuplot. Existing one is very old. (Andrew Rasmussen, 2014
|
||||
Feb 24)
|
||||
|
||||
@ -90,7 +107,7 @@ Also fixes wrong result from executable().
|
||||
Update from Ken Takata, 2014 Jan 10. Newer 2014 Apr 3.
|
||||
|
||||
Win32: use 64 bit stat() if possible. (Ken Takata, 2014 May 12)
|
||||
More tests May 14.
|
||||
More tests May 14. Update May 29.
|
||||
|
||||
Idea: For a window in the middle (has window above and below it), use
|
||||
right-mouse-drag on the status line to move a window up/down without changing
|
||||
@ -99,22 +116,23 @@ it's height? It's like dragging the status bar above it at the same time.
|
||||
Can we make ":unlet $VAR" use unsetenv() to delete the env var?
|
||||
What for systems that don't have unsetenv()?
|
||||
|
||||
Patch to make getchar() work for typing Esc. (Yasuhiro Matsumoto, 2014 May 13)
|
||||
|
||||
Patch for problem that v:register is set to '_' after deleting into the black
|
||||
hole register.
|
||||
|
||||
This does not give an error: (Andre Sihera, 2014 Mar 21)
|
||||
vim -u NONE 1 2 3 -c 'bufdo if 1 | echo 1'
|
||||
This neither: (ZyX)
|
||||
vim -u NONE 1 2 3 -c 'bufdo while 1 | echo 1'
|
||||
|
||||
Patch for signs in GTK. (Christian Brabandt, 2014 Jun 10)
|
||||
Asked about it.
|
||||
|
||||
'viewdir' default on MS-Windows is not a good choice, it's a system directory.
|
||||
Change 'viewdir' to "$HOME/vimfiles/view" and use 'viewdiralt' to also read
|
||||
from?
|
||||
|
||||
Patch to add arglistid(), get the ID of the currently used argument list.
|
||||
(Marcin Szamotulski, 2014 Apr 27)
|
||||
Problem with upwards search on Windows (works OK on Linux). (Brett Stahlman,
|
||||
2014 Jun 8)
|
||||
|
||||
When 'clipboard' is "unnamed", :g/pat/d is very slow. Only set the clipboard
|
||||
after the last delete? (Praful, 2014 May 28)
|
||||
|
||||
Include a plugin manager with Vim? Neobundle seems to be the best currently.
|
||||
Long message about this from ZyX, 2014 Mar 23. And following replies.
|
||||
@ -153,16 +171,6 @@ Out of scope:
|
||||
Setting the spell file in a session only reads the local additions, not the
|
||||
normal spell file. (Enno Nagel, 2014 Mar 29)
|
||||
|
||||
- Patch for 'breakindent' option: repeat indent for wrapped line. (Vaclav
|
||||
Smilauer, 2004 Sep 13, fix Oct 31, update 2007 May 30)
|
||||
Version for latest MacVim: Tobia Conforto, 2009 Nov 23
|
||||
More recent version: https://retracile.net/wiki/VimBreakIndent
|
||||
Posted to vim-dev by Taylor Hedberg, 2011 Nov 25
|
||||
Update by Taylor Hedberg, 2013 May 30.
|
||||
Updated for Vim 7.4 by Ken Takata, 2013 Oct 5.
|
||||
Update by Christian Brabandt, 2014 May 9. Remarks by Ken Takata.
|
||||
Update by Christian 2014 May 12, github link on May 15
|
||||
|
||||
When typing the first character of a command, e.g. "f", then using a menu, the
|
||||
menu item doesn't work. Clear typeahead when using a menu?
|
||||
|
||||
@ -176,9 +184,10 @@ VMS: Select() doesn't work properly, typing ESC may hang Vim. Use sys$qiow
|
||||
instead. (Samuel Ferencik, 2013 Sep 28)
|
||||
|
||||
Patch for XDG base directory support. (Jean François Bignolles, 2014 Mar 4)
|
||||
Remark on the docs. Should not be a compile time feature. But then what?
|
||||
|
||||
Patch to add flag to shortmess to avoid giving completion messages.
|
||||
(Shougo Matsu, 2014 Jan 6, update Jan 11)
|
||||
Completion of ":e" is ":earlier", whould be ":edit". Complete to the matching
|
||||
command instead of doing this alphabetically. (Mikel Jorgensen)
|
||||
|
||||
Patch to add v:completed_item. (Shougo Matsu, 2013 Nov 29).
|
||||
|
||||
@ -314,6 +323,17 @@ Issue 28.
|
||||
Patch to fix that 'cedit' is recognized after :normal. (Christian Brabandt,
|
||||
2013 Mar 19, later message)
|
||||
|
||||
- Patch for 'breakindent' option: repeat indent for wrapped line. (Vaclav
|
||||
Smilauer, 2004 Sep 13, fix Oct 31, update 2007 May 30)
|
||||
Version for latest MacVim: Tobia Conforto, 2009 Nov 23
|
||||
More recent version: https://retracile.net/wiki/VimBreakIndent
|
||||
Posted to vim-dev by Taylor Hedberg, 2011 Nov 25
|
||||
Update by Taylor Hedberg, 2013 May 30.
|
||||
Updated for Vim 7.4 by Ken Takata, 2013 Oct 5.
|
||||
Update by Christian Brabandt, 2014 May 9. Remarks by Ken Takata.
|
||||
Update by Christian 2014 May 12, github link on May 15
|
||||
2014 May 28: remarks from Bram
|
||||
|
||||
Patch to view coverage of the tests. (Nazri Ramliy, 2013 Feb 15)
|
||||
|
||||
Patch to invert characters differently in GTK. (Yukihiro Nakadaira, 2013 May
|
||||
@ -358,9 +378,6 @@ Patch by Christian Brabandt, 2013 Apr 20, unfinished.
|
||||
|
||||
Bug: findfile("any", "file:///tmp;") does not work.
|
||||
|
||||
v:register is not directly reset to " after a delete command that specifies a
|
||||
register. It is reset after the next command. (Steve Vermeulen, 2013 Mar 16)
|
||||
|
||||
'ff' is wrong for one-line file without EOL. (Issue 77)
|
||||
|
||||
Patch to set antialiasing style on Windows. (Ondrej Balaz, 2013 Mar 14)
|
||||
@ -791,10 +808,6 @@ setpos() does not restore cursor position after :normal. (Tyru, 2010 Aug 11)
|
||||
file names unique, also support this for 'backupdir'. (Mikolaj Machowski)
|
||||
Patch by Christian Brabandt, 2010 Oct 21.
|
||||
|
||||
getpos()/setpos() don't include curswant. getpos() could return a fifth
|
||||
element. setpos() could accept an optional fifth element.
|
||||
Patch by Christian Brabandt, 2010 Sep 6. Again 2013 Aug 22.
|
||||
|
||||
With "tw=55 fo+=a" typing space before ) doesn't work well. (Scott Mcdermott,
|
||||
2010 Oct 24)
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
*undo.txt* For Vim version 7.4. Last change: 2013 Sep 08
|
||||
*undo.txt* For Vim version 7.4. Last change: 2014 May 24
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -97,9 +97,9 @@ change but joins in with the previous change use this command:
|
||||
or redo.
|
||||
{not in Vi}
|
||||
|
||||
This is most useful when you need to prompt the user halfway a change. For
|
||||
example in a function that calls |getchar()|. Do make sure that there was a
|
||||
related change before this that you must join with.
|
||||
This is most useful when you need to prompt the user halfway through a change.
|
||||
For example in a function that calls |getchar()|. Do make sure that there was
|
||||
a related change before this that you must join with.
|
||||
|
||||
This doesn't work by itself, because the next key press will start a new
|
||||
change again. But you can do something like this: >
|
||||
|
@ -1,4 +1,4 @@
|
||||
*usr_41.txt* For Vim version 7.4. Last change: 2014 Apr 05
|
||||
*usr_41.txt* For Vim version 7.4. Last change: 2014 May 28
|
||||
|
||||
VIM USER MANUAL - by Bram Moolenaar
|
||||
|
||||
@ -708,6 +708,7 @@ Cursor and mark position: *cursor-functions* *mark-functions*
|
||||
cursor() position the cursor at a line/column
|
||||
screencol() get screen column of the cursor
|
||||
screenrow() get screen row of the cursor
|
||||
getcurpos() get position of the cursor
|
||||
getpos() get position of cursor, mark, etc.
|
||||
setpos() set position of cursor, mark, etc.
|
||||
byte2line() get line number at a specific byte count
|
||||
|
@ -1,7 +1,7 @@
|
||||
" Vim support file to detect file types
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2014 Feb 26
|
||||
" Last Change: 2014 Jun 12
|
||||
|
||||
" Listen very carefully, I will say this only once
|
||||
if exists("did_load_filetypes")
|
||||
@ -1013,6 +1013,9 @@ au BufNewFile,BufRead *.kix setf kix
|
||||
" Kimwitu[++]
|
||||
au BufNewFile,BufRead *.k setf kwt
|
||||
|
||||
" Kivy
|
||||
au BufNewFile,BufRead *.kv setf kivy
|
||||
|
||||
" KDE script
|
||||
au BufNewFile,BufRead *.ks setf kscript
|
||||
|
||||
|
@ -2,7 +2,7 @@
|
||||
" You can also use this as a start for your own set of menus.
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2013 May 17
|
||||
" Last Change: 2014 May 22
|
||||
|
||||
" Note that ":an" (short for ":anoremenu") is often used to make a menu work
|
||||
" in all modes and avoid side effects from mappings defined by the user.
|
||||
@ -477,6 +477,7 @@ if has("folding")
|
||||
an 40.340.110 &Tools.&Folding.&Enable/Disable\ folds<Tab>zi zi
|
||||
an 40.340.120 &Tools.&Folding.&View\ Cursor\ Line<Tab>zv zv
|
||||
an 40.340.120 &Tools.&Folding.Vie&w\ Cursor\ Line\ only<Tab>zMzx zMzx
|
||||
inoremenu 40.340.120 &Tools.&Folding.Vie&w\ Cursor\ Line\ only<Tab>zMzx <C-O>zM<C-O>zx
|
||||
an 40.340.130 &Tools.&Folding.C&lose\ more\ folds<Tab>zm zm
|
||||
an 40.340.140 &Tools.&Folding.&Close\ all\ folds<Tab>zM zM
|
||||
an 40.340.150 &Tools.&Folding.O&pen\ more\ folds<Tab>zr zr
|
||||
|
@ -1,7 +1,7 @@
|
||||
" Vim syntax file
|
||||
" Language: C
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2013 Jul 05
|
||||
" Last Change: 2014 May 26
|
||||
|
||||
" Quit when a (custom) syntax file was already loaded
|
||||
if exists("b:current_syntax")
|
||||
@ -322,6 +322,9 @@ if !exists("c_no_ansi") || exists("c_ansi_constants") || exists("c_gnu")
|
||||
syn keyword cConstant SEEK_CUR SEEK_END SEEK_SET
|
||||
syn keyword cConstant TMP_MAX stderr stdin stdout
|
||||
syn keyword cConstant EXIT_FAILURE EXIT_SUCCESS RAND_MAX
|
||||
" POSIX 2001
|
||||
syn keyword cConstant SIGBUS SIGPOLL SIGPROF SIGSYS SIGURG
|
||||
syn keyword cConstant SIGVTALRM SIGXCPU SIGXFSZ
|
||||
" Add POSIX errors as well
|
||||
syn keyword cConstant E2BIG EACCES EAGAIN EBADF EBADMSG EBUSY
|
||||
syn keyword cConstant ECANCELED ECHILD EDEADLK EDOM EEXIST EFAULT
|
||||
|
@ -2,7 +2,7 @@
|
||||
" Language: J
|
||||
" Maintainer: David Bürgin <676c7473@gmail.com>
|
||||
" URL: https://github.com/glts/vim-j
|
||||
" Last Change: 2014-04-05
|
||||
" Last Change: 2014-05-25
|
||||
|
||||
if exists('b:current_syntax')
|
||||
finish
|
||||
@ -46,7 +46,7 @@ syntax match jStdlibVerb /\<\%(assert\|break\|do\)\>\.\@!/
|
||||
" All in all, a compromise between correctness and practicality had to be
|
||||
" made. See http://www.jsoftware.com/help/dictionary/dcons.htm for reference.
|
||||
syntax match jNumber /\<_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\%(\%(r_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\%([px]_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\%(r_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\)\=\)\=\)\|\%(\%(j\|a[dr]\)_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\%([px]_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\%(\%(j\|a[dr]\)_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\)\=\)\=\)\|\%([px]_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\%(\%(j\|a[dr]\|r\)_\=\d\+\%(\.\d*\)\=\%([eE]_\=\d\+\)\=\)\=\)\)\=/
|
||||
syntax match jNumber /\<_\=\d\+\%([eE]\d\+\)\=b_\=[0-9a-z]\+/
|
||||
syntax match jNumber /\<_\=\d\+\%([eE]\d\+\)\=b_\=[0-9a-z]\+\%(\.[0-9a-z]\+\)\=/
|
||||
syntax match jNumber /\<__\=\>/
|
||||
syntax match jNumber /\<_\./
|
||||
syntax match jNumber /\<_\=\d\+x\>/
|
||||
@ -64,15 +64,20 @@ syntax match jVerb /[=!\]]\|[\^?]\.\=\|[;[]:\=\|{\.\|[_/\\]:\|[<>+*\-%$|,#][.:]\
|
||||
syntax match jCopula /=[.:]/
|
||||
syntax match jConjunction /;\.\|\^:\|![.:]/
|
||||
|
||||
" Explicit noun definition. The difficulty is that the define expression
|
||||
" "0 : 0" can occur in the middle of a line but the jNounDefine region must
|
||||
" only start on the next line. The trick is to split the problem into two
|
||||
" regions and link them with "nextgroup=".
|
||||
" Explicit noun definition. The difficulty is that the define expression can
|
||||
" occur in the middle of a line but the jNounDefine region must only start on
|
||||
" the next line. The trick is to split the problem into two regions and link
|
||||
" them with "nextgroup=". The fold wrapper provides syntax folding.
|
||||
syntax region jNounDefineFold
|
||||
\ matchgroup=NONE start=/\<\%(\%(0\|noun\)\s\+\%(\:\s*0\|def\s\+0\|define\)\>\)\@=/
|
||||
\ keepend matchgroup=NONE end=/^\s*)\s*$/
|
||||
\ contains=jNounDefineStart
|
||||
\ fold
|
||||
syntax region jNounDefineStart
|
||||
\ matchgroup=jDefineExpression start=/\<\%(0\|noun\)\s\+\%(\:\s*0\|def\s\+0\|define\)\>/
|
||||
\ keepend matchgroup=NONE end=/$/
|
||||
\ contains=@jStdlibItems,@jPrimitiveItems,jNumber,jString,jParenGroup,jParen,jComment
|
||||
\ oneline skipempty nextgroup=jDefineEnd,jNounDefine
|
||||
\ contained oneline skipempty nextgroup=jDefineEnd,jNounDefine
|
||||
" These two items must have "contained", which allows them to match only after
|
||||
" jNounDefineStart thanks to the "nextgroup=" above.
|
||||
syntax region jNounDefine
|
||||
@ -87,6 +92,7 @@ syntax region jDefine
|
||||
\ matchgroup=jDefineExpression start=/\<\%([1-4]\|13\|adverb\|conjunction\|verb\|monad\|dyad\)\s\+\%(:\s*0\|def\s\+0\|define\)\>/
|
||||
\ matchgroup=jDefineEnd end=/^\s*)\s*$/
|
||||
\ contains=jControl,@jStdlibItems,@jPrimitiveItems,jNumber,jString,jArgument,jParenGroup,jParen,jComment,jDefineMonadDyad
|
||||
\ fold
|
||||
syntax match jDefineMonadDyad contained /^\s*:\s*$/
|
||||
|
||||
" Paired parentheses. When a jDefineExpression such as "3 : 0" is
|
||||
|
36
runtime/syntax/kivy.vim
Normal file
36
runtime/syntax/kivy.vim
Normal file
@ -0,0 +1,36 @@
|
||||
" Vim syntax file
|
||||
" Language: Kivy
|
||||
" Maintainer: Corey Prophitt <prophitt.corey@gmail.com>
|
||||
" Last Change: May 29th, 2014
|
||||
" Version: 1
|
||||
" URL: http://kivy.org/
|
||||
|
||||
if exists("b:current_syntax")
|
||||
finish
|
||||
endif
|
||||
|
||||
" Load Python syntax first (Python can be used within Kivy)
|
||||
syn include @pyth $VIMRUNTIME/syntax/python.vim
|
||||
|
||||
" Kivy language rules can be found here
|
||||
" http://kivy.org/docs/guide/lang.html
|
||||
|
||||
" Define Kivy syntax
|
||||
syn match kivyPreProc /#:.*/
|
||||
syn match kivyComment /#.*/
|
||||
syn match kivyRule /<\I\i*\(,\s*\I\i*\)*>:/
|
||||
syn match kivyAttribute /\<\I\i*\>/ nextgroup=kivyValue
|
||||
|
||||
syn region kivyValue start=":" end=/$/ contains=@pyth skipwhite
|
||||
|
||||
syn region kivyAttribute matchgroup=kivyIdent start=/[\a_][\a\d_]*:/ end=/$/ contains=@pyth skipwhite
|
||||
|
||||
hi def link kivyPreproc PreProc
|
||||
hi def link kivyComment Comment
|
||||
hi def link kivyRule Function
|
||||
hi def link kivyIdent Statement
|
||||
hi def link kivyAttribute Label
|
||||
|
||||
let b:current_syntax = "kivy"
|
||||
|
||||
" vim: ts=8
|
@ -1,10 +1,10 @@
|
||||
" ninja build file syntax.
|
||||
" Language: ninja build file as described at
|
||||
" http://martine.github.com/ninja/manual.html
|
||||
" Version: 1.3
|
||||
" Last Change: 2013/04/16
|
||||
" Version: 1.4
|
||||
" Last Change: 2014/05/13
|
||||
" Maintainer: Nicolas Weber <nicolasweber@gmx.de>
|
||||
" Version 1.3 of this script is in the upstream vim repository and will be
|
||||
" Version 1.4 of this script is in the upstream vim repository and will be
|
||||
" included in the next vim release. If you change this, please send your change
|
||||
" upstream.
|
||||
|
||||
@ -55,6 +55,7 @@ syn keyword ninjaPoolCommand contained depth
|
||||
" $simple_varname -> variable
|
||||
" ${varname} -> variable
|
||||
|
||||
syn match ninjaDollar "\$\$"
|
||||
syn match ninjaWrapLineOperator "\$$"
|
||||
syn match ninjaSimpleVar "\$[a-zA-Z0-9_-]\+"
|
||||
syn match ninjaVar "\${[a-zA-Z0-9_.-]\+}"
|
||||
@ -70,6 +71,7 @@ hi def link ninjaComment Comment
|
||||
hi def link ninjaKeyword Keyword
|
||||
hi def link ninjaRuleCommand Statement
|
||||
hi def link ninjaPoolCommand Statement
|
||||
hi def link ninjaDollar ninjaOperator
|
||||
hi def link ninjaWrapLineOperator ninjaOperator
|
||||
hi def link ninjaOperator Operator
|
||||
hi def link ninjaSimpleVar ninjaVar
|
||||
|
Loading…
x
Reference in New Issue
Block a user