annotate runtime/syntax/tak.vim @ 6925:30c9301f33ed v7.4.781

patch 7.4.781 Problem: line2byte() returns one less when 'bin' and 'noeol' are set. Solution: Only adjust the size for the last line. (Rob Wu)
author Bram Moolenaar <bram@vim.org>
date Sun, 12 Jul 2015 17:52:57 +0200
parents 3fc0f57ecb91
children 43efa4f5a8ea
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim syntax file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 " Language: TAK2, TAK3, TAK2000 thermal modeling input file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Maintainer: Adrian Nagle, anagle@ball.com
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 " Last Change: 2003 May 11
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 " Filenames: *.tak
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6 " URL: http://www.naglenet.org/vim/syntax/tak.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 " MAIN URL: http://www.naglenet.org/vim/
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 " For version 5.x: Clear all syntax items
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 " For version 6.x: Quit when a syntax file was already loaded
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 if version < 600
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 syntax clear
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 elseif exists("b:current_syntax")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 " Ignore case
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 syn case ignore
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 "
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 "
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 " Begin syntax definitions for tak input file.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 "
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 " Force free-form fortran format
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32 let fortran_free_source=1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 " Load FORTRAN syntax file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35 if version < 600
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 source <sfile>:p:h/fortran.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 runtime! syntax/fortran.vim
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40 unlet b:current_syntax
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 " Define keywords for TAK and TAKOUT
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45 syn keyword takOptions AUTODAMP CPRINT CSGDUMP GPRINT HPRINT LODTMP
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 syn keyword takOptions LOGIC LPRINT NCVPRINT PLOTQ QPRINT QDUMP
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 syn keyword takOptions SUMMARY SOLRTN UID DICTIONARIES
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 syn keyword takRoutine SSITER FWDWRD FWDBCK BCKWRD
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 syn keyword takControl ABSZRO BACKUP DAMP DTIMEI DTIMEL DTIMEH IFC
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 syn keyword takControl MAXTEMP NLOOPS NLOOPT NODELIST OUTPUT PLOT
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53 syn keyword takControl SCALE SIGMA SSCRIT TIMEND TIMEN TIMEO TRCRIT
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 syn keyword takControl PLOT
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56 syn keyword takSolids PLATE CYL
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57 syn keyword takSolidsArg ID MATNAM NTYPE TEMP XL YL ZL ISTRN ISTRG NNX
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 syn keyword takSolidsArg NNY NNZ INCX INCY INCZ IAK IAC DIFF ARITH BOUN
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59 syn keyword takSolidsArg RMIN RMAX AXMAX NNR NNTHETA INCR INCTHETA END
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61 syn case ignore
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 syn keyword takMacro fac pstart pstop
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64 syn keyword takMacro takcommon fstart fstop
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
65
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
66 syn keyword takIdentifier flq flx gen ncv per sim siv stf stv tvd tvs
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
67 syn keyword takIdentifier tvt pro thm
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
68
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
69
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
70
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
71 " Define matches for TAK
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
72 syn match takFortran "^F[0-9 ]"me=e-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
73 syn match takMotran "^M[0-9 ]"me=e-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
74
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
75 syn match takComment "^C.*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
76 syn match takComment "^R.*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
77 syn match takComment "\$.*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
78
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
79 syn match takHeader "^header[^,]*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
80
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
81 syn match takIncludeFile "include \+[^ ]\+"hs=s+8 contains=fortranInclude
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
82
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
83 syn match takInteger "-\=\<[0-9]*\>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
84 syn match takFloat "-\=\<[0-9]*\.[0-9]*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
85 syn match takScientific "-\=\<[0-9]*\.[0-9]*E[-+]\=[0-9]\+\>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
86
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
87 syn match takEndData "END OF DATA"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
88
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
89 if exists("thermal_todo")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
90 execute 'syn match takTodo ' . '"^'.thermal_todo.'.*$"'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
91 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
92 syn match takTodo "^?.*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
93 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
94
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
95
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
96
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
97 " Define the default highlighting
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
98 " For version 5.7 and earlier: only when not done already
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
99 " For version 5.8 and later: only when an item doesn't have highlighting yet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
100 if version >= 508 || !exists("did_tak_syntax_inits")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
101 if version < 508
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
102 let did_tak_syntax_inits = 1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
103 command -nargs=+ HiLink hi link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
104 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
105 command -nargs=+ HiLink hi def link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
106 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
107
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
108 HiLink takMacro Macro
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
109 HiLink takOptions Special
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
110 HiLink takRoutine Type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
111 HiLink takControl Special
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
112 HiLink takSolids Special
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
113 HiLink takSolidsArg Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
114 HiLink takIdentifier Identifier
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
115
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
116 HiLink takFortran PreProc
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
117 HiLink takMotran PreProc
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
118
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
119 HiLink takComment Comment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
120 HiLink takHeader Typedef
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
121 HiLink takIncludeFile Type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
122 HiLink takInteger Number
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
123 HiLink takFloat Float
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
124 HiLink takScientific Float
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
125
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
126 HiLink takEndData Macro
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
127
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
128 HiLink takTodo Todo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
129
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
130 delcommand HiLink
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
131 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
132
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
133
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
134 let b:current_syntax = "tak"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
135
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
136 " vim: ts=8 sw=2