Skip to content
Snippets Groups Projects
Commit d09acef4 authored by Bram Moolenaar's avatar Bram Moolenaar
Browse files

Updated runtime files.

parent 66b7985e
No related branches found
No related tags found
No related merge requests found
Showing
with 558 additions and 289 deletions
*autocmd.txt* For Vim version 7.3. Last change: 2012 Jul 10
*autocmd.txt* For Vim version 7.3. Last change: 2012 Sep 05
VIM REFERENCE MANUAL by Bram Moolenaar
......@@ -263,8 +263,10 @@ Name triggered by ~
Startup and exit
|VimEnter| after doing all the startup stuff
|GUIEnter| after starting the GUI successfully
|GUIFailed| after starting the GUI failed
|TermResponse| after the terminal response to |t_RV| is received
|QuitPre| when using `:quit`, before deciding whether to quit
|VimLeavePre| before exiting Vim, before writing the viminfo file
|VimLeave| before exiting Vim, after writing the viminfo file
......@@ -312,6 +314,7 @@ Name triggered by ~
|SessionLoadPost| after loading a session file
|MenuPopup| just before showing the popup menu
|CompleteDone| after Insert mode completion is done
|User| to be used in combination with ":doautocmd"
......
*diff.txt* For Vim version 7.3. Last change: 2012 Aug 08
*diff.txt* For Vim version 7.3. Last change: 2012 Sep 05
VIM REFERENCE MANUAL by Bram Moolenaar
......@@ -86,16 +86,16 @@ diff mode. You could use a construct like this: >
While already in Vim you can start diff mode in three ways.
*E98*
:diffsplit {filename} *:diffs* *:diffsplit*
:diffs[plit] {filename} *:diffs* *:diffsplit*
Open a new window on the file {filename}. The options are set
as for "vimdiff" for the current and the newly opened window.
Also see 'diffexpr'.
*:difft* *:diffthis*
:diffthis Make the current window part of the diff windows. This sets
:difft[his] Make the current window part of the diff windows. This sets
the options like for "vimdiff".
:diffpatch {patchfile} *E816* *:diffp* *:diffpatch*
:diffp[atch] {patchfile} *E816* *:diffp* *:diffpatch*
Use the current buffer, patch it with the diff found in
{patchfile} and open a buffer on the result. The options are
set as for "vimdiff".
......@@ -123,9 +123,9 @@ Since the option values are remembered with the buffer, you can edit another
file for a moment and come back to the same file and be in diff mode again.
*:diffo* *:diffoff*
:diffoff Switch off diff mode for the current window.
:diffo[ff] Switch off diff mode for the current window.
:diffoff! Switch off diff mode for the current window and in all windows
:diffo[ff]! Switch off diff mode for the current window and in all windows
in the current tab page where 'diff' is set.
The ":diffoff" command resets the relevant options to their default value.
......
*eval.txt* For Vim version 7.3. Last change: 2012 Aug 02
*eval.txt* For Vim version 7.3. Last change: 2012 Sep 05
VIM REFERENCE MANUAL by Bram Moolenaar
......@@ -759,7 +759,7 @@ of a |List| is different from the original |List|. When using "is" without
a |List| or a |Dictionary| it is equivalent to using "equal", using "isnot"
equivalent to using "not equal". Except that a different type means the
values are different: "4 == '4'" is true, "4 is '4'" is false and "0 is []" is
false and not a error. "is#"/"isnot#" and "is?"/"isnot?" can be used to match
false and not an error. "is#"/"isnot#" and "is?"/"isnot?" can be used to match
and ignore case.
When comparing a String with a Number, the String is converted to a Number,
......@@ -4635,8 +4635,8 @@ pyeval({expr}) *pyeval()*
Numbers and strings are returned as they are (strings are
copied though).
Lists are represented as Vim |List| type.
Dictionaries are represented as Vim |Dictionary| type with
keys converted to strings.
Dictionaries are represented as Vim |Dictionary| type,
non-string keys result in error.
{only available when compiled with the |+python| feature}
*E726* *E727*
......@@ -5253,8 +5253,9 @@ setreg({regname}, {value} [,{options}])
If {options} contains no register settings, then the default
is to use character mode unless {value} ends in a <NL>.
Setting the '=' register is not possible.
Returns zero for success, non-zero for failure.
Setting the '=' register is not possible, but you can use >
:let @= = var_expr
< Returns zero for success, non-zero for failure.
Examples: >
:call setreg(v:register, @*)
......
......@@ -93,7 +93,7 @@ Details
This is also the keymap when 'keymap=hebrew' is set. The advantage of
'keymap' is that it works properly when using UTF8, e.g. it inserts the
correct characters; 'hkmap' does not. The 'keymap' keyboard can also
insert niqud and te`amim. To see what those mappings are,look at the
insert niqud and te`amim. To see what those mappings are, look at the
keymap file 'hebrew.vim' etc.
......
......@@ -159,6 +159,26 @@ vim.bindeval(str) *python-bindeval*
vimlist or vimdictionary python type that are connected to original
list or dictionary. Thus modifications to these objects imply
modifications of the original.
Additionally, vimlist and vimdictionary type have read-write
`.locked` attribute that returns
Value Meaning ~
zero Variable is not locked
vim.VAR_LOCKED Variable is locked, but can be unlocked
vim.VAR_FIXED Variable is locked and can’t be unlocked
integer constants. If variable is not fixed, you can do
`var.locked=True` to lock it and `var.locked=False` to unlock.
There is no recursive locking like |:lockvar|! does. There is also
no way to lock a specific key or check whether it is locked (in any
case these locks are ignored by anything except |:let|: |extend()|
does not care, neither does python interface).
Vimdictionary type also supports `.scope` attribute which is one of
Value Meaning ~
zero Dictionary is not a scope one
vim.VAR_DEF_SCOPE Function-local or global scope dictionary
vim.VAR_SCOPE Other scope dictionary
2. if expression evaluates to a function reference, then it returns
callable vimfunction object. Use self keyword argument to assign
|self| object for dictionary functions.
......
*indent.txt* For Vim version 7.3. Last change: 2011 Sep 02
*indent.txt* For Vim version 7.3. Last change: 2012 Aug 30
VIM REFERENCE MANUAL by Bram Moolenaar
......@@ -540,7 +540,7 @@ The examples below assume a 'shiftwidth' of 4.
*cino-star*
*N Vim searches for unclosed comments at most N lines away. This
limits the time needed to search for the start of a comment.
If your /* */ comments stop indenting afer N lines this is the
If your /* */ comments stop indenting after N lines this is the
value you will want to change.
(default 70 lines).
......
*intro.txt* For Vim version 7.3. Last change: 2011 May 15
*intro.txt* For Vim version 7.3. Last change: 2012 Sep 05
VIM REFERENCE MANUAL by Bram Moolenaar
......@@ -394,6 +394,8 @@ CTRL-{char} {char} typed as a control character; that is, typing {char}
*quotecommandquote*
"command" A reference to a command that you can type is enclosed in
double quotes.
`command` New style command, this distinguishes it from other
quoted text and strings.
*key-notation* *key-codes* *keycodes*
These names for keys are used in the documentation. They can also be used
......
*todo.txt* For Vim version 7.3. Last change: 2012 Aug 15
*todo.txt* For Vim version 7.3. Last change: 2012 Sep 21
VIM REFERENCE MANUAL by Bram Moolenaar
......@@ -36,6 +36,9 @@ not be repeated below, unless there is extra information.
Go through more coverity reports.
Ruby problem, patch in issue 49. (Sep 19)
Also in email from Ondruch?
Discussion about canonicalization of Hebrew. (Ron Aaron, 2011 April 10)
GTK: problem with 'L' in 'guioptions' changing the window width.
......@@ -43,12 +46,35 @@ GTK: problem with 'L' in 'guioptions' changing the window width.
Checking runtime scripts: Thilo Six, 2012 Jun 6.
Crash with 1023 byte directory name. (Danek Duvall, 2012 Sep 19)
Patch for SGR mouse with older xterm. (Hayaki Saito, 2012 Sep 19)
Patch for crash with an autocommand. (ZyX, 2012 Sep 6, second one)
Also patch for garbage, but use vim_strncpy() instead.
Patch to fix crash on Win32 when setting 'encoding'. (Jiri Sedlak, 2012 Sep
12)
Patch to update example using empty(). (ZyX, 2012 Sep 13)
Javascript file where indent gets stuck on: GalaxyMaster, 2012 May 3.
Updated French and Esperanto files. (Dominique Pelle, 2012 Aug 19)
When showing diffs filler lines may be hidden at first.
Patch by Christian Brabandt, 2012 Sep 6.
Patch for memory leaks on exception. (ZyX, 2012 Sep 9)
The CompleteDone autocommand needs some info passed to it:
- The word that was selected (empty if abandoned complete)
- Type of completion: tag, omnifunc, user func.
mouse_sgr is not ordered alphabetically in :version output.
Docs list mouse_urxvt as normal feature, should be big. (Hayaki Saito, 2012
Aug 16)
":gundo" command: global undo. Undoes changes spread over multiple files in
the order they were made. Also ":gredo". Both with a count. Useful when
tests fail after making changes and you forgot in which files.
......@@ -57,27 +83,45 @@ Win32: When a directory name contains an exclamation mark, completion doesn't
complete the contents of the directory. No escaping for the "!"? (Jan
Stocker, 2012 Jan 5)
Patch for IME handling, adds 'imactivatefunc' and 'imstatusfunc' option.
(Yukihiro Nakadaira, 2012 Aug 16)
Patch to improve IME handling. (Yasuhiro Matsumoto, 2012 Jul 18)
Issue 54: document behavior of -complete, also expands arg.
Patch for if_lua. (Luis Carvalho, 2012 Aug 26, update Aug 29, another Aug 30,
then Sep 1)
Issue 72: 'autochdir' causes problems for :vimgrep.
MS-Windows: Crash opening very long file name starting with "\\".
(Christian Brock, 2012 Jun 29)
Win32: patch for current directory, "loading iof conv". (Ken Takata, 2012 Sep
15)
Syntax update problem in one buffer opened in two windows, bottom window is
not correctly updated. (Paul Harris, 2012 Feb 27)
Patch to add assignments in cscope. (Uli Meis, Estabrooks, 2012 Sep 1)
Alternate patch by Gary Johnson, Sep 4.
Patch to add getsid(). (Tyru, 2011 Oct 2) Do we want this? Update Oct 4.
Or use expand('<sid>')?
Patch to improve IME handling. (Yasuhiro Matsumoto, 2012 Jul 18)
Patch for :tabcloseleft, after closing a tab go to left tab. (William Bowers,
2012 Aug 4)
Patch for Tab behavior with 'conceal'. (Dominique Pelle, 2012 Mar 18)
Patch to test functionality of 'conceal' with tabs. (Simon Ruderich, 2012 Sep
5) Update with screencol() and screenrow() functions: Sep 7.
Crash in autocmd that unloads buffers in a BufUnload event. (Andrew Pimlott,
2012 Aug 11) Disallow :new when BufUnload is being handled?
MS-Windows ACL support doesn't work well. Patch from Ken Takata, 2012 Aug 29.
Update Aug 31.
MS-Windows resizing problems:
- Windows window on screen positioning: Patch by Yukihiro Nakadaira, 2012 Jun
20. Uses getWindowRect() instead of GetWindowPlacement()
......@@ -94,6 +138,9 @@ The input map for CTRL-O in mswin.vim causes problems after CTRL-X CTRL-O.
Suggestion for another map. (Philip Mat, 2012 Jun 18)
But use "gi" instead of "a". Or use CTRL-\ CTRL-O.
Patch to support user name completion on MS-Windows. (Yasuhiro Matsumoto, 2012
Aug 16)
URXVT:
- will get stuck if byte sequence does not containe expected semicolon.
- Use urxvt mouse support also in xterm. Explanations:
......@@ -108,17 +155,23 @@ Do give the prompt? Quit with an error?
Patch for 'backupcopy' default behavior for symlinks on Windows. (David Pope,
2012 Mar 21, update Mar 31)
With fix for memory leak: Ken Takata, 2012 Aug 24
Patch to list user digraphs. (Christian Brabandt, 2012 Apr 14)
Patch for input method status. (Hirohito Higashi, 2012 Apr 18)
Patch to print the result of a :python command. (Maxim Philippov
<philippovmi@gmail.com>, 2012 Aug 16) Update Aug 17.
Problem with winfixheight and resizing. (Yukihiro Nakadaira, 2011 Sep 17)
Patch Sep 18.
Patch for IME problems. Remove hacking code for old IM. (Yukihiro Nakadaira,
2012 Jul 20)
/[^\n] does match at a line break. Expected to do the same as /.
Patch for has('unnamedplus') docs. (Tony Mechelynck, 2011 Sep 27)
And one for gui_x11.txt.
......@@ -162,9 +215,6 @@ Patch to add ":py3do". (Lilydjwg, 2012 Apr 7)
Plugin for Modeleasy. (Massimiliano Tripoli, 2011 Nov 29)
When using remote-silent the -R flag is not passed on. (Axel Bender, 2012 May
31)
Updated syntax file for ssh_config, maintainer doesn't respond.
(Leonard Ehrenfried, 2011 Sep 26)
......@@ -725,10 +775,6 @@ Support a 'systemencoding' option (for Unix). It specifies the encoding of
file names. (Kikuchan, 2010 Oct 5). Useful on a latin1 or double-byte Asian
system when 'encoding' is "utf-8".
Win32: A --remote command that has a directory name starting with a ( doesn't
work, the backslash is removed, assuming that it escapes the (. (Valery
Kondakoff, 2009 May 13)
Win32 GUI: Changing manifest helps for dpi changes (Joe Castro, 2009 Mar 27)
Win32 GUI: last message from startup doesn't show up when there is an echoerr
......@@ -914,6 +960,15 @@ escaping characters where the backslash is not removed later. Asked Chris for
an alternate solution, also for src/ex_getln.c.
This also fails when the file or directory name contains "%". (Thoml, 2008
July 7)
Using --remote-silent while the current directory has a # in the name does not
work, the # needs to be escaped. (Tramblay Bruno, 2012 Sep 15)
When using remote-silent the -R flag is not passed on. (Axel Bender, 2012 May
31)
Win32: A --remote command that has a directory name starting with a ( doesn't
work, the backslash is removed, assuming that it escapes the (. (Valery
Kondakoff, 2009 May 13)
Problem with 'langmap' being used on the rhs of a mapping. (Nikolai Weibull,
2008 May 14)
......
......@@ -1681,7 +1681,7 @@ in your plugin file!
HEADER
You will probably add new corrections to the plugin and soon have several
versions laying around. And when distributing this file, people will want to
versions lying around. And when distributing this file, people will want to
know who wrote this wonderful plugin and where they can send remarks.
Therefore, put a header at the top of your plugin: >
......
......@@ -66,7 +66,7 @@ position.
lines as used for the last Visual operation, but at
the current cursor position, multiplied by [count].
When the previous Visual operation was on a block both
the width and height of the block are multipiled by
the width and height of the block are multiplied by
[count].
When there was no previous Visual operation [count]
characters are selected. This is like moving the
......
" Vim support file to detect file types
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2012 Aug 02
" Last Change: 2012 Sep 06
" Listen very carefully, I will say this only once
if exists("did_load_filetypes")
......@@ -1772,6 +1772,10 @@ func! SetFileTypeSH(name)
" Some .sh scripts contain #!/bin/tcsh.
call SetFileTypeShell("tcsh")
return
elseif a:name =~ '\<zsh\>'
" Some .sh scripts contain #!/bin/zsh.
call SetFileTypeShell("zsh")
return
elseif a:name =~ '\<ksh\>'
let b:is_kornshell = 1
if exists("b:is_bash")
......
" Vim filetype plugin file
" Language: generic Changelog file
" Maintainer: Nikolai Weibull <now@bitwi.se>
" Latest Revision: 2011-05-02
" Latest Revision: 2012-08-23
" Variables:
" g:changelog_timeformat (deprecated: use g:changelog_dateformat instead) -
" description: the timeformat used in ChangeLog entries.
......@@ -106,10 +106,10 @@ if &filetype == 'changelog'
function! s:passwd_field(line, field)
let fields = split(a:line, ':', 1)
if len(fields) < field
if len(fields) < a:field
return ""
endif
return fields[field - 1]
return fields[a:field - 1]
endfunction
function! s:capitalize(word)
......
" Vim filetype plugin file
" Language: Zimbu
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2012 May 18
" Last Change: 2012 Sep 08
" Only do this when not done yet for this buffer
if exists("b:did_ftplugin")
......@@ -34,7 +34,7 @@ setlocal errorformat^=%f\ line\ %l\ col\ %c:\ %m,ERROR:\ %m
" When the matchit plugin is loaded, this makes the % command skip parens and
" braces in comments.
let b:match_words = '\(^\s*\)\@<=\(MODULE\|CLASS\|INTERFACE\|BITS\|ENUM\|SHARED\|FUNC\|REPLACE\|DEFINE\|PROC\|EQUAL\|MAIN\|IF\|GENERATE_IF\|WHILE\|REPEAT\|WITH\|DO\|FOR\|SWITCH\|TRY\)\>\|{\s*$:\(^\s*\)\@<=\(ELSE\|ELSEIF\|GENERATE_ELSE\|GENERATE_ELSEIF\|CATCH\|FINALLY\)\>:\(^\s*\)\@<=}\|\<UNTIL\>'
let b:match_words = '\(^\s*\)\@<=\(MODULE\|CLASS\|INTERFACE\|BITS\|ENUM\|SHARED\|FUNC\|REPLACE\|DEFINE\|PROC\|EQUAL\|MAIN\|IF\|GENERATE_IF\|WHILE\|REPEAT\|WITH\|DO\|FOR\|SWITCH\|TRY\)\>\|{\s*$:\(^\s*\)\@<=\(ELSE\|ELSEIF\|GENERATE_ELSE\|GENERATE_ELSEIF\|CATCH\|FINALLY\)\>:\(^\s*\)\@<=\(}\|\<UNTIL\>\)'
let b:match_skip = 's:comment\|string\|zimbuchar'
......@@ -43,35 +43,22 @@ setlocal et sts=2 sw=2
" Does replace when a dot, space or closing brace is typed.
func! GCUpperDot(what)
let col = col(".") - strlen(a:what)
if v:char != ' ' && v:char != "\r" && v:char != "\x1b" && v:char != '.' && v:char != ')' && v:char != '}'
if v:char != ' ' && v:char != "\r" && v:char != "\x1b" && v:char != '.' && v:char != ')' && v:char != '}' && v:char != ','
" no space or dot after the typed text
let g:got_char = v:char
return a:what
endif
if col > 1 && getline('.')[col - 2] != ' '
" no space before the typed text
let g:got_char = 999
return a:what
endif
let synName = synIDattr(synID(line("."), col(".") - 2, 1), "name")
if synName =~ 'Comment\|String\|zimbuCregion\|\<c'
" inside a comment or C code
let g:got_char = 777
return a:what
endif
let g:got_char = 1111
return toupper(a:what)
return GCUpperCommon(a:what)
endfunc
" Does not replace when a dot is typed.
func! GCUpper(what)
if v:char != ' ' && v:char != "\r" && v:char != "\x1b" && v:char != ')'
" no space after the typed text
if v:char != ' ' && v:char != "\r" && v:char != "\x1b" && v:char != ')' && v:char != ','
" no space or other "terminating" character after the typed text
let g:got_char = v:char
return a:what
endif
return GCUpperDot(a:what)
return GCUpperCommon(a:what)
endfunc
" Only replaces when a space is typed.
......@@ -81,17 +68,35 @@ func! GCUpperSpace(what)
let g:got_char = v:char
return a:what
endif
return GCUpperDot(a:what)
return GCUpperCommon(a:what)
endfunc
func! GCUpperCommon(what)
let col = col(".") - strlen(a:what)
if col > 1 && getline('.')[col - 2] != ' '
" no space before the typed text
let g:got_char = 999
return a:what
endif
let synName = synIDattr(synID(line("."), col(".") - 2, 1), "name")
if synName =~ 'Comment\|String\|zimbuCregion\|\<c'
" inside a comment or C code
let g:got_char = 777
return a:what
endif
let g:got_char = 1111
return toupper(a:what)
endfunc
iabbr <buffer> <expr> alias GCUpperSpace("alias")
iabbr <buffer> <expr> arg GCUpperDot("arg")
iabbr <buffer> <expr> bad GCUpper("bad")
iabbr <buffer> <expr> break GCUpper("break")
iabbr <buffer> <expr> case GCUpperSpace("case")
iabbr <buffer> <expr> catch GCUpperSpace("catch")
iabbr <buffer> <expr> check GCUpperDot("check")
iabbr <buffer> <expr> class GCUpperSpace("class")
iabbr <buffer> <expr> interface GCUpperSpace("interface")
iabbr <buffer> <expr> implements GCUpperSpace("implements")
iabbr <buffer> <expr> shared GCUpperSpace("shared")
iabbr <buffer> <expr> continue GCUpper("continue")
iabbr <buffer> <expr> default GCUpper("default")
......
" Vim indent file
" Language: Zimbu
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2011 Jun 19
" Last Change: 2012 Sep 08
" Only load this indent file when no other was loaded.
if exists("b:did_indent")
......@@ -101,7 +101,7 @@ func GetZimbuIndent(lnum)
endwhile
endif
if prevline =~ '^\s*\(IF\|\|ELSEIF\|ELSE\|GENERATE_IF\|\|GENERATE_ELSEIF\|GENERATE_ELSE\|WHILE\|REPEAT\|TRY\|CATCH\|FINALLY\|FOR\|DO\|SWITCH\|CASE\|DEFAULT\|FUNC\|VIRTUAL\|ABSTRACT\|DEFINE\|REPLACE\|FINAL\|PROC\|MAIN\|NEW\|ENUM\|CLASS\|BITS\|MODULE\|SHARED\)\>'
if prevline =~ '^\s*\(IF\|\|ELSEIF\|ELSE\|GENERATE_IF\|\|GENERATE_ELSEIF\|GENERATE_ELSE\|WHILE\|REPEAT\|TRY\|CATCH\|FINALLY\|FOR\|DO\|SWITCH\|CASE\|DEFAULT\|FUNC\|VIRTUAL\|ABSTRACT\|DEFINE\|REPLACE\|FINAL\|PROC\|MAIN\|NEW\|ENUM\|CLASS\|INTERFACE\|BITS\|MODULE\|SHARED\)\>'
let plindent += &sw
endif
if thisline =~ '^\s*\(}\|ELSEIF\>\|ELSE\>\|CATCH\|FINALLY\|GENERATE_ELSEIF\>\|GENERATE_ELSE\>\|UNTIL\>\)'
......
" Vim support file to detect file types in scripts
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last change: 2010 Sep 22
" Last change: 2012 Aug 30
" This file is called by an autocommand for every file that has just been
" loaded into a buffer. It checks if the type of file can be recognized by
......@@ -198,7 +198,8 @@ else
" - "=== ", line of "=", "---", "+++ " (SVK diff)
" - "=== ", "--- ", "+++ " (bzr diff, common case)
" - "=== (removed|added|renamed|modified)" (bzr diff, alternative)
elseif s:line1 =~ '^\(diff\>\|Only in \|\d\+\(,\d\+\)\=[cda]\d\+\>\|# It was generated by makepatch \|Index:\s\+\f\+\r\=$\|===== \f\+ \d\+\.\d\+ vs edited\|==== //\f\+#\d\+\)'
" - "# HG changeset patch" in first line (Mercurial export format)
elseif s:line1 =~ '^\(diff\>\|Only in \|\d\+\(,\d\+\)\=[cda]\d\+\>\|# It was generated by makepatch \|Index:\s\+\f\+\r\=$\|===== \f\+ \d\+\.\d\+ vs edited\|==== //\f\+#\d\+\|# HG changeset patch\)'
\ || (s:line1 =~ '^--- ' && s:line2 =~ '^+++ ')
\ || (s:line1 =~ '^\* looking for ' && s:line2 =~ '^\* comparing to ')
\ || (s:line1 =~ '^\*\*\* ' && s:line2 =~ '^--- ')
......
" Vim syntax file
" Language: CL
" (pronounced alphabetically, and NOT known as Clever)
" (CL was created by Multibase, http://www.mbase.com.au)
" Language: CL
" (pronounced alphabetically, and NOT known as Clever)
" (CL was created by Multibase, http://www.mbase.com.au)
" Filename extensions: *.ent
" *.eni
" *.eni
" Maintainer: Philip Uren <philuSPAX@ieee.org> Remove SPAX spam block
" Version: 4
" Last Change: May 11 2012
" Version: 5
" Last Change: Aug 16 2012
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
if version < 600
syntax clear
syntax clear
elseif exists("b:current_syntax")
finish
finish
endif
if version >= 600
setlocal iskeyword=@,48-57,_,-,
setlocal iskeyword=@,48-57,_,-,
else
set iskeyword=@,48-57,_,-,
set iskeyword=@,48-57,_,-,
endif
syn case ignore
......@@ -27,87 +27,87 @@ syn case ignore
syn sync lines=300
"If/else/elsif/endif and while/wend mismatch errors
syn match clifError "\<wend\>"
syn match clifError "\<elsif\>"
syn match clifError "\<else\>"
syn match clifError "\<endif\>"
syn match clifError "\<wend\>"
syn match clifError "\<elsif\>"
syn match clifError "\<else\>"
syn match clifError "\<endif\>"
syn match clSpaceError "\s\+$"
syn match clSpaceError "\s\+$"
" If and while regions
syn region clLoop transparent matchgroup=clWhile start="\<while\>" matchgroup=clWhile end="\<wend\>" contains=ALLBUT,clBreak,clProcedure
syn region clIf transparent matchgroup=clConditional start="\<if\>" matchgroup=clConditional end="\<endif\>" contains=ALLBUT,clBreak,clProcedure
syn region clLoop transparent matchgroup=clWhile start="\<while\>" matchgroup=clWhile end="\<wend\>" contains=ALLBUT,clBreak,clProcedure
syn region clIf transparent matchgroup=clConditional start="\<if\>" matchgroup=clConditional end="\<endif\>" contains=ALLBUT,clBreak,clProcedure
" Make those TODO notes and debugging stand out!
syn keyword clTodo contained TODO BUG DEBUG FIX
syn match clNeedsWork contained "NEED[S]*\s\s*WORK"
syn keyword clDebug contained debug
syn keyword clTodo contained TODO BUG DEBUG FIX
syn match clNeedsWork contained "NEED[S]*\s\s*WORK"
syn keyword clDebug contained debug
syn match clComment "#.*$" contains=clTodo,clNeedsWork
syn region clProcedure oneline start="^\s*[{}]" end="$"
syn match clInclude "^\s*include\s.*"
syn match clComment "#.*$" contains=clTodo,clNeedsWork,@Spell
syn region clProcedure oneline start="^\s*[{}]" end="$"
syn match clInclude "^\s*include\s.*"
" We don't put "debug" in the clSetOptions;
" we contain it in clSet so we can make it stand out.
syn keyword clSetOptions transparent aauto abort align convert E fill fnum goback hangup justify null_exit output rauto rawprint rawdisplay repeat skip tab trim
syn match clSet "^\s*set\s.*" contains=clSetOptions,clDebug
syn keyword clSetOptions transparent aauto abort align convert E fill fnum goback hangup justify null_exit output rauto rawprint rawdisplay repeat skip tab trim
syn match clSet "^\s*set\s.*" contains=clSetOptions,clDebug
syn match clPreProc "^\s*#P.*"
syn match clPreProc "^\s*#P.*"
syn keyword clConditional else elsif
syn keyword clWhile continue endloop
syn keyword clConditional else elsif
syn keyword clWhile continue endloop
" 'break' needs to be a region so we can sync on it above.
syn region clBreak oneline start="^\s*break" end="$"
syn region clBreak oneline start="^\s*break" end="$"
syn match clOperator "[!;|)(:.><+*=-]"
syn match clOperator "[!;|)(:.><+*=-]"
syn match clNumber "\<\d\+\(u\=l\=\|lu\|f\)\>"
syn match clNumber "\<\d\+\(u\=l\=\|lu\|f\)\>"
syn region clString matchgroup=clQuote start=+"+ end=+"+ skip=+\\"+
syn region clString matchgroup=clQuote start=+'+ end=+'+ skip=+\\'+
syn region clString matchgroup=clQuote start=+"+ end=+"+ skip=+\\"+ contains=@Spell
syn region clString matchgroup=clQuote start=+'+ end=+'+ skip=+\\'+ contains=@Spell
syn keyword clReserved ERROR EXIT INTERRUPT LOCKED LREPLY MODE MCOL MLINE MREPLY NULL REPLY V1 V2 V3 V4 V5 V6 V7 V8 V9 ZERO BYPASS GOING_BACK AAUTO ABORT ABORT ALIGN BIGE CONVERT FNUM GOBACK HANGUP JUSTIFY NEXIT OUTPUT RAUTO RAWDISPLAY RAWPRINT REPEAT SKIP TAB TRIM LCOUNT PCOUNT PLINES SLINES SCOLS MATCH LMATCH
syn keyword clReserved ERROR EXIT INTERRUPT LOCKED LREPLY MODE MCOL MLINE MREPLY NULL REPLY V1 V2 V3 V4 V5 V6 V7 V8 V9 ZERO BYPASS GOING_BACK AAUTO ABORT ABORT ALIGN BIGE CONVERT FNUM GOBACK HANGUP JUSTIFY NEXIT OUTPUT RAUTO RAWDISPLAY RAWPRINT REPEAT SKIP TAB TRIM LCOUNT PCOUNT PLINES SLINES SCOLS MATCH LMATCH
syn keyword clFunction asc asize chr name random slen srandom day getarg getcgi getenv lcase scat sconv sdel skey smult srep substr sword trim ucase match
syn keyword clFunction asc asize chr name random slen srandom day getarg getcgi getenv lcase scat sconv sdel skey smult srep substr sword trim ucase match
syn keyword clStatement clear clear_eol clear_eos close copy create unique with where empty define define ldefine delay_form delete escape exit_block exit_do exit_process field fork format get getfile getnext getprev goto head join maintain message no_join on_eop on_key on_exit on_delete openin openout openapp pause popenin popenout popenio print put range read redisplay refresh restart_block screen select sleep text unlock write and not or do
syn keyword clStatement clear clear_eol clear_eos close copy create unique with where empty define define ldefine delay_form delete escape exit_block exit_do exit_process field fork format get getfile getnext getprev goto head join maintain message no_join on_eop on_key on_exit on_delete openin openout openapp pause popenin popenout popenio print put range read redisplay refresh restart_block screen select sleep text unlock write and not or do
" Define the default highlighting.
" For version 5.7 and earlier: only when not done already
" For version 5.8 and later: only when an item doesn't have highlighting yet
if version >= 508 || !exists("did_cl_syntax_inits")
if version < 508
let did_cl_syntax_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
HiLink clifError Error
HiLink clSpaceError Error
HiLink clWhile Repeat
HiLink clConditional Conditional
HiLink clDebug Debug
HiLink clNeedsWork Todo
HiLink clTodo Todo
HiLink clComment Comment
HiLink clProcedure Procedure
HiLink clBreak Procedure
HiLink clInclude Include
HiLink clSetOption Statement
HiLink clSet Identifier
HiLink clPreProc PreProc
HiLink clOperator Operator
HiLink clNumber Number
HiLink clString String
HiLink clQuote Delimiter
HiLink clReserved Identifier
HiLink clFunction Function
HiLink clStatement Statement
delcommand HiLink
if version >= 508 || !exists("did_cl_syntax_inits")
if version < 508
let did_cl_syntax_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
HiLink clifError Error
HiLink clSpaceError Error
HiLink clWhile Repeat
HiLink clConditional Conditional
HiLink clDebug Debug
HiLink clNeedsWork Todo
HiLink clTodo Todo
HiLink clComment Comment
HiLink clProcedure Procedure
HiLink clBreak Procedure
HiLink clInclude Include
HiLink clSetOption Statement
HiLink clSet Identifier
HiLink clPreProc PreProc
HiLink clOperator Operator
HiLink clNumber Number
HiLink clString String
HiLink clQuote Delimiter
HiLink clReserved Identifier
HiLink clFunction Function
HiLink clStatement Statement
delcommand HiLink
endif
let b:current_syntax = "cl"
" vim: ts=8 sw=4
" vim: ts=8 sw=8
This diff is collapsed.
" Vim syntax file
" Language: hg (Mercurial) commit file
" Maintainer: Ken Takata <kentkt at csc dot jp>
" Last Change: 2012 Aug 2
" Last Change: 2012 Aug 23
" Filenames: hg-editor-*.txt
" License: VIM License
" URL: https://github.com/k-takata/hg-vim
......@@ -10,12 +10,12 @@ if exists("b:current_syntax")
finish
endif
syn match hgcommitComment "^HG:.*$"
syn match hgcommitUser "^HG: user: \zs.*$" contained containedin=hgcommitComment
syn match hgcommitBranch "^HG: branch \zs.*$" contained containedin=hgcommitComment
syn match hgcommitAdded "^HG: \zsadded .*$" contained containedin=hgcommitComment
syn match hgcommitChanged "^HG: \zschanged .*$" contained containedin=hgcommitComment
syn match hgcommitRemoved "^HG: \zsremoved .*$" contained containedin=hgcommitComment
syn match hgcommitComment "^HG:.*$" contains=@NoSpell
syn match hgcommitUser "^HG: user: \zs.*$" contains=@NoSpell contained containedin=hgcommitComment
syn match hgcommitBranch "^HG: branch \zs.*$" contains=@NoSpell contained containedin=hgcommitComment
syn match hgcommitAdded "^HG: \zsadded .*$" contains=@NoSpell contained containedin=hgcommitComment
syn match hgcommitChanged "^HG: \zschanged .*$" contains=@NoSpell contained containedin=hgcommitComment
syn match hgcommitRemoved "^HG: \zsremoved .*$" contains=@NoSpell contained containedin=hgcommitComment
hi def link hgcommitComment Comment
hi def link hgcommitUser String
......
......@@ -3,20 +3,20 @@
" Filename extensions: *.p (collides with Pascal),
" *.i (collides with assembler)
" *.w (collides with cweb)
" Maintainer: Philip Uren <philuSPAX@ieee.org> Remove SPAX spam block
" Contributors: Chris Ruprecht <chris@ruprecht.org>
" Philip Uren <philu@computer.org>
" Mikhail Kuperblum <mikhail@whasup.com>
" John Florian <jflorian@voyager.net>
" Version: 11
" Last Change: May 11 2012
" Maintainer: Philip Uren <philuSPAX@ieee.org> Remove SPAX spam block
" Contributors: Chris Ruprecht <chris@ruprecht.org>
" Philip Uren <philu@computer.org>
" Mikhail Kuperblum <mikhail@whasup.com>
" John Florian <jflorian@voyager.net>
" Version: 12
" Last Change: Aug 16 2012
" For version 5.x: Clear all syntax item
" For version 6.x: Quit when a syntax file was already loaded
if version < 600
syntax clear
syntax clear
elseif exists("b:current_syntax")
finish
finish
endif
let s:cpo_save = &cpo
......@@ -34,7 +34,7 @@ set expandtab
syn case ignore
" Progress Blocks of code and mismatched "end." errors.
syn match ProgressEndError "\<end\>"
syn match ProgressEndError "\<end\>"
syn region ProgressDoBlock transparent matchgroup=ProgressDo start="\<do\>" matchgroup=ProgressDo end="\<end\>" contains=ALLBUT,ProgressProcedure,ProgressFunction
syn region ProgressForBlock transparent matchgroup=ProgressFor start="\<for\>" matchgroup=ProgressFor end="\<end\>" contains=ALLBUT,ProgressProcedure,ProgressFunction
syn region ProgressRepeatBlock transparent matchgroup=ProgressRepeat start="\<repeat\>" matchgroup=ProgressRepeat end="\<end\>" contains=ALLBUT,ProgressProcedure,ProgressFunction
......@@ -44,20 +44,20 @@ syn region ProgressCaseBlock transparent matchgroup=ProgressCase start="\<case\>
" and they could go in ProgressReserved,
" but I found it more helpful to highlight them in a different color.
syn keyword ProgressConditional if else then when otherwise
syn keyword ProgressFor each where
syn keyword ProgressFor each where
" Make those TODO and debugging notes stand out!
syn keyword ProgressTodo contained TODO BUG FIX
syn keyword ProgressDebug contained DEBUG
syn keyword ProgressTodo contained TODO BUG FIX
syn keyword ProgressDebug contained DEBUG
syn keyword ProgressDebug debugger
" If you like to highlight the whole line of
" the start and end of procedures
" to make the whole block of code stand out:
syn match ProgressProcedure "^\s*procedure.*"
syn match ProgressProcedure "^\s*end\s\s*procedure.*"
syn match ProgressFunction "^\s*function.*"
syn match ProgressFunction "^\s*end\s\s*function.*"
syn match ProgressProcedure "^\s*procedure.*"
syn match ProgressProcedure "^\s*end\s\s*procedure.*"
syn match ProgressFunction "^\s*function.*"
syn match ProgressFunction "^\s*end\s\s*function.*"
" ... otherwise use this:
" syn keyword ProgressFunction procedure function
......@@ -99,14 +99,14 @@ syn keyword ProgressReserved window-maxim[ized] window-minim[ized] window-normal
" Strings. Handles embedded quotes.
" Note that, for some reason, Progress doesn't use the backslash, "\"
" as the escape character; it uses tilde, "~".
syn region ProgressString matchgroup=ProgressQuote start=+"+ end=+"+ skip=+\~'\|\~\~+
syn region ProgressString matchgroup=ProgressQuote start=+'+ end=+'+ skip=+\~'\|\~\~+
syn region ProgressString matchgroup=ProgressQuote start=+"+ end=+"+ skip=+\~'\|\~\~+ contains=@Spell
syn region ProgressString matchgroup=ProgressQuote start=+'+ end=+'+ skip=+\~'\|\~\~+ contains=@Spell
syn match ProgressIdentifier "\<[a-zA-Z_][a-zA-Z0-9_]*\>()"
" syn match ProgressDelimiter "()"
syn match ProgressMatrixDelimiter "[][]"
syn match ProgressMatrixDelimiter "[][]"
" If you prefer you can highlight the range:
"syn match ProgressMatrixDelimiter "[\d\+\.\.\d\+]"
......@@ -114,7 +114,7 @@ syn match ProgressNumber "\<\-\=\d\+\(u\=l\=\|lu\|f\)\>"
syn match ProgressByte "\$[0-9a-fA-F]\+"
" More values: Logicals, and Progress's unknown value, ?.
syn match ProgressNumber "?"
syn match ProgressNumber "?"
syn keyword ProgressNumber true false yes no
" If you don't like tabs:
......@@ -123,9 +123,9 @@ syn match ProgressShowTab "\t"
" If you don't like white space on the end of lines, uncomment this:
" syn match ProgressSpaceError "\s\+$"
syn region ProgressComment start="/\*" end="\*/" contains=ProgressComment,ProgressTodo,ProgressDebug
syn region ProgressInclude start="^[ ]*[{]" end="[}]" contains=ProgressPreProc,ProgressOperator,ProgressString,ProgressComment
syn region ProgressPreProc start="&" end="\>" contained
syn region ProgressComment start="/\*" end="\*/" contains=ProgressComment,ProgressTodo,ProgressDebug,@Spell
syn region ProgressInclude start="^[ ]*[{]" end="[}]" contains=ProgressPreProc,ProgressOperator,ProgressString,ProgressComment
syn region ProgressPreProc start="&" end="\>" contained
" This next line works reasonably well.
" syn match ProgressOperator "[!;|)(:.><+*=-]"
......@@ -277,7 +277,7 @@ syn keyword ProgressOperator write-fragment write-message write-processing-instr
syn keyword ProgressOperator xml-data-type xml-node-name xml-node-type xml-schema-pat[h] xml-suppress-namespace-processing y y-of year year-offset yes-no
syn keyword ProgressOperator yes-no-cancel
syn keyword ProgressType char[acter] int[eger] int64 dec[imal] log[ical] da[te] datetime datetime-tz
syn keyword ProgressType char[acter] int[eger] int64 dec[imal] log[ical] da[te] datetime datetime-tz
syn sync lines=800
......@@ -285,40 +285,40 @@ syn sync lines=800
" For version 5.7 and earlier: only when not done already
" For version 5.8 and later: only when an item doesn't have highlighting yet
if version >= 508 || !exists("did_progress_syntax_inits")
if version < 508
let did_progress_syntax_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
if version < 508
let did_progress_syntax_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
" The default methods for highlighting. Can be overridden later.
HiLink ProgressByte Number
HiLink ProgressCase Repeat
HiLink ProgressComment Comment
HiLink ProgressConditional Conditional
HiLink ProgressDebug Debug
HiLink ProgressDo Repeat
HiLink ProgressEndError Error
HiLink ProgressFor Repeat
HiLink ProgressFunction Procedure
HiLink ProgressIdentifier Identifier
HiLink ProgressInclude Include
HiLink ProgressMatrixDelimiter Identifier
HiLink ProgressNumber Number
HiLink ProgressOperator Operator
HiLink ProgressPreProc PreProc
HiLink ProgressProcedure Procedure
HiLink ProgressQuote Delimiter
HiLink ProgressRepeat Repeat
HiLink ProgressReserved Statement
HiLink ProgressSpaceError Error
HiLink ProgressString String
HiLink ProgressTodo Todo
HiLink ProgressType Statement
HiLink ProgressShowTab Error
" The default methods for highlighting. Can be overridden later.
HiLink ProgressByte Number
HiLink ProgressCase Repeat
HiLink ProgressComment Comment
HiLink ProgressConditional Conditional
HiLink ProgressDebug Debug
HiLink ProgressDo Repeat
HiLink ProgressEndError Error
HiLink ProgressFor Repeat
HiLink ProgressFunction Procedure
HiLink ProgressIdentifier Identifier
HiLink ProgressInclude Include
HiLink ProgressMatrixDelimiter Identifier
HiLink ProgressNumber Number
HiLink ProgressOperator Operator
HiLink ProgressPreProc PreProc
HiLink ProgressProcedure Procedure
HiLink ProgressQuote Delimiter
HiLink ProgressRepeat Repeat
HiLink ProgressReserved Statement
HiLink ProgressSpaceError Error
HiLink ProgressString String
HiLink ProgressTodo Todo
HiLink ProgressType Statement
HiLink ProgressShowTab Error
delcommand HiLink
delcommand HiLink
endif
let b:current_syntax = "progress"
......@@ -326,4 +326,4 @@ let b:current_syntax = "progress"
let &cpo = s:cpo_save
unlet s:cpo_save
" vim: ts=8 sw=4
" vim: ts=8 sw=8
" Vim tutor support file
" Author: Eduardo F. Amatria <eferna1@platea.pntic.mec.es>
" Maintainer: Bram Moolenaar
" Last Change: 2008 Jul 21
" Last Change: 2012 Sep 21
" This Vim script is used for detecting if a translation of the
" tutor file exist, i.e., a tutor.xx file, where xx is the language.
......@@ -72,14 +72,20 @@ if s:ext =~? '\.ko'
endif
endif
" The Chinese tutor is available in two encodings, guess which one to use
" The Chinese tutor is available in three encodings, guess which one to use
" This segment is from the above lines and modified by
" Mendel L Chan <beos@turbolinux.com.cn> for Chinese vim tutorial
" When 'encoding' is utf-8, choose between China (simplified) and Taiwan
" (traditional) based on the language, suggested by Alick Zhao.
if s:ext =~? '\.zh'
if &enc =~ 'big5\|cp950'
let s:ext = ".zh.big5"
elseif &enc != 'utf-8'
let s:ext = ".zh.euc"
elseif s:ext =~? 'zh_tw' || (exists("s:lang") && s:lang =~? 'zh_tw')
let s:ext = ".zh_tw"
else
let s:ext = ".zh_cn"
endif
endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment