Updated runtime files.
diff --git a/runtime/syntax/abap.vim b/runtime/syntax/abap.vim
index 18d3b0f..8f7306d 100644
--- a/runtime/syntax/abap.vim
+++ b/runtime/syntax/abap.vim
@@ -1,8 +1,9 @@
" Vim ABAP syntax file
" Language: SAP - ABAP/R4
-" Revision: 1.0
-" Maintainer: Marius Piedallu van Wyk <marius@e.co.za>
-" Last Change: 2006 Apr 13
+" Revision: 2.0
+" Maintainer: Marius Piedallu van Wyk <lailoken@gmail.com>
+" Last Change: 2012 Oct 12
+" Comment: Thanks to EPI-USE Labs for all your assistance. :)
" For version < 6.0: Clear all syntax items
" For version >= 6.0: Quit when a syntax file was already loaded
@@ -16,73 +17,126 @@
syn case ignore
" Symbol Operators
-syn match abapSymbolOperator "[+\-/=<>$]"
-syn match abapSymbolOperator "\*"
-syn match abapSymbolOperator "[<>]="
-syn match abapSymbolOperator "<>"
-syn match abapSymbolOperator "\*\*"
-syn match abapSymbolOperator "[()]"
-syn match abapSymbolOperator "[:,\.]"
+syn match abapSymbolOperator "\W+\W"
+syn match abapSymbolOperator "\W-\W"
+syn match abapSymbolOperator "\W/\W"
+syn match abapSymbolOperator "\W%\W"
+syn match abapSymbolOperator "\W=\W"
+syn match abapSymbolOperator "\W<\W"
+syn match abapSymbolOperator "\W>\W"
+syn match abapSymbolOperator "\W\*\W"
+syn match abapSymbolOperator "\W[<>]=\W"
+syn match abapSymbolOperator "\W<>\W"
+syn match abapSymbolOperator "\W\*\*\W"
+syn match abapSymbolOperator "\[\]"
+syn match abapSymbolOperator "->\*\?"
+syn match abapSymbolOperator "=>"
+syn match abapSymbolOperator "[()~:,\.&$]"
" Literals
-syn region abapString matchgroup=abapString start="'" end="'" contains=abapStringEscape
-syn match abapStringEscape contained "''"
+syn region abapCharString matchgroup=abapCharString start="'" end="'" contains=abapCharStringEscape
+syn match abapCharStringEscape contained "''"
-syn match abapNumber "-\=\<\d\+\>"
+syn region abapString matchgroup=abapString start="`" end="`" contains=abapStringEscape
+syn match abapStringEscape contained "``"
+
+syn match abapNumber "\-\=\<\d\+\>"
syn region abapHex matchgroup=abapHex start="X'" end="'"
if version >= 600
- setlocal iskeyword=-,48-57,_,A-Z,a-z
+ setlocal iskeyword=48-57,_,A-Z,a-z,/
else
- set iskeyword=-,48-57,_,A-Z,a-z
+ set iskeyword=48-57,_,A-Z,a-z,/
endif
+syn match abapNamespace "/\w\+/"
+
+" multi-word statements
+syn match abapComplexStatement "\(WITH\W\+\(HEADER\W\+LINE\|FRAME\|KEY\)\|WITH\)"
+syn match abapComplexStatement "NO\W\+STANDARD\W\+PAGE\W\+HEADING"
+syn match abapComplexStatement "\(EXIT\W\+FROM\W\+STEP\W\+LOOP\|EXIT\)"
+syn match abapComplexStatement "\(BEGIN\W\+OF\W\+\(BLOCK\|LINE\)\|BEGIN\W\+OF\)"
+syn match abapComplexStatement "\(END\W\+OF\W\+\(BLOCK\|LINE\)\|END\W\+OF\)"
+syn match abapComplexStatement "NO\W\+INTERVALS"
+syn match abapComplexStatement "RESPECTING\W\+BLANKS"
+syn match abapComplexStatement "SEPARATED\W\+BY"
+syn match abapComplexStatement "\(USING\W\+\(EDIT\W\+MASK\)\|USING\)"
+syn match abapComplexStatement "\(WHERE\W\+\(LINE\)\)"
+syn match abapComplexStatement "RADIOBUTTON\W\+GROUP"
+syn match abapComplexStatement "REF\W\+TO"
+syn match abapComplexStatement "\(PUBLIC\|PRIVATE\|PROTECTED\)\(\W\+SECTION\)\?"
+syn match abapComplexStatement "DELETING\W\+\(TRAILING\|LEADING\)"
+syn match abapComplexStatement "\(ALL\W\+OCCURRENCES\)\|\(\(FIRST\|LAST\)\W\+OCCURRENCE\)"
+syn match abapComplexStatement "INHERITING\W\+FROM"
+
+" hyphenated-word statements
+syn match abapComplexStatement "LINE-COUNT"
+syn match abapComplexStatement "ADD-CORRESPONDING"
+syn match abapComplexStatement "AUTHORITY-CHECK"
+syn match abapComplexStatement "BREAK-POINT"
+syn match abapComplexStatement "CLASS-DATA"
+syn match abapComplexStatement "CLASS-METHODS"
+syn match abapComplexStatement "CLASS-METHOD"
+syn match abapComplexStatement "DIVIDE-CORRESPONDING"
+syn match abapComplexStatement "EDITOR-CALL"
+syn match abapComplexStatement "END-OF-DEFINITION"
+syn match abapComplexStatement "END-OF-PAGE"
+syn match abapComplexStatement "END-OF-SELECTION"
+syn match abapComplexStatement "FIELD-GROUPS"
+syn match abapComplexStatement "FIELD-SYMBOLS"
+syn match abapComplexStatement "FUNCTION-POOL"
+syn match abapComplexStatement "MOVE-CORRESPONDING"
+syn match abapComplexStatement "MULTIPLY-CORRESPONDING"
+syn match abapComplexStatement "NEW-LINE"
+syn match abapComplexStatement "NEW-PAGE"
+syn match abapComplexStatement "NEW-SECTION"
+syn match abapComplexStatement "PRINT-CONTROL"
+syn match abapComplexStatement "RP-PROVIDE-FROM-LAST"
+syn match abapComplexStatement "SELECT-OPTIONS"
+syn match abapComplexStatement "SELECTION-SCREEN"
+syn match abapComplexStatement "START-OF-SELECTION"
+syn match abapComplexStatement "SUBTRACT-CORRESPONDING"
+syn match abapComplexStatement "SYNTAX-CHECK"
+syn match abapComplexStatement "SYNTAX-TRACE"
+syn match abapComplexStatement "TOP-OF-PAGE"
+syn match abapComplexStatement "TYPE-POOL"
+syn match abapComplexStatement "TYPE-POOLS"
+syn match abapComplexStatement "LINE-SIZE"
+syn match abapComplexStatement "LINE-COUNT"
+syn match abapComplexStatement "MESSAGE-ID"
+syn match abapComplexStatement "DISPLAY-MODE"
+syn match abapComplexStatement "READ\(-ONLY\)\?"
+
" ABAP statements
-syn keyword abapStatement ADD ADD-CORRESPONDING ASSIGN AT AUTHORITY-CHECK
-syn keyword abapStatement BACK BREAK-POINT
-syn keyword abapStatement CALL CASE CHECK CLEAR CLOSE CNT COLLECT COMMIT COMMUNICATION COMPUTE CONCATENATE CONDENSE CONSTANTS CONTINUE CONTROLS CONVERT CREATE CURRENCY
-syn keyword abapStatement DATA DEFINE DELETE DESCRIBE DETAIL DIVIDE DIVIDE-CORRESPONDING DO
-syn keyword abapStatement EDITOR-CALL ELSE ELSEIF END-OF-DEFINITION END-OF-PAGE END-OF-SELECTION ENDAT ENDCASE ENDDO ENDEXEC ENDFORM ENDFUNCTION ENDIF ENDIFEND ENDLOOP ENDMODULE ENDON ENDPROVIDE ENDSELECT ENDWHILE EXEC EXPORT EXPORTING EXTRACT
-syn keyword abapStatement FETCH FIELD-GROUPS FIELD-SYMBOLS FIELDS FORM FORMAT FREE FUNCTION FUNCTION-POOL
+syn keyword abapStatement ADD ALIAS ALIASES ASSERT ASSIGN ASSIGNING AT
+syn keyword abapStatement BACK BOUND
+syn keyword abapStatement CALL CASE CATCH CHECK CLASS CLEAR CLOSE CNT COLLECT COMMIT COMMUNICATION COMPUTE CONCATENATE CONDENSE CONSTANTS CONTINUE CONTROLS CONVERT CREATE CURRENCY
+syn keyword abapStatement DATA DEFINE DEFINITION DEFERRED DELETE DESCRIBE DETAIL DIVIDE DO
+syn keyword abapStatement ELSE ELSEIF ENDAT ENDCASE ENDCLASS ENDDO ENDEXEC ENDFORM ENDFUNCTION ENDIF ENDIFEND ENDINTERFACE ENDLOOP ENDMETHOD ENDMODULE ENDON ENDPROVIDE ENDSELECT ENDTRY ENDWHILE EVENT EVENTS EXEC EXIT EXPORT EXPORTING EXTRACT
+syn keyword abapStatement FETCH FIELDS FORM FORMAT FREE FROM FUNCTION
syn keyword abapStatement GENERATE GET
syn keyword abapStatement HIDE
-syn keyword abapStatement IF IMPORT IMPORTING INDEX INFOTYPES INITIALIZATION INPUT INSERT
-syn keyword abapStatement LEAVE LIKE LOAD LOCAL LOOP
-syn keyword abapStatement MESSAGE MODIFY MODULE MOVE MOVE-CORRESPONDING MULTIPLY MULTIPLY-CORRESPONDING
-syn keyword abapStatement NEW-LINE NEW-PAGE NEW-SECTION
-syn keyword abapStatement ON OVERLAY
-syn keyword abapStatement PACK PARAMETERS PERFORM POSITION PRINT-CONTROL PROGRAM PROVIDE PUT
-syn keyword abapStatement RAISE RANGES READ RECEIVE REFRESH REJECT REPLACE REPORT RESERVE RESTORE ROLLBACK RP-PROVIDE-FROM-LAST
-syn keyword abapStatement SCAN SCROLL SEARCH SELECT SELECT-OPTIONS SELECTION-SCREEN SET SHIFT SKIP SORT SPLIT START-OF-SELECTION STATICS STOP SUBMIT SUBTRACT SUBTRACT-CORRESPONDING SUM SUMMARY SUPPRESS SYNTAX-CHECK SYNTAX-TRACE
-syn keyword abapStatement TABLES TOP-OF-PAGE TRANSFER TRANSLATE TYPE TYPE-POOL TYPE-POOLS TYPES
-syn keyword abapStatement UNPACK UPDATE
+syn keyword abapStatement IF IMPORT IMPORTING INDEX INFOTYPES INITIAL INITIALIZATION INTERFACE INTERFACES INPUT INSERT IMPLEMENTATION IS
+syn keyword abapStatement LEAVE LIKE LINE LOAD LOCAL LOOP
+syn keyword abapStatement MESSAGE METHOD METHODS MODIFY MODULE MOVE MULTIPLY
+syn keyword abapStatement ON OVERLAY OPTIONAL OTHERS
+syn keyword abapStatement PACK PARAMETERS PERFORM POSITION PROGRAM PROVIDE PUT
+syn keyword abapStatement RAISE RANGES RECEIVE REDEFINITION REFERENCE REFRESH REJECT REPLACE REPORT RESERVE RESTORE RETURNING ROLLBACK
+syn keyword abapStatement SCAN SCROLL SEARCH SELECT SET SHIFT SKIP SORT SORTED SPLIT STANDARD STATICS STEP STOP SUBMIT SUBTRACT SUM SUMMARY SUPPRESS
+syn keyword abapStatement TABLES TIMES TRANSFER TRANSLATE TRY TYPE TYPES
+syn keyword abapStatement UNASSIGN ULINE UNPACK UPDATE
syn keyword abapStatement WHEN WHILE WINDOW WRITE
" More statemets
syn keyword abapStatement OCCURS STRUCTURE OBJECT PROPERTY
syn keyword abapStatement CASTING APPEND RAISING VALUE COLOR
-syn keyword abapStatement LINE-SIZE LINE-COUNT MESSAGE-ID
-syn keyword abapStatement CHANGING EXCEPTIONS DEFAULT CHECKBOX COMMENT
-syn keyword abapStatement ID NUMBER FOR DISPLAY-MODE TITLE OUTPUT
-
-" More multi-word statements
-syn match abapStatement "\(\W\|^\)\(WITH\W\+\(HEADER\W\+LINE\|FRAME\|KEY\)\|WITH\)\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)NO\W\+STANDARD\W\+PAGE\W\+HEADING\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)\(EXIT\W\+FROM\W\+STEP\W\+LOOP\|EXIT\)\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)\(BEGIN\W\+OF\W\+\(BLOCK\|LINE\)\|BEGIN\W\+OF\)\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)\(END\W\+OF\W\+\(BLOCK\|LINE\)\|END\W\+OF\)\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)IS\W\+INITIAL\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)NO\W\+INTERVALS\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)SEPARATED\W\+BY\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)\(USING\W\+\(EDIT\W\+MASK\)\|USING\)\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)\(WHERE\W\+\(LINE\)\)\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)RADIOBUTTON\W\+GROUP\(\W\|$\)"ms=s+1,me=e-1
-syn match abapStatement "\(\W\|^\)REF\W\+TO\(\W\|$\)"ms=s+1,me=e-1
+syn keyword abapStatement CHANGING EXCEPTION EXCEPTIONS DEFAULT CHECKBOX COMMENT
+syn keyword abapStatement ID NUMBER FOR TITLE OUTPUT
" Special ABAP specific tables:
syn match abapSpecial "\(\W\|^\)\(sy\|\(p\|pa\)\d\d\d\d\|t\d\d\d.\|innnn\)\(\W\|$\)"ms=s+1,me=e-1
syn match abapSpecialTables "\(sy\|\(p\|pa\)\d\d\d\d\|t\d\d\d.\|innnn\)-"me=e-1 contained
-syn match abapSpecial "\(\W\|^\)\w\+-\(\w\+-\w\+\|\w\+\)"ms=s+1 contains=abapSpecialTables
+syn match abapSpecial "\(\W\|^\)\w\+-\(\w\+-\w\+\|\w\+\)"ms=s+1 contains=abapSpecialTables,abapStatement,abapComplexStatement
" Pointer
syn match abapSpecial "<\w\+>"
@@ -94,7 +148,7 @@
syn region abapInclude start="include" end="." contains=abapComment
" Types
-syn keyword abapTypes c n i p f d t x
+syn keyword abapTypes c n i p f d t x string xstring decfloat16 decfloat34
" Atritmitic operators
syn keyword abapOperator abs sign ceil floor trunc frac acos asin atan cos sin tan
@@ -107,7 +161,7 @@
syn keyword abapOperator lines
" Table operators (SELECT operators)
-syn keyword abapOperator INTO FROM WHERE GROUP BY HAVING ORDER BY SINGLE
+syn keyword abapOperator INTO WHERE GROUP BY HAVING ORDER BY SINGLE
syn keyword abapOperator APPENDING CORRESPONDING FIELDS OF TABLE
syn keyword abapOperator LEFT RIGHT OUTER INNER JOIN AS CLIENT SPECIFIED BYPASSING BUFFER UP TO ROWS CONNECTING
syn keyword abapOperator EQ NE LT LE GT GE NOT AND OR XOR IN LIKE BETWEEN
@@ -119,6 +173,7 @@
syn region abapComment start="^\*" end="$" contains=abapTodo
syn match abapComment "\".*" contains=abapTodo
syn keyword abapTodo contained TODO NOTE
+syn match abapTodo "\#EC\W\+\w\+"
" Define the default highlighting.
" For version 5.7 and earlier: only when not done already
@@ -134,13 +189,18 @@
HiLink abapError Error
HiLink abapComment Comment
HiLink abapInclude Include
+ HiLink abapStatement Statement
+ HiLink abapComplexStatement Statement
HiLink abapSpecial Special
+ HiLink abapNamespace Special
HiLink abapSpecialTables PreProc
HiLink abapSymbolOperator abapOperator
HiLink abapOperator Operator
- HiLink abapStatement Statement
+ HiLink abapCharString String
HiLink abapString String
HiLink abapFloat Float
+ HiLink abapTypes Type
+ HiLink abapSymbol Structure
HiLink abapNumber Number
HiLink abapHex Number
diff --git a/runtime/syntax/aptconf.vim b/runtime/syntax/aptconf.vim
index 40fe92b..dabfe56 100644
--- a/runtime/syntax/aptconf.vim
+++ b/runtime/syntax/aptconf.vim
@@ -1,7 +1,7 @@
" Vim syntax file
" Language: APT config file
" Maintainer: Yann Amar <quidame@poivron.org>
-" Last Change: 2012 Oct 05
+" Last Change: 2012 Oct 06
" For version 5.x: Clear all syntax items
" For version 6.x and 7.x: Quit when a syntax file was already loaded
@@ -17,6 +17,7 @@
let s:cpo_save = &cpo
set cpo&vim
+
" Errors:
" Catch all that is not overridden by next rules/items:
syn match aptconfError display '[^[:blank:]]'
@@ -490,4 +491,3 @@
let &cpo = s:cpo_save
unlet s:cpo_save
-
diff --git a/runtime/syntax/css.vim b/runtime/syntax/css.vim
index df7f2a1..2b14bf2 100644
--- a/runtime/syntax/css.vim
+++ b/runtime/syntax/css.vim
@@ -5,7 +5,8 @@
" Yeti (Add full CSS2, HTML4 support)
" Nikolai Weibull (Add CSS2 support)
" Maintainer: Jules Wang <w.jq0722@gmail.com>
-" Last Change: 2012 Oct 05
+" URL: https://github.com/JulesWang/css.vim
+" Last Change: 2012 Dec 15
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
@@ -90,7 +91,37 @@
syn match cssUnicodeRange contained "U+[0-9A-Fa-f?]\+"
syn match cssUnicodeRange contained "U+\x\+-\x\+"
+" The 16 basic color names
syn keyword cssColor contained aqua black blue fuchsia gray green lime maroon navy olive purple red silver teal yellow
+
+" 130 more color names
+syn keyword cssColor contained aliceblue antiquewhite aquamarine azure
+syn keyword cssColor contained beige bisque blanchedalmond blueviolet brown burlywood
+syn keyword cssColor contained cadetblue chartreuse chocolate coral cornflowerblue cornsilk crimson cyan
+syn match cssColor contained /dark\(blue\|cyan\|goldenrod\|gray\|green\|grey\|khaki\)/
+syn match cssColor contained /dark\(magenta\|olivegreen\|orange\|orchid\|red\|salmon\|seagreen\)/
+syn match cssColor contained /darkslate\(blue\|gray\|grey\)/
+syn match cssColor contained /dark\(turquoise\|violet\)/
+syn keyword cssColor contained deeppink deepskyblue dimgray dimgrey dodgerblue firebrick
+syn keyword cssColor contained floralwhite forestgreen gainsboro ghostwhite gold
+syn keyword cssColor contained goldenrod greenyellow grey honeydew hotpink
+syn keyword cssColor contained indianred indigo ivory khaki lavender lavenderblush lawngreen
+syn keyword cssColor contained lemonchiffon limegreen linen magenta
+syn match cssColor contained /light\(blue\|coral\|cyan\|goldenrodyellow\|gray\|green\)/
+syn match cssColor contained /light\(grey\|pink\|salmon\|seagreen\|skyblue\|yellow\)/
+syn match cssColor contained /light\(slategray\|slategrey\|steelblue\)/
+syn match cssColor contained /medium\(aquamarine\|blue\|orchid\|purple\|seagreen\)/
+syn match cssColor contained /medium\(slateblue\|springgreen\|turquoise\|violetred\)/
+syn keyword cssColor contained midnightblue mintcream mistyrose moccasin navajowhite
+syn keyword cssColor contained oldlace olivedrab orange orangered orchid
+syn match cssColor contained /pale\(goldenrod\|green\|turquoise\|violetred\)/
+syn keyword cssColor contained papayawhip peachpuff peru pink plum powderblue
+syn keyword cssColor contained rosybrown royalblue saddlebrown salmon sandybrown
+syn keyword cssColor contained seagreen seashell sienna skyblue slateblue
+syn keyword cssColor contained slategray slategrey snow springgreen steelblue tan
+syn keyword cssColor contained thistle tomato turquoise violet wheat
+syn keyword cssColor contained whitesmoke yellowgreen
+
" FIXME: These are actually case-insentivie too, but (a) specs recommend using
" mixed-case (b) it's hard to highlight the word `Background' correctly in
" all situations
diff --git a/runtime/syntax/debcontrol.vim b/runtime/syntax/debcontrol.vim
index 7875b3c..74b41b2 100644
--- a/runtime/syntax/debcontrol.vim
+++ b/runtime/syntax/debcontrol.vim
@@ -3,7 +3,7 @@
" Maintainer: Debian Vim Maintainers <pkg-vim-maintainers@lists.alioth.debian.org>
" Former Maintainers: Gerfried Fuchs <alfie@ist.org>
" Wichert Akkerman <wakkerma@debian.org>
-" Last Change: 2011 Dec 09
+" Last Change: 2012 Jun 06
" URL: http://anonscm.debian.org/hg/pkg-vim/vim/raw-file/unstable/runtime/syntax/debcontrol.vim
" Standard syntax initialization
@@ -45,7 +45,7 @@
syn match debcontrolEmail "<.\{-}>"
" #-Comments
-syn match debcontrolComment "^#.*$"
+syn match debcontrolComment "^#.*$" contains=@Spell
syn case ignore
@@ -69,6 +69,7 @@
" Catch-all for the other legal fields
syn region debcontrolField start="^\%(\%(XSBC-Original-\)\=Maintainer\|Standards-Version\|Essential\|Bugs\|Origin\|X[SB]-Python-Version\|\%(XS-\)\=Vcs-Mtn\):" end="$" contains=debcontrolKey,debcontrolVariable,debcontrolEmail oneline
syn region debcontrolMultiField start="^\%(Build-\%(Conflicts\|Depends\)\%(-Indep\)\=\|\%(Pre-\)\=Depends\|Recommends\|Suggests\|Provides\|Replaces\|Conflicts\|Enhances\|Breaks\|Uploaders\|Description\):" skip="^ " end="^$"me=s-1 end="^[^ #]"me=s-1 contains=debcontrolKey,debcontrolEmail,debcontrolVariable,debcontrolComment
+syn region debcontrolMultiFieldSpell start="^\%(Description\):" skip="^ " end="^$"me=s-1 end="^[^ #]"me=s-1 contains=debcontrolKey,debcontrolEmail,debcontrolVariable,debcontrolComment,@Spell
" Associate our matches and regions with pretty colours
if version >= 508 || !exists("did_debcontrol_syn_inits")
diff --git a/runtime/syntax/rexx.vim b/runtime/syntax/rexx.vim
index b4d0732..ef698a5 100644
--- a/runtime/syntax/rexx.vim
+++ b/runtime/syntax/rexx.vim
@@ -1,14 +1,8 @@
" Vim syntax file
" Language: Rexx
" Maintainer: Thomas Geulig <geulig@nentec.de>
-" Last Change: 2005 Dez 9, added some <http://www.ooRexx.org>-coloring,
-" line comments, do *over*, messages, directives,
-" highlighting classes, methods, routines and requires
-" 2007 Oct 17, added support for new ooRexx 3.2 features
-" Rony G. Flatscher <rony.flatscher@wu-wien.ac.at>
-"
+" Last Change: 2012 Sep 14, added support for new ooRexx 4.0 features
" URL: http://www.geulig.de/vim/rexx.vim
-"
" Special Thanks to Dan Sharp <dwsharp@hotmail.com> and Rony G. Flatscher
" <Rony.Flatscher@wu-wien.ac.at> for comments and additions
@@ -54,7 +48,7 @@
syn match rexxRegularCallSignal contained "\<\(call\|signal\)\s\(\s*on\>\|\s*off\>\)\@!\(\k\+\ze\|\ze(\)\(\s*\|;\|$\|(\)"
syn region rexxLabel contained start="\<\(call\|signal\)\>\s*\zs\(\k*\|(\)" end="\ze\(\s*\|;\|$\|(\)" containedin=rexxRegularCallSignal
-syn match rexxExceptionHandling contained "\<\(call\|signal\)\>\s\+\<\(on\|off\)\>.*\(;\|$\)"
+syn match rexxExceptionHandling contained "\<\(call\|signal\)\>\s\+\<\(on\|off\)\>.*\(;\|$\)" contains=rexxComment
" hilite label given after keyword "name"
syn match rexxLabel "name\s\+\zs\k\+\ze" containedin=rexxExceptionHandling
@@ -74,13 +68,14 @@
syn match rexxLoopKeywords "\<\(to\|by\|for\|until\|while\|over\)\>" containedin=doLoopSelectLabelRegion
" must be after Conditional phrases!
-syn match doLoopSelectLabelRegion "\<\(do\|loop\|select\)\>\s\+\(label\s\+\)\?\(\s\+\k\+\s\+\zs\<over\>\)\?\k*\(\s\+forever\)\?\(\s\|;\|$\)"
+syn match doLoopSelectLabelRegion "\<\(do\|loop\|select\)\>\s\+\(label\s\+\)\?\(\s\+\k\+\s\+\zs\<over\>\)\?\k*\(\s\+forever\)\?\(\s\|;\|$\)" contains=doLoopSelectLabelRegion,rexxStartValueAssignment,rexxLoopKeywords
" color label's name
syn match rexxLabel2 "\<\(do\|loop\|select\)\>\s\+label\s\+\zs\k*\ze" containedin=doLoopSelectLabelRegion
" make sure control variable is normal
-syn match rexxControlVariable "\<\(do\|loop\)\>\(\s\+label\s\+\k*\)\?\s\+\zs.*\ze\s\+\<over\>" containedin=doLoopSelectLabelRegion
+" TODO: re-activate ?
+"rgf syn match rexxControlVariable "\<\(do\|loop\)\>\(\s\+label\s\+\k*\)\?\s\+\zs.*\ze\s\+\<over\>" containedin=doLoopSelectLabelRegion
" make sure control variable assignment is normal
syn match rexxStartValueAssignment "\<\(do\|loop\)\>\(\s\+label\s\+\k*\)\?\s\+\zs.*\ze\(=.*\)\?\s\+\<to\>" containedin=doLoopSelectLabelRegion
@@ -96,7 +91,8 @@
syn match rexxTrace "\(^\|;\|:\)\s*\<trace\>\s\+\<\K\k*\>"
" Raise statement
-syn match rexxRaise "\(^\|;\|:\)\s\+\<raise\>\s*\<\(propagate\|error\|failure\|syntax\|user\)\>\?" contains=rexxRaise2
+" syn match rexxRaise "\(^\|;\|:\)\s\+\<raise\>\s*\<\(propagate\|error\|failure\|syntax\|user\)\>\?" contains=rexxRaise2
+syn match rexxRaise "\(^\|;\|:\)\s*\<raise\>\s*\<\(propagate\|error\|failure\|syntax\|user\)\>\?" contains=rexxRaise2
syn match rexxRaise2 "\<\(additional\|array\|description\|exit\|propagate\|return\)\>" containedin=rexxRaise
" Forward statement
@@ -142,19 +138,36 @@
syn keyword rexxSpecialVariable .environment .error .input .local .methods .output .rs .stderr .stdin .stdout .stdque
" Constants
-syn keyword rexxConst .true .false .nil .endOfLine .line
+syn keyword rexxConst .true .false .nil .endOfLine .line .context
-syn match rexxNumber "\(-\|+\)\?\s*\zs\<\(\d\+\.\?\|\d*\.\d\+\(E\(+\|-\)\d\{2,2}\)\?\)\?\>"
+" Rexx numbers
+" int like number
+syn match rexxNumber '\d\+' contained
+syn match rexxNumber '[-+]\s*\d\+' contained
+
+" Floating point number with decimal
+syn match rexxNumber '\d\+\.\d*' contained
+syn match rexxNumber '[-+]\s*\d\+\.\d*' contained
+
+" Floating point like number with E
+syn match rexxNumber '[-+]\s*\d*[eE][\-+]\d\+' contained
+syn match rexxNumber '\d*[eE][\-+]\d\+' contained
+
+" Floating point like number with E and decimal point (+,-)
+syn match rexxNumber '[-+]\s*\d*\.\d*[eE][\-+]\d\+' contained
+syn match rexxNumber '\d*\.\d*[eE][\-+]\d\+' contained
+
" ooRexx builtin classes (as of version 3.2.0, fall 2007), first define dot to be o.k. in keywords
syn keyword rexxBuiltinClass .Alarm .ArgUtil .Array .Bag .CaselessColumnComparator
syn keyword rexxBuiltinClass .CaselessComparator .CaselessDescendingComparator .CircularQueue
syn keyword rexxBuiltinClass .Class .Collection .ColumnComparator .Comparable .Comparator
-syn keyword rexxBuiltinClass .DateTime .DescendingComparator .Directory .InputOutputStream
+syn keyword rexxBuiltinClass .DateTime .DescendingComparator .Directory .File .InputOutputStream
syn keyword rexxBuiltinClass .InputStream .InvertingComparator .List .MapCollection
syn keyword rexxBuiltinClass .Message .Method .Monitor .MutableBuffer .Object
-syn keyword rexxBuiltinClass .OrderedCollection .OutputStream .Properties .Queue
-syn keyword rexxBuiltinClass .Relation .RexxQueue .Set .SetCollection .Stem .Stream
+syn keyword rexxBuiltinClass .OrderedCollection .OutputStream .Package .Properties .Queue
+syn keyword rexxBuiltinClass .RegularExpression .Relation .RexxContext .RexxQueue .Routine
+syn keyword rexxBuiltinClass .Set .SetCollection .Stem .Stream
syn keyword rexxBuiltinClass .StreamSupplier .String .Supplier .Table .TimeSpan
" Windows-only classes
@@ -163,7 +176,8 @@
syn keyword rexxBuiltinClass .DialogExtensions .DlgArea .DlgAreaU .DynamicDialog
syn keyword rexxBuiltinClass .EditControl .InputBox .IntegerBox .ListBox .ListChoice
syn keyword rexxBuiltinClass .ListControl .MenuObject .MessageExtensions .MultiInputBox
-syn keyword rexxBuiltinClass .MultiListChoice .PasswordBox .PlainBaseDialog .PlainUserDialog
+syn keyword rexxBuiltinClass .MultiListChoice .OLEObject .OLEVariant
+syn keyword rexxBuiltinClass .PasswordBox .PlainBaseDialog .PlainUserDialog
syn keyword rexxBuiltinClass .ProgressBar .ProgressIndicator .PropertySheet .RadioButton
syn keyword rexxBuiltinClass .RcDialog .ResDialog .ScrollBar .SingleSelection .SliderControl
syn keyword rexxBuiltinClass .StateIndicator .StaticControl .TabControl .TimedMessage
@@ -171,22 +185,34 @@
syn keyword rexxBuiltinClass .WindowExtensions .WindowObject .WindowsClassesBase .WindowsClipboard
syn keyword rexxBuiltinClass .WindowsEventLog .WindowsManager .WindowsProgramManager .WindowsRegistry
+" BSF4ooRexx classes
+syn keyword rexxBuiltinClass .BSF .bsf.dialog .bsf_proxy
+syn keyword rexxBuiltinClass .UNO .UNO_ENUM .UNO_CONSTANTS .UNO_PROPERTIES
+
" ooRexx directives, ---rgf location important, otherwise directives in top of file not matched!
syn region rexxClassDirective start="::\s*class\s*"ms=e+1 end="\ze\(\s\|;\|$\)"
syn region rexxMethodDirective start="::\s*method\s*"ms=e+1 end="\ze\(\s\|;\|$\)"
syn region rexxRequiresDirective start="::\s*requires\s*"ms=e+1 end="\ze\(\s\|;\|$\)"
syn region rexxRoutineDirective start="::\s*routine\s*"ms=e+1 end="\ze\(\s\|;\|$\)"
syn region rexxAttributeDirective start="::\s*attribute\s*"ms=e+1 end="\ze\(\s\|;\|$\)"
+" rgf, 2012-09-09
+syn region rexxOptionsDirective start="::\s*options\s*"ms=e+1 end="\ze\(\s\|;\|$\)"
+syn region rexxConstantDirective start="::\s*constant\s*"ms=e+1 end="\ze\(\s\|;\|$\)"
-syn region rexxDirective start="\(^\|;\)\s*::\s*\w\+" end="\($\|;\)" contains=rexxString,rexxComment,rexxLineComment,rexxClassDirective,rexxMethodDirective,rexxRoutineDirective,rexxRequiresDirective,rexxAttributeDirective keepend
+syn region rexxDirective start="\(^\|;\)\s*::\s*\w\+" end="\($\|;\)" contains=rexxString,rexxNumber,rexxComment,rexxLineComment,rexxClassDirective,rexxMethodDirective,rexxRoutineDirective,rexxRequiresDirective,rexxAttributeDirective,rexxOptionsDirective,rexxConstantDirective keepend
+
+syn match rexxOptionsDirective2 "\<\(digits\|form\|fuzz\|trace\)\>" containedin = rexxOptionsDirective3
+syn region rexxOptionsDirective3 start="\(^\|;\)\s*::\s*options\s"ms=e+1 end="\($\|;\)" contains=rexxString,rexxNumber,rexxVariable,rexxComment,rexxLineComment containedin = rexxDirective
+
syn region rexxVariable start="\zs\<\(\.\)\@!\K\k\+\>\ze\s*\(=\|,\|)\|%\|\]\|\\\||\|&\|+=\|-=\|<\|>\)" end="\(\_$\|.\)"me=e-1
-syn match rexxVariable "\(=\|,\|)\|%\|\]\|\\\||\|&\|+=\|-=\|<\|>\)\s*\zs\K\k*\ze"
+syn match rexxVariable "\(=\|,\|)\|%\|\]\|\\\||\|&\|+=\|-=\|<\|>\)\s*\zs\K\k*\ze"
" rgf, 2007-07-22: unfortunately, the entire region is colored (not only the
" patterns), hence useless (vim 7.0)! (syntax-docs hint that that should work)
" attempt: just colorize the parenthesis in matching colors, keep content
" transparent to keep the formatting already done to it!
+" TODO: test on 7.3
" syn region par1 matchgroup=par1 start="(" matchgroup=par1 end=")" transparent contains=par2
" syn region par2 matchgroup=par2 start="(" matchgroup=par2 end=")" transparent contains=par3 contained
" syn region par3 matchgroup=par3 start="(" matchgroup=par3 end=")" transparent contains=par4 contained
@@ -200,11 +226,11 @@
" syn region par4 matchgroup=par4 start="(" end=")" contains=par5 contained
" syn region par5 matchgroup=par5 start="(" end=")" contains=par1 contained
-hi par1 ctermfg=red guifg=red
-hi par2 ctermfg=blue guifg=blue
-hi par3 ctermfg=darkgreen guifg=darkgreen
-hi par4 ctermfg=darkyellow guifg=darkyellow
-hi par5 ctermfg=darkgrey guifg=darkgrey
+hi par1 ctermfg=red guifg=red "guibg=grey
+hi par2 ctermfg=blue guifg=blue "guibg=grey
+hi par3 ctermfg=darkgreen guifg=darkgreen "guibg=grey
+hi par4 ctermfg=darkyellow guifg=darkyellow "guibg=grey
+hi par5 ctermfg=darkgrey guifg=darkgrey "guibg=grey
" line continuation (trailing comma or single dash)
syn sync linecont "\(,\|-\ze-\@!\)\ze\s*\(--.*\|\/\*.*\)*$"
@@ -214,7 +240,7 @@
" endif
" exec "syn sync ccomment rexxComment minlines=" . rexx_minlines
-" always scan from start, PCs are powerful enough for that in 2007 !
+" always scan from start, PCs have long become to be powerful enough for that
exec "syn sync fromstart"
" Define the default highlighting.
@@ -236,7 +262,7 @@
HiLink endIterateLeaveLabelRegion rexxKeyword
HiLink rexxLoopKeywords rexxKeyword " Todo
- HiLink rexxNumber Normal
+ HiLink rexxNumber Normal "DiffChange
" HiLink rexxIdentifier DiffChange
HiLink rexxRegularCallSignal Statement
@@ -249,7 +275,7 @@
HiLink rexxCommentError rexxError
HiLink rexxError Error
HiLink rexxKeyword Statement
- HiLink rexxKeywordStatements Statement
+ HiLink rexxKeywordStatements Statement
HiLink rexxFunction Function
HiLink rexxString String
@@ -271,6 +297,13 @@
HiLink rexxRequiresDirective Include
HiLink rexxRoutineDirective rexxFunction
+" rgf, 2012-09-09
+ HiLink rexxOptionsDirective rexxFunction
+ HiLink rexxOptionsDirective2 rexxOptionsDirective
+ HiLink rexxOptionsDirective3 Normal " rexxOptionsDirective
+
+ HiLink rexxConstantDirective rexxFunction
+
HiLink rexxConst Constant
HiLink rexxTypeSpecifier Type
HiLink rexxBuiltinClass rexxTypeSpecifier