summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--runtime/doc/autocmd.txt5
-rw-r--r--runtime/doc/diff.txt12
-rw-r--r--runtime/doc/eval.txt13
-rw-r--r--runtime/doc/hebrew.txt2
-rw-r--r--runtime/doc/if_pyth.txt20
-rw-r--r--runtime/doc/indent.txt4
-rw-r--r--runtime/doc/intro.txt4
-rw-r--r--runtime/doc/todo.txt75
-rw-r--r--runtime/doc/usr_41.txt2
-rw-r--r--runtime/doc/visual.txt2
-rw-r--r--runtime/filetype.vim6
-rw-r--r--runtime/ftplugin/changelog.vim6
-rw-r--r--runtime/ftplugin/zimbu.vim49
-rw-r--r--runtime/indent/zimbu.vim4
-rw-r--r--runtime/scripts.vim5
-rw-r--r--runtime/syntax/cl.vim136
-rw-r--r--runtime/syntax/css.vim362
-rw-r--r--runtime/syntax/hgcommit.vim14
-rw-r--r--runtime/syntax/progress.vim116
-rw-r--r--runtime/tutor/tutor.vim10
-rw-r--r--runtime/tutor/tutor.zh_cn.utf-8851
-rw-r--r--runtime/tutor/tutor.zh_tw.utf-8852
22 files changed, 2261 insertions, 289 deletions
diff --git a/runtime/doc/autocmd.txt b/runtime/doc/autocmd.txt
index a8bff07c56..32cad6764b 100644
--- a/runtime/doc/autocmd.txt
+++ b/runtime/doc/autocmd.txt
@@ -1,4 +1,4 @@
-*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 --git a/runtime/doc/diff.txt b/runtime/doc/diff.txt
index 0e03a57fe1..036dc5e136 100644
--- a/runtime/doc/diff.txt
+++ b/runtime/doc/diff.txt
@@ -1,4 +1,4 @@
-*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.
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt
index 2ae65ff82b..12ea9c897e 100644
--- a/runtime/doc/eval.txt
+++ b/runtime/doc/eval.txt
@@ -1,4 +1,4 @@
-*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, @*)
diff --git a/runtime/doc/hebrew.txt b/runtime/doc/hebrew.txt
index 589d12c33f..8f264e67e2 100644
--- a/runtime/doc/hebrew.txt
+++ b/runtime/doc/hebrew.txt
@@ -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.
diff --git a/runtime/doc/if_pyth.txt b/runtime/doc/if_pyth.txt
index 4bdacf66f2..92840d40ec 100644
--- a/runtime/doc/if_pyth.txt
+++ b/runtime/doc/if_pyth.txt
@@ -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.
diff --git a/runtime/doc/indent.txt b/runtime/doc/indent.txt
index ce02178d70..6a43896c00 100644
--- a/runtime/doc/indent.txt
+++ b/runtime/doc/indent.txt
@@ -1,4 +1,4 @@
-*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).
diff --git a/runtime/doc/intro.txt b/runtime/doc/intro.txt
index 6682ba6aa7..c643ab8dbf 100644
--- a/runtime/doc/intro.txt
+++ b/runtime/doc/intro.txt
@@ -1,4 +1,4 @@
-*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
diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt
index e1efea17a5..e3e6bbbffc 100644
--- a/runtime/doc/todo.txt
+++ b/runtime/doc/todo.txt
@@ -1,4 +1,4 @@
-*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)
diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt
index 77f7d1c350..1a4ae3d1b3 100644
--- a/runtime/doc/usr_41.txt
+++ b/runtime/doc/usr_41.txt
@@ -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: >
diff --git a/runtime/doc/visual.txt b/runtime/doc/visual.txt
index 6d85075efa..6905c21803 100644
--- a/runtime/doc/visual.txt
+++ b/runtime/doc/visual.txt
@@ -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
diff --git a/runtime/filetype.vim b/runtime/filetype.vim
index 45cf6309a4..6f6bc812ad 100644
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -1,7 +1,7 @@
" 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")
diff --git a/runtime/ftplugin/changelog.vim b/runtime/ftplugin/changelog.vim
index dafcbe20ff..ee83c79175 100644
--- a/runtime/ftplugin/changelog.vim
+++ b/runtime/ftplugin/changelog.vim
@@ -1,7 +1,7 @@
" 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)
diff --git a/runtime/ftplugin/zimbu.vim b/runtime/ftplugin/zimbu.vim
index 85b57f464f..ff281202e0 100644
--- a/runtime/ftplugin/zimbu.vim
+++ b/runtime/ftplugin/zimbu.vim
@@ -1,7 +1,7 @@
" 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")
diff --git a/runtime/indent/zimbu.vim b/runtime/indent/zimbu.vim
index 8df0eebe6f..9565b10843 100644
--- a/runtime/indent/zimbu.vim
+++ b/runtime/indent/zimbu.vim
@@ -1,7 +1,7 @@
" 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\>\)'
diff --git a/runtime/scripts.vim b/runtime/scripts.vim
index 75275785fb..bb5a492512 100644
--- a/runtime/scripts.vim
+++ b/runtime/scripts.vim
@@ -1,7 +1,7 @@
" 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 =~ '^--- ')
diff --git a/runtime/syntax/cl.vim b/runtime/syntax/cl.vim
index 343d2601d1..ccea2ee5ce 100644
--- a/runtime/syntax/cl.vim
+++ b/runtime/syntax/cl.vim
@@ -1,25 +1,25 @@
" 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 s