xref: /vim-8.2.3635/runtime/syntax/dsl.vim (revision 36e294c0)
1" Vim syntax file
2" Language:	DSSSL
3" Maintainer:	Johannes Zellner <[email protected]>
4" Last Change:	Tue, 27 Apr 2004 14:54:59 CEST
5" Filenames:	*.dsl
6" $Id: dsl.vim,v 1.1 2004/06/13 19:13:31 vimboss Exp $
7
8if exists("b:current_syntax") | finish | endif
9
10runtime syntax/xml.vim
11syn cluster xmlRegionHook add=dslRegion,dslComment
12syn cluster xmlCommentHook add=dslCond
13
14" EXAMPLE:
15"   <![ %output.html; [
16"     <!-- some comment -->
17"     (define html-manifest #f)
18"   ]]>
19"
20" NOTE: 'contains' the same as xmlRegion, except xmlTag / xmlEndTag
21syn region  dslCond matchgroup=dslCondDelim start="\[\_[^[]\+\[" end="]]" contains=xmlCdata,@xmlRegionCluster,xmlComment,xmlEntity,xmlProcessing,@xmlRegionHook
22
23" NOTE, that dslRegion and dslComment do both NOT have a 'contained'
24" argument, so this will also work in plain dsssl documents.
25
26syn region dslRegion matchgroup=Delimiter start=+(+ end=+)+ contains=dslRegion,dslString,dslComment
27syn match dslString +"\_[^"]*"+ contained
28syn match dslComment +;.*$+ contains=dslTodo
29syn keyword dslTodo contained TODO FIXME XXX display
30
31" The default highlighting.
32hi def link dslTodo		Todo
33hi def link dslString		String
34hi def link dslComment		Comment
35" compare the following with xmlCdataStart / xmlCdataEnd
36hi def link dslCondDelim	Type
37
38let b:current_syntax = "dsl"
39