" Vim syntax file " Language: XML " Maintainer: Paul Siegmann " URL: http://www.euronet.nl/~pauls/vim/syntax/xml.vim " Last change: 1998 May 7 " This syntax file will highlight xml tags and arguments. " " Currently this is a pre-alpha 'better-then-nothing' version, and I probably " not going to make any improvements, because it servers my purpose in its " current form " In other words, I copied Claudio Fleiner's html.vim " available from http://www.fleiner.com/vim/syntax/html.vim, " and did some global search and replace and stuff. " Remove any old syntax stuff hanging around syn clear syn case ignore " Only tags and special chars (ä) are highlighted " Known tag names and arg names are colored the same way " as statements and types, while unknwon ones as function. " mark illegal characters syn match xmlError "[<>&]" " tags syn match xmlSpecial contained "\\\d\d\d\|\\." syn region xmlString contained start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=xmlSpecial syn region xmlString contained start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=xmlSpecial syn region xmlEndTag start=++ contains=xmlTagName,xmlTagError syn region xmlTag start=+<[^/]+ end=+>+ contains=xmlString,xmlTagName,xmlArg,xmlValue,xmlTagError syn match xmlTagError contained "[^>]<"ms=s+1 " special characters syn match xmlSpecialChar "&[^;]*;" " server-parsed commands syn region xmlPreProc start=++ " The real comments (this implements the comments as defined by xml, " but not all xml pages actually conform to it. Errors are flagged. syn region xmlComment start=++ contains=xmlCommentPart,xmlCommentError syn region xmlComment start=++ syn match xmlCommentError contained "[^>