xref: /vim-8.2.3635/runtime/syntax/sindaout.vim (revision 2bf24176)
1" Vim syntax file
2" Language:     sinda85, sinda/fluint output file
3" Maintainer:   Adrian Nagle, [email protected]
4" Last Change:  2003 May 11
5" Filenames:    *.out
6" URL:		http://www.naglenet.org/vim/syntax/sindaout.vim
7" MAIN URL:     http://www.naglenet.org/vim/
8
9
10
11" For version 5.x: Clear all syntax items
12" For version 6.x: Quit when a syntax file was already loaded
13if version < 600
14  syntax clear
15elseif exists("b:current_syntax")
16  finish
17endif
18
19
20
21" Ignore case
22syn case match
23
24
25
26" Load SINDA syntax file
27if version < 600
28  source <sfile>:p:h/sinda.vim
29else
30  runtime! syntax/sinda.vim
31endif
32unlet b:current_syntax
33
34
35
36"
37"
38" Begin syntax definitions for sinda output files.
39"
40
41" Define keywords for sinda output
42syn case match
43
44syn keyword sindaoutPos       ON SI
45syn keyword sindaoutNeg       OFF ENG
46
47
48
49" Define matches for sinda output
50syn match sindaoutFile	       ": \w*\.TAK"hs=s+2
51
52syn match sindaoutInteger      "T\=[0-9]*\>"ms=s+1
53
54syn match sindaoutSectionDelim "[-<>]\{4,}" contains=sindaoutSectionTitle
55syn match sindaoutSectionDelim ":\=\.\{4,}:\=" contains=sindaoutSectionTitle
56syn match sindaoutSectionTitle "[-<:] \w[0-9A-Za-z_() ]\+ [->:]"hs=s+1,me=e-1
57
58syn match sindaoutHeaderDelim  "=\{5,}"
59syn match sindaoutHeaderDelim  "|\{5,}"
60syn match sindaoutHeaderDelim  "+\{5,}"
61
62syn match sindaoutLabel		"Input File:" contains=sindaoutFile
63syn match sindaoutLabel		"Begin Solution: Routine"
64
65syn match sindaoutError		"<<< Error >>>"
66
67
68" Define the default highlighting
69" For version 5.7 and earlier: only when not done already
70" For version 5.8 and later: only when an item doesn't have highlighting yet
71if version >= 508 || !exists("did_sindaout_syntax_inits")
72  if version < 508
73    let did_sindaout_syntax_inits = 1
74    command -nargs=+ HiLink hi link <args>
75  else
76    command -nargs=+ HiLink hi def link <args>
77  endif
78
79  hi sindaHeaderDelim  ctermfg=Black ctermbg=Green	       guifg=Black guibg=Green
80
81  HiLink sindaoutPos		     Statement
82  HiLink sindaoutNeg		     PreProc
83  HiLink sindaoutTitle		     Type
84  HiLink sindaoutFile		     sindaIncludeFile
85  HiLink sindaoutInteger	     sindaInteger
86
87  HiLink sindaoutSectionDelim	      Delimiter
88  HiLink sindaoutSectionTitle	     Exception
89  HiLink sindaoutHeaderDelim	     SpecialComment
90  HiLink sindaoutLabel		     Identifier
91
92  HiLink sindaoutError		     Error
93
94  delcommand HiLink
95endif
96
97
98let b:current_syntax = "sindaout"
99
100" vim: ts=8 sw=2
101