Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100755 401 lines (352 sloc) 12.975 kb
e692455 @djspiewak Initial commit
authored
1 <?xml version="1.0"?>
2
3 <!DOCTYPE MODE SYSTEM "xmode.dtd">
4
5 <MODE>
6 <PROPS>
7 <PROPERTY NAME="indentOpenBrackets" VALUE="{" />
8 <PROPERTY NAME="indentCloseBrackets" VALUE="}" />
9 <PROPERTY NAME="lineUpClosingBracket" VALUE="true" />
10 <PROPERTY NAME="indentPrevLine"
11 VALUE="\s*(((if|while)\s*\(|else\s*(\{|$)|else\s+if\s*\(|case\s+.+:|default:)[^;]*|for\s*\(.*)" />
12 <!-- set this to 'true' if you want to use GNU coding style -->
13 <PROPERTY NAME="doubleBracketIndent" VALUE="false" />
14 <PROPERTY NAME="commentStart" VALUE="/*" />
15 <PROPERTY NAME="commentEnd" VALUE="*/" />
16 <PROPERTY NAME="lineComment" VALUE="//" />
17 <PROPERTY NAME="noTabs" VALUE="true" />
18 <PROPERTY NAME="tabSize" VALUE="2" />
19 <PROPERTY NAME="indentSize" VALUE="2" />
20 <PROPERTY NAME="wordBreakChars" VALUE=",+-=&lt;&gt;/?^&amp;*" />
21 </PROPS>
22
23 <RULES ESCAPE="\" IGNORE_CASE="FALSE" HIGHLIGHT_DIGITS="TRUE"
24 DIGIT_RE="(0[lL]?|[1-9]\d{0,9}(\d{0,9}[lL])?|0[xX]\p{XDigit}{1,8}(\p{XDigit}{0,8}[lL])?|0[0-7]{1,11}([0-7]{0,11}[lL])?|([0-9]+\.[0-9]*|\.[0-9]+)([eE][+-]?[0-9]+)?[fFdD]?|[0-9]+([eE][+-]?[0-9]+[fFdD]?|([eE][+-]?[0-9]+)?[fFdD]))">
06f1931 @djspiewak El Bizarro hack for annotations vs patterns
authored
25
26 <MARK_FOLLOWING TYPE="LABEL">@</MARK_FOLLOWING>
27
28 <IMPORT DELEGATE="PRIMARY"/>
29 </RULES>
30
31 <RULES SET="PRIMARY">
e692455 @djspiewak Initial commit
authored
32 <!-- Silly comment -->
33 <SEQ TYPE="COMMENT1">/**/</SEQ>
34
35 <EOL_SPAN TYPE="COMMENT2">//</EOL_SPAN>
36
37 <!-- Scaladoc comment -->
38 <SPAN TYPE="COMMENT3" DELEGATE="SCALADOC">
39 <BEGIN>/**</BEGIN>
40 <END>*/</END>
41 </SPAN>
42
43 <!-- Scala comment (Java style) -->
44 <SPAN TYPE="COMMENT1">
45 <BEGIN>/*</BEGIN>
46 <END>*/</END>
47 </SPAN>
48
49 <!-- start of XML comment (griba2010@ya.com) -->
50 <SEQ_REGEXP HASH_CHAR="&lt;" AT_WHITESPACE_END="TRUE" TYPE="COMMENT2"
51 DELEGATE="XML_COMMENT">&lt;!--</SEQ_REGEXP>
52
53 <!-- start of xml tag (griba2010@ya.com) -->
54 <SEQ_REGEXP HASH_CHAR="&lt;" AT_WHITESPACE_END="TRUE" TYPE="LITERAL3"
55 DELEGATE="XML_TAG">&lt;\/?\w*</SEQ_REGEXP>
56
57 <!-- string and character literals -->
ce84df5 @djspiewak Fixed """ string literals
authored
58 <SPAN TYPE="LITERAL1" NO_LINE_BREAK="FALSE">
59 <BEGIN>"""</BEGIN>
60 <END>"""</END>
61 </SPAN>
e692455 @djspiewak Initial commit
authored
62 <SPAN TYPE="LITERAL1" NO_LINE_BREAK="TRUE">
63 <BEGIN>"</BEGIN>
64 <END>"</END>
65 </SPAN>
66 <SEQ_REGEXP HASH_CHAR="'" TYPE="LITERAL1">'([^']|\\.)'</SEQ_REGEXP>
67
68 <!-- symbol literals -->
69 <SEQ_REGEXP HASH_CHAR="'" TYPE="LABEL">'[0-9a-zA-Z]([0-9a-zA-Z]|_.)*</SEQ_REGEXP>
70
71 <!-- type params between bracket pairs with -->
72 <!-- nested ones within (griba2010@ya.com) -->
73 <SEQ_REGEXP HASH_CHAR="[" TYPE="LITERAL3"
74 >\[[^\[\]]*(\[[^\[\]]*(\[[^\[\]]*\][^\[\]]*)*\][^\[\]]*)*\]</SEQ_REGEXP>
75
76 <!-- type constraints (griba2010@ya.com) -->
77 <SEQ_REGEXP HASH_CHAR="&lt;" TYPE="LITERAL2"
78 >&lt;:\s*\w+(\.\w+)*(#\w+)?</SEQ_REGEXP>
79 <SEQ_REGEXP HASH_CHAR=">" TYPE="LITERAL2"
80 >&gt;:\s*\w+(\.\w+)*(#\w+)?</SEQ_REGEXP>
81
82 <SEQ TYPE="OPERATOR">)</SEQ>
83 <SEQ TYPE="OPERATOR">=</SEQ>
84 <SEQ TYPE="OPERATOR">!</SEQ>
85 <SEQ TYPE="OPERATOR">&gt;=</SEQ>
86 <SEQ TYPE="OPERATOR">&gt;:</SEQ>
87 <SEQ TYPE="OPERATOR">&lt;=</SEQ>
88 <SEQ TYPE="OPERATOR">&lt;:</SEQ>
89 <SEQ TYPE="OPERATOR">+</SEQ>
90 <SEQ TYPE="OPERATOR">-</SEQ>
91 <SEQ TYPE="OPERATOR">/</SEQ>
92 <SEQ TYPE="OPERATOR">*</SEQ>
93 <SEQ TYPE="OPERATOR">&gt;</SEQ>
94 <SEQ TYPE="OPERATOR">&lt;</SEQ>
95 <SEQ TYPE="OPERATOR">%</SEQ>
96 <SEQ TYPE="OPERATOR">&amp;</SEQ>
97 <SEQ TYPE="OPERATOR">|</SEQ>
98 <SEQ TYPE="OPERATOR">^</SEQ>
06f1931 @djspiewak El Bizarro hack for annotations vs patterns
authored
99 <SEQ TYPE="OPERATOR">`</SEQ>
e692455 @djspiewak Initial commit
authored
100 <SEQ TYPE="OPERATOR">~</SEQ>
101 <SEQ TYPE="OPERATOR">}</SEQ>
102 <SEQ TYPE="OPERATOR">{</SEQ>
103 <SEQ TYPE="NULL">.</SEQ>
104 <SEQ TYPE="NULL">,</SEQ>
105 <SEQ TYPE="NULL">;</SEQ>
106 <SEQ TYPE="NULL">]</SEQ>
107 <SEQ TYPE="NULL">[</SEQ>
108 <SEQ TYPE="NULL">?</SEQ>
109 <SEQ TYPE="NULL">:</SEQ>
110
111 <!-- after colon type descriptions (griba2010@ya.com) -->
112 <SEQ_REGEXP HASH_CHAR=":" TYPE="LITERAL2"
113 >:\s*\w+(\.\w+)*(#\w+)?</SEQ_REGEXP>
114
115 <!-- Function calls -->
116 <MARK_PREVIOUS TYPE="FUNCTION" MATCH_TYPE="OPERATOR">(</MARK_PREVIOUS>
06f1931 @djspiewak El Bizarro hack for annotations vs patterns
authored
117
fa936fe @djspiewak Fixed case...er, case issue
authored
118 <SPAN DELEGATE="PATTERN" MATCH_TYPE="KEYWORD1" AT_WORD_START="TRUE" NO_LINE_BREAK="TRUE">
119 <BEGIN>case </BEGIN>
06f1931 @djspiewak El Bizarro hack for annotations vs patterns
authored
120 <END>=&gt;</END>
fa936fe @djspiewak Fixed case...er, case issue
authored
121 </SPAN>
e692455 @djspiewak Initial commit
authored
122
fa936fe @djspiewak Fixed case...er, case issue
authored
123 <KEYWORDS>
e692455 @djspiewak Initial commit
authored
124 <KEYWORD1>abstract</KEYWORD1>
125 <KEYWORD1>catch</KEYWORD1>
126 <KEYWORD1>class</KEYWORD1>
127 <KEYWORD1>def</KEYWORD1>
128 <KEYWORD1>do</KEYWORD1>
129 <KEYWORD1>else</KEYWORD1>
130 <KEYWORD1>extends</KEYWORD1>
131 <KEYWORD1>final</KEYWORD1>
132 <KEYWORD1>finally</KEYWORD1>
133 <KEYWORD1>for</KEYWORD1>
134 <KEYWORD1>forSome</KEYWORD1>
135 <KEYWORD1>if</KEYWORD1>
136 <KEYWORD1>implicit</KEYWORD1>
137 <KEYWORD1>import</KEYWORD1>
138 <KEYWORD1>lazy</KEYWORD1>
139 <KEYWORD1>match</KEYWORD1>
140 <KEYWORD1>new</KEYWORD1>
141 <KEYWORD1>object</KEYWORD1>
142 <KEYWORD1>override</KEYWORD1>
143 <KEYWORD1>package</KEYWORD1>
144 <KEYWORD1>private</KEYWORD1>
145 <KEYWORD1>protected</KEYWORD1>
146 <KEYWORD1>requires</KEYWORD1>
147 <KEYWORD1>return</KEYWORD1>
148 <KEYWORD1>sealed</KEYWORD1>
149 <KEYWORD1>throw</KEYWORD1>
150 <KEYWORD1>trait</KEYWORD1>
151 <KEYWORD1>try</KEYWORD1>
152 <KEYWORD1>type</KEYWORD1>
153 <KEYWORD1>val</KEYWORD1>
154 <KEYWORD1>var</KEYWORD1>
155 <KEYWORD1>with</KEYWORD1>
156 <KEYWORD1>while</KEYWORD1>
157 <KEYWORD1>yield</KEYWORD1>
158 <KEYWORD1>=&gt;</KEYWORD1>
159
160 <!-- java.lang.* wrapper types -->
161 <KEYWORD2>Character</KEYWORD2>
162 <KEYWORD2>Integer</KEYWORD2>
163
164 <!-- scala.* primitive types -->
165 <KEYWORD2>Boolean</KEYWORD2>
166 <KEYWORD2>boolean</KEYWORD2>
167 <KEYWORD2>Byte</KEYWORD2>
168 <KEYWORD2>byte</KEYWORD2>
169 <KEYWORD2>Char</KEYWORD2>
170 <KEYWORD2>char</KEYWORD2>
171 <KEYWORD2>Double</KEYWORD2>
172 <KEYWORD2>double</KEYWORD2>
173 <KEYWORD2>Float</KEYWORD2>
174 <KEYWORD2>float</KEYWORD2>
175 <KEYWORD2>Int</KEYWORD2>
176 <KEYWORD2>int</KEYWORD2>
177 <KEYWORD2>Long</KEYWORD2>
178 <KEYWORD2>long</KEYWORD2>
179 <KEYWORD2>Short</KEYWORD2>
180 <KEYWORD2>short</KEYWORD2>
181 <KEYWORD2>Unit</KEYWORD2>
182 <KEYWORD2>unit</KEYWORD2>
183
184 <!-- scala.* predefined types -->
185 <KEYWORD3>Actor</KEYWORD3>
186 <KEYWORD3>ActorProxy</KEYWORD3>
187 <KEYWORD3>ActorTask</KEYWORD3>
188 <KEYWORD3>ActorThread</KEYWORD3>
189 <KEYWORD3>AllRef</KEYWORD3>
190 <KEYWORD3>Any</KEYWORD3>
191 <KEYWORD3>AnyRef</KEYWORD3>
192 <KEYWORD3>Application</KEYWORD3>
193 <KEYWORD3>AppliedType</KEYWORD3>
194 <KEYWORD3>Array</KEYWORD3>>
195 <KEYWORD3>ArrayBuffer</KEYWORD3>
196 <KEYWORD3>Attribute</KEYWORD3>
197 <KEYWORD3>BoxedArray</KEYWORD3>
198 <KEYWORD3>BoxedBooleanArray</KEYWORD3>
199 <KEYWORD3>BoxedByteArray</KEYWORD3>
200 <KEYWORD3>BoxedCharArray</KEYWORD3>
201 <KEYWORD3>Buffer</KEYWORD3>
202 <KEYWORD3>BufferedIterator</KEYWORD3>
203 <KEYWORD3>Enumeration</KEYWORD3>
204 <KEYWORD3>Fluid</KEYWORD3>
205 <KEYWORD3>Function</KEYWORD3>
206 <KEYWORD3>IScheduler</KEYWORD3>
207 <KEYWORD3>ImmutableMapAdaptor</KEYWORD3>
208 <KEYWORD3>ImmutableSetAdaptor</KEYWORD3>
209 <KEYWORD3>Iterable</KEYWORD3>
210 <KEYWORD3>List</KEYWORD3>
211 <KEYWORD3>Option</KEYWORD3>
212 <KEYWORD3>Pair</KEYWORD3>
213 <KEYWORD3>PartialFunction</KEYWORD3>
214 <KEYWORD3>Pid</KEYWORD3>
215 <KEYWORD3>PriorityQueue</KEYWORD3>
216 <KEYWORD3>PriorityQueueProxy</KEYWORD3>
217 <KEYWORD3>Reaction</KEYWORD3>
218 <KEYWORD3>Ref</KEYWORD3>
219 <KEYWORD3>Responder</KEYWORD3>
220 <KEYWORD3>RichInt</KEYWORD3>
221 <KEYWORD3>RichString</KEYWORD3>
222 <KEYWORD3>Rule</KEYWORD3>
223 <KEYWORD3>RuleTransformer</KEYWORD3>
224 <KEYWORD3>Script</KEYWORD3>
225 <KEYWORD3>Some</KEYWORD3>
226 <KEYWORD3>Stream</KEYWORD3>
227 <KEYWORD3>String</KEYWORD3>
228 <KEYWORD3>Symbol</KEYWORD3>
229 <KEYWORD3>TcpService</KEYWORD3>
230 <KEYWORD3>TcpServiceWorker</KEYWORD3>
231 <KEYWORD3>WorkerThread</KEYWORD3>
232
233 <!-- scala.* predefined objects -->
234 <KEYWORD4>Console</KEYWORD4>
235 <KEYWORD4>Nil</KEYWORD4>
236 <KEYWORD4>None</KEYWORD4>
237 <KEYWORD4>Predef</KEYWORD4>
238 <KEYWORD4>RemoteActor</KEYWORD4>
239 <KEYWORD4>SUnit</KEYWORD4>
240 <KEYWORD4>ScalaRunTime</KEYWORD4>
241 <KEYWORD4>Scheduler</KEYWORD4>
242 <KEYWORD4>TIMEOUT</KEYWORD4>
243 <KEYWORD4>TimerThread</KEYWORD4>
244
245 <LITERAL2>false</LITERAL2>
246 <LITERAL2>null</LITERAL2>
247 <LITERAL2>super</LITERAL2>
248 <LITERAL2>this</LITERAL2>
249 <LITERAL2>true</LITERAL2>
250 </KEYWORDS>
251 </RULES>
06f1931 @djspiewak El Bizarro hack for annotations vs patterns
authored
252
253 <RULES SET="PATTERN" DEFAULT="NULL" IGNORE_CASE="FALSE">
254 <IMPORT DELEGATE="PRIMARY"/>
255
256 <SEQ TYPE="OPERATOR">@</SEQ>
257 </RULES>
e692455 @djspiewak Initial commit
authored
258
259 <RULES SET="SCALADOC" DEFAULT="COMMENT3" IGNORE_CASE="TRUE">
260 <!-- so that @link{...} is highlighted -->
261 <SEQ TYPE="COMMENT3">{</SEQ>
262
263 <!-- so that *@param is highlighted -->
264 <SEQ TYPE="COMMENT3">*</SEQ>
265
266 <!-- Javadoc ignores tags inside <pre> -->
267 <SPAN TYPE="MARKUP" DELEGATE="SCALADOC_PRE">
268 <BEGIN>&lt;pre&gt;</BEGIN>
269 <END>&lt;/pre&gt;</END>
270 </SPAN>
271
272 <!-- HTML comments -->
273 <SPAN TYPE="COMMENT1">
274 <BEGIN>&lt;!--</BEGIN>
275 <END>--&gt;</END>
276 </SPAN>
277
278 <!-- Javadoc allows this -->
279 <SEQ TYPE="COMMENT3">&lt;&lt;</SEQ>
280 <SEQ TYPE="COMMENT3">&lt;=</SEQ>
281 <SEQ TYPE="COMMENT3">&lt; </SEQ>
282
283 <!-- HTML tags -->
284 <SPAN TYPE="MARKUP" DELEGATE="xml::TAGS">
285 <BEGIN>&lt;</BEGIN>
286 <END>&gt;</END>
287 </SPAN>
288
289 <KEYWORDS>
290 <LABEL>@author</LABEL>
291 <LABEL>@beaninfo</LABEL>
292 <LABEL>@history</LABEL>
293 <LABEL>@bug</LABEL>
294 <LABEL>@review</LABEL>
295 <LABEL>@todo</LABEL>
296 <LABEL>@idea</LABEL>
297 <LABEL>@pre</LABEL>
298 <LABEL>@requires</LABEL>
299 <LABEL>@post</LABEL>
300 <LABEL>@ensures</LABEL>
301 <LABEL>@generates</LABEL>
302 <LABEL>@modifies</LABEL>
303 <LABEL>@invariant</LABEL>
304 <LABEL>@exception</LABEL>
305 <LABEL>@hides</LABEL>
306 <LABEL>@overrides</LABEL>
307 <LABEL>@equivalent</LABEL>
308 <LABEL>@bon</LABEL>
309 <LABEL>@access</LABEL>
310 <LABEL>@example</LABEL>
311 <LABEL>@design</LABEL>
312 <LABEL>@serial</LABEL>
313 <LABEL>@references</LABEL>
314 <LABEL>@uses</LABEL>
315 <LABEL>@guard</LABEL>
316 <LABEL>@values</LABEL>
317 <LABEL>@complexity</LABEL>
318 <LABEL>@deprecated</LABEL>
319 <LABEL>@docRoot</LABEL>
320 <LABEL>@exception</LABEL>
321 <LABEL>@link</LABEL>
322 <LABEL>@param</LABEL>
323 <LABEL>@return</LABEL>
324 <LABEL>@see</LABEL>
325 <LABEL>@serialData</LABEL>
326 <LABEL>@serialField</LABEL>
327 <LABEL>@since</LABEL>
328 <LABEL>@throws</LABEL>
329 <LABEL>@version</LABEL>
330 <LABEL>@spec</LABEL>
331 </KEYWORDS>
332 </RULES>
333
334 <RULES SET="SCALADOC_PRE" DEFAULT="COMMENT3" />
335
336 <!-- inside xml tag default type label -->
337 <!-- for attribute names (griba2010@ya.com) -->
338 <RULES SET="XML_TAG" DEFAULT="LABEL" IGNORE_CASE="TRUE">
339 <!-- string and character literals -->
340 <SPAN TYPE="LITERAL1" NO_LINE_BREAK="TRUE">
341 <BEGIN>"</BEGIN>
342 <END>"</END>
343 </SPAN>
344
345 <SPAN TYPE="LITERAL1" NO_LINE_BREAK="TRUE">
346 <BEGIN>'</BEGIN>
347 <END>'</END>
348 </SPAN>
349
350 <!-- scala attribute value -->
351 <SPAN DELEGATE="MAIN">
352 <BEGIN>{</BEGIN>
353 <END>}</END>
354 </SPAN>
355
356 <!-- if ">\n" goto main rule set -->
357 <SEQ_REGEXP HASH_CHAR="&gt;" DELEGATE="MAIN" TYPE="LITERAL3"
358 >&gt;$</SEQ_REGEXP>
359
360 <!-- if ">;" goto main rule set -->
361 <SEQ_REGEXP HASH_CHAR="&gt;" DELEGATE="MAIN" TYPE="LITERAL3"
362 >&gt;\s*;</SEQ_REGEXP>
363
364 <!-- if ">)" goto main rule set -->
365 <SEQ_REGEXP HASH_CHAR="&gt;" DELEGATE="MAIN" TYPE="LITERAL3"
366 >&gt;\s*\)</SEQ_REGEXP>
367
368 <!-- if ">" goto xml_text rule set -->
369 <SEQ DELEGATE="XML_TEXT" TYPE="LITERAL3">&gt;</SEQ>
370 </RULES>
371
372 <RULES SET="XML_TEXT" DEFAULT="COMMENT4">
373 <!-- scala expression -->
374 <SPAN DELEGATE="MAIN">
375 <BEGIN>{</BEGIN>
376 <END>}</END>
377 </SPAN>
378
379 <SEQ_REGEXP HASH_CHAR="&lt;" DELEGATE="XML_COMMENT" TYPE="COMMENT2"
380 >&lt;!--</SEQ_REGEXP>
381 <!-- if "<" goto xml_tag rule set -->
382 <SEQ_REGEXP HASH_CHAR="&lt;" DELEGATE="XML_TAG" TYPE="LITERAL3"
383 >&lt;\/?\w*</SEQ_REGEXP>
384 </RULES>
385
386 <RULES SET="XML_COMMENT" DEFAULT="COMMENT2">
387 <!-- if end_of_comment with "\n" goto main rule set -->
388 <SEQ_REGEXP HASH_CHAR="-" DELEGATE="MAIN" TYPE="COMMENT2"
389 >--&gt;$</SEQ_REGEXP>
390
391 <!-- if end_of_comment with ";" goto main rule set -->
392 <SEQ_REGEXP HASH_CHAR="-" DELEGATE="MAIN" TYPE="COMMENT2"
393 >--&gt;\s*;</SEQ_REGEXP>
394
395 <!-- if end_of_comment goto xml_text rule set -->
396 <SEQ DELEGATE="XML_TEXT" TYPE="COMMENT2">--&gt;</SEQ>
397 </RULES>
398 </MODE>
399
400 <!-- $Id: scala.xml 12156 2007-06-28 12:33:22Z michelou $ -->
Something went wrong with that request. Please try again.