1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
|
<!-- Slightly modified from Chad Joan's original, added operators to be highlighed, some m4 stuff -->
<language name="Haxe" section="Sources" extensions="*.hx;*.Hx;*.hX;*.HX;"
mimetype="text/x-hxsrc" version="0.2" kateversion="3.1" casesensitive="true"
author="Chad Joan" license="MIT"> <highlighting> <list name="keywords">
<item> break </item>
<item> case </item> <item> cast </item> <item> catch </item> <item> class </item> <item> continue </item>
<item> default </item> <item> do </item> <item> dynamic </item>
<item> else </item> <item> enum </item> <item> extends </item>
<item> false </item> <item> for </item> <item> function </item>
<item> if </item> <item> implements </item> <item> in </item> <item> inline </item> <item> interface </item>
<item> new </item> <item> null </item>
<item> override </item>
<item> private </item> <item> public </item>
<item> return </item>
<item> static </item> <item> super </item> <item> switch </item>
<item> this </item> <item> throw </item> <item> trace </item> <item> true </item> <item> try </item> <item> typedef </item>
<item> untyped </item>
<item> var </item>
<item> while </item>
</list>
<list name="modules"> <item> package </item> <item> import </item> </list>
<list name="types"> <item> Array </item> <item> Void </item> <item> Bool </item> <item> Int </item> <item> UInt </item> <item> Float </item> <item> Dynamic </item> <item> String </item> <item> List </item> <item> Error </item> <item> Unknown </item> <item> Type </item> </list>
<list name='m4keywords'>
<item>define</item>
<item>ifelse</item>
<item>include</item>
<item>changecom</item>
<item>builtin</item>
<item>changequote</item>
<item>changeword</item>
<item>cleardivert</item>
<item>defn</item>
<item>divert</item>
<item>dnl</item>
<item>dumpdef</item>
<item>errprint</item>
<item>syscmd</item>
<item>esyscmd</item>
<item>sysval</item>
<item>eval</item>
<item>incr</item>
<item>decr</item>
<item>m4exit</item>
<item>fatal_error</item>
<item>format</item>
<item>patsubst</item>
<item>upcase</item>
<item>downcase</item>
<item>capitalize</item>
<item>substr</item>
<item>regexp</item>
<item>index</item>
<item>len</item>
</list>
<contexts>
<context attribute="Normal Text" lineEndContext="#stay" name="normal">
<RegExpr attribute="Preprocessor" context="#pop" String="#if(\s+\w+)?"/>
<RegExpr attribute="Preprocessor" context="#pop" String="#elseif(\s+\w+)?" />
<RegExpr attribute="Preprocessor" context="#pop" String="#(else|end|error)" />
<keyword attribute="M4Keyword" context="#stay" String="m4keywords"/>
<keyword attribute="Keyword" context="#stay" String="keywords"/>
<keyword attribute="Module" context="ModuleName" String="modules"/>
<keyword attribute="Type" context="#stay" String="types"/>
<DetectIdentifier attribute="Normal Text"/>
<HlCStringChar attribute="EscapeString" context="#pop"/>
<DetectChar attribute="M4String" context="M4String" char="`"/>
<DetectChar attribute="RawString" context="RawString" char="'"/>
<DetectChar attribute="String" context="String" char="""/>
<Detect2Chars attribute="RegularExp" context="RegularExp" char="~" char1="/"/>
<Detect2Chars attribute="Comment" context="CommentLine" char="/"
char1="/"/> <Detect2Chars attribute="Comment" context="CommentBlock" char="/"
char1="*" beginRegion="CommentBlock"/>
<DetectChar attribute="Block" context="#stay" char="{" beginRegion="BraceA" />
<DetectChar attribute="Block" context="#stay" char="}" endRegion="BraceA" />
<!-- Match ... and .. before numbers are matched. -->
<StringDetect attribute="Normal Text" context="#pop" String="..."/>
<Detect2Chars attribute="Normal Text" char="." char1="."/>
<!-- Numerics --> <RegExpr attribute="Hex" context="#pop"
String="[-+]?0[xX][\da-fA-F]+"/>
<RegExpr attribute="Float" context="#pop"
String="[-+]?[\d][\d]*(\.(?!\.)[\d]*([eE][-+]?[\d]+)?)"/> <RegExpr attribute="Float" context="#pop"
String="[-+]?\.?[\d][\d]*([eE][-+]?[\d]+)?"/>
<RegExpr attribute="Integer" context="#pop" String="[-+]?\d+"/>
<RegExpr context="#stay" attribute="Operators" String="[\(\)+-*/\[\]/:,\.=|&<>?]"/>
<RegExpr context="#stay" attribute="Block" String="[\{\};]"/>
</context>
<context attribute="Module Name" lineEndContext="#stay" name="ModuleName">
<Detect2Chars attribute="Comment" context="CommentLine" char="/" char1="/"/>
<Detect2Chars attribute="Comment" context="CommentBlock" char="/" char1="*" beginRegion="CommentBlock"/>
<RegExpr context="#pop" String="[^\s\w.:,]"/>
</context>
<!-- Strings --> <!-- '...' -->
<context attribute="RawString" lineEndContext="#stay" name="RawString">
<DetectChar attribute="RawString" context="#pop" char="'"/>
</context> <!-- "..." -->
<context attribute="M4String" lineEndContext="#stay" name="M4String">
<DetectChar attribute="M4String" context="M4String" char="`"/>
<DetectChar attribute="M4String" context="#pop" char="'"/>
</context>
<context attribute="String" lineEndContext="#stay" name="String">
<Detect2Chars attribute="String" context="#stay" char="\" char1="""/>
<DetectChar attribute="String" context="#pop" char="""/>
<HlCStringChar attribute="EscapeSequence"/>
<RegExpr attribute="EscapeSequence" context="#stay" String="\\(u[\da-fA-F]{4}|U[\da-fA-F]{8}|&[a-zA-Z]\w+;)" />
</context> <!-- "~/.../igm" regular expression literals -->
<context attribute="RegularExp" lineEndContext="#stay" name="RegularExp">
<Detect2Chars attribute="RegularExp" context="#stay" char="\" char1="/"/>
<RegExpr attribute="RegularExp" context="#pop" String="/[igm]*"/>
</context>
<!-- Comments -->
<context attribute="Comment" lineEndContext="#pop" name="CommentLine"/>
<context attribute="Comment" lineEndContext="#stay" name="CommentBlock">
<Detect2Chars attribute="Comment" context="#pop" char="*" char1="/" endRegion="CommentBlock"/>
</context>
</contexts>
<itemDatas>
<itemData name="Normal Text" defStyleNum="dsNormal"/>
<itemData name="Keyword" defStyleNum="dsKeyword"/>
<itemData name="M4Keyword" defStyleNum="dsKeyword"/>
<itemData name="Operators" defStyleNum="dsNormal"/>
<itemData name="Block" defStyleNum="dsNormal"/>
<itemData name="Type" defStyleNum="dsDataType"/>
<itemData name="Integer" defStyleNum="dsDecVal"/>
<itemData name="Hex" defStyleNum="dsBaseN"/>
<itemData name="Float" defStyleNum="dsFloat"/>
<itemData name="Module" defStyleNum="dsKeyword" color="#0000ff" selColor="#ffffff"/>
<itemData name="Module Name" defStyleNum="dsNormal" color="#0000ff" selColor="#ffffff"/>
<itemData name="EscapeSequence" defStyleNum="dsString" color="#00aa88" selColor="#ff0000"/>
<itemData name="String" defStyleNum="dsString"/>
<itemData name="RawString" defStyleNum="dsString"/>
<itemData name="RegularExp" defStyleNum="dsString"/>
<itemData name="Comment" defStyleNum="dsComment"/>
<itemData name="Preprocessor" defStyleNum="dsOthers"/>
<itemDate name="M4String" defStyleNum="dsOthers"/>
</itemDatas>
</highlighting>
<general> <comments> <comment name="singleLine" start="//"/> <comment name="multiLine" start="/*" end="*/" /> </comments>
<keywords casesensitive="1"/>
</general>
</language>
|