1" Vim syntax file 2" Language: Motif UIL (User Interface Language) 3" Maintainer: Thomas Koehler <[email protected]> 4" Last Change: 2013 May 23 5" URL: http://gott-gehabt.de/800_wer_wir_sind/thomas/Homepage/Computer/vim/syntax/uil.vim 6 7" quit when a syntax file was already loaded 8if exists("b:current_syntax") 9 finish 10endif 11 12" A bunch of useful keywords 13syn keyword uilType arguments callbacks color 14syn keyword uilType compound_string controls end 15syn keyword uilType exported file include 16syn keyword uilType module object procedure 17syn keyword uilType user_defined xbitmapfile 18 19syn keyword uilTodo contained TODO 20 21" String and Character constants 22" Highlight special characters (those which have a backslash) differently 23syn match uilSpecial contained "\\\d\d\d\|\\." 24syn region uilString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@Spell,uilSpecial 25syn match uilCharacter "'[^\\]'" 26syn region uilString start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=@Spell,uilSpecial 27syn match uilSpecialCharacter "'\\.'" 28syn match uilSpecialStatement "Xm[^ =(){}:;]*" 29syn match uilSpecialFunction "MrmNcreateCallback" 30syn match uilRessource "XmN[^ =(){}:;]*" 31 32syn match uilNumber "-\=\<\d*\.\=\d\+\(e\=f\=\|[uU]\=[lL]\=\)\>" 33syn match uilNumber "0[xX]\x\+\>" 34 35syn region uilComment start="/\*" end="\*/" contains=@Spell,uilTodo 36syn match uilComment "!.*" contains=@Spell,uilTodo 37syn match uilCommentError "\*/" 38 39syn region uilPreCondit start="^#\s*\(if\>\|ifdef\>\|ifndef\>\|elif\>\|else\>\|endif\>\)" skip="\\$" end="$" contains=uilComment,uilString,uilCharacter,uilNumber,uilCommentError 40syn match uilIncluded contained "<[^>]*>" 41syn match uilInclude "^#\s*include\s\+." contains=uilString,uilIncluded 42syn match uilLineSkip "\\$" 43syn region uilDefine start="^#\s*\(define\>\|undef\>\)" end="$" contains=uilLineSkip,uilComment,uilString,uilCharacter,uilNumber,uilCommentError 44 45syn sync ccomment uilComment 46 47" Define the default highlighting. 48" Only when an item doesn't have highlighting yet 49command -nargs=+ HiLink hi def link <args> 50 51" The default highlighting. 52HiLink uilCharacter uilString 53HiLink uilSpecialCharacter uilSpecial 54HiLink uilNumber uilString 55HiLink uilCommentError uilError 56HiLink uilInclude uilPreCondit 57HiLink uilDefine uilPreCondit 58HiLink uilIncluded uilString 59HiLink uilSpecialFunction uilRessource 60HiLink uilRessource Identifier 61HiLink uilSpecialStatement Keyword 62HiLink uilError Error 63HiLink uilPreCondit PreCondit 64HiLink uilType Type 65HiLink uilString String 66HiLink uilComment Comment 67HiLink uilSpecial Special 68HiLink uilTodo Todo 69 70delcommand HiLink 71 72 73let b:current_syntax = "uil" 74 75" vim: ts=8 76