Debian Codegraph @

extensions/CodeEditor/modules/lib/ace/mode-csound_document.js

raw symbols SCIP
1 ace.define("ace/mode/csound_preprocessor_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module){"use strict";
2 var oop = require("../lib/oop");
3 var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
4 var CsoundPreprocessorHighlightRules = function (embeddedRulePrefix) {
5 this.embeddedRulePrefix = embeddedRulePrefix === undefined ? "" : embeddedRulePrefix;
6 this.semicolonComments = {
7 token: "comment.line.semicolon.csound",
8 regex: ";.*$"
9 };
10 this.comments = [
11 {
12 token: "punctuation.definition.comment.begin.csound",
13 regex: "/\\*",
14 push: [
15 {
16 token: "punctuation.definition.comment.end.csound",
17 regex: "\\*/",
18 next: "pop"
19 }, {
20 defaultToken: "comment.block.csound"
21 }
22 ]
23 }, {
24 token: "comment.line.double-slash.csound",
25 regex: "//.*$"
26 },
27 this.semicolonComments
28 ];
29 this.macroUses = [
30 {
31 token: ["entity.name.function.preprocessor.csound", "punctuation.definition.macro-parameter-value-list.begin.csound"],
32 regex: /(\$[A-Z_a-z]\w*\.?)(\()/,
33 next: "macro parameter value list"
34 }, {
35 token: "entity.name.function.preprocessor.csound",
36 regex: /\$[A-Z_a-z]\w*(?:\.|\b)/
37 }
38 ];
39 this.numbers = [
40 {
41 token: "constant.numeric.float.csound",
42 regex: /(?:\d+[Ee][+-]?\d+)|(?:\d+\.\d*|\d*\.\d+)(?:[Ee][+-]?\d+)?/
43 }, {
44 token: ["storage.type.number.csound", "constant.numeric.integer.hexadecimal.csound"],
45 regex: /(0[Xx])([0-9A-Fa-f]+)/
46 }, {
47 token: "constant.numeric.integer.decimal.csound",
48 regex: /\d+/
49 }
50 ];
51 this.bracedStringContents = [
52 {
53 token: "constant.character.escape.csound",
54 regex: /\\(?:[\\abnrt"]|[0-7]{1,3})/
55 },
56 {
57 token: "constant.character.placeholder.csound",
58 regex: /%[#0\- +]*\d*(?:\.\d+)?[diuoxXfFeEgGaAcs]/
59 }, {
60 token: "constant.character.escape.csound",
61 regex: /%%/
62 }
63 ];
64 this.quotedStringContents = [
65 this.macroUses,
66 this.bracedStringContents
67 ];
68 var start = [
69 this.comments,
70 {
71 token: "keyword.preprocessor.csound",
72 regex: /#(?:e(?:nd(?:if)?|lse)\b|##)|@@?[ \t]*\d+/
73 }, {
74 token: "keyword.preprocessor.csound",
75 regex: /#include/,
76 push: [
77 this.comments,
78 {
79 token: "string.csound",
80 regex: /([^ \t])(?:.*?\1)/,
81 next: "pop"
82 }
83 ]
84 }, {
85 token: "keyword.preprocessor.csound",
86 regex: /#includestr/,
87 push: [
88 this.comments,
89 {
90 token: "string.csound",
91 regex: /([^ \t])(?:.*?\1)/,
92 next: "pop"
93 }
94 ]
95 }, {
96 token: "keyword.preprocessor.csound",
97 regex: /#[ \t]*define/,
98 next: "define directive"
99 }, {
100 token: "keyword.preprocessor.csound",
101 regex: /#(?:ifn?def|undef)\b/,
102 next: "macro directive"
103 },
104 this.macroUses
105 ];
106 this.$rules = {
107 "start": start,
108 "define directive": [
109 this.comments,
110 {
111 token: "entity.name.function.preprocessor.csound",
112 regex: /[A-Z_a-z]\w*/
113 }, {
114 token: "punctuation.definition.macro-parameter-name-list.begin.csound",
115 regex: /\(/,
116 next: "macro parameter name list"
117 }, {
118 token: "punctuation.definition.macro.begin.csound",
119 regex: /#/,
120 next: "macro body"
121 }
122 ],
123 "macro parameter name list": [
124 {
125 token: "variable.parameter.preprocessor.csound",
126 regex: /[A-Z_a-z]\w*/
127 }, {
128 token: "punctuation.definition.macro-parameter-name-list.end.csound",
129 regex: /\)/,
130 next: "define directive"
131 }
132 ],
133 "macro body": [
134 {
135 token: "constant.character.escape.csound",
136 regex: /\\#/
137 }, {
138 token: "punctuation.definition.macro.end.csound",
139 regex: /#/,
140 next: "start"
141 },
142 start
143 ],
144 "macro directive": [
145 this.comments,
146 {
147 token: "entity.name.function.preprocessor.csound",
148 regex: /[A-Z_a-z]\w*/,
149 next: "start"
150 }
151 ],
152 "macro parameter value list": [
153 {
154 token: "punctuation.definition.macro-parameter-value-list.end.csound",
155 regex: /\)/,
156 next: "start"
157 }, {
158 token: "punctuation.definition.string.begin.csound",
159 regex: /"/,
160 next: "macro parameter value quoted string"
161 }, this.pushRule({
162 token: "punctuation.macro-parameter-value-parenthetical.begin.csound",
163 regex: /\(/,
164 next: "macro parameter value parenthetical"
165 }), {
166 token: "punctuation.macro-parameter-value-separator.csound",
167 regex: "[#']"
168 }
169 ],
170 "macro parameter value quoted string": [
171 {
172 token: "constant.character.escape.csound",
173 regex: /\\[#'()]/
174 }, {
175 token: "invalid.illegal.csound",
176 regex: /[#'()]/
177 }, {
178 token: "punctuation.definition.string.end.csound",
179 regex: /"/,
180 next: "macro parameter value list"
181 },
182 this.quotedStringContents,
183 {
184 defaultToken: "string.quoted.csound"
185 }
186 ],
187 "macro parameter value parenthetical": [
188 {
189 token: "constant.character.escape.csound",
190 regex: /\\\)/
191 }, this.popRule({
192 token: "punctuation.macro-parameter-value-parenthetical.end.csound",
193 regex: /\)/
194 }), this.pushRule({
195 token: "punctuation.macro-parameter-value-parenthetical.begin.csound",
196 regex: /\(/,
197 next: "macro parameter value parenthetical"
198 }),
199 start
200 ]
201 };
202 };
203 oop.inherits(CsoundPreprocessorHighlightRules, TextHighlightRules);
204 (function () {
205 this.pushRule = function (params) {
206 if (Array.isArray(params.next)) {
207 for (var i = 0; i < params.next.length; i++) {
208 params.next[i] = this.embeddedRulePrefix + params.next[i];
209 }
210 }
211 return {
212 regex: params.regex, onMatch: function (value, currentState, stack, line) {
213 if (stack.length === 0)
214 stack.push(currentState);
215 if (Array.isArray(params.next)) {
216 for (var i = 0; i < params.next.length; i++) {
217 stack.push(params.next[i]);
218 }
219 }
220 else {
221 stack.push(params.next);
222 }
223 this.next = stack[stack.length - 1];
224 return params.token;
225 },
226 get next() { return Array.isArray(params.next) ? params.next[params.next.length - 1] : params.next; },
227 set next(next) {
228 if (!Array.isArray(params.next)) {
229 params.next = next;
230 }
231 },
232 get token() { return params.token; }
233 };
234 };
235 this.popRule = function (params) {
236 if (params.next) {
237 params.next = this.embeddedRulePrefix + params.next;
238 }
239 return {
240 regex: params.regex, onMatch: function (value, currentState, stack, line) {
241 stack.pop();
242 if (params.next) {
243 stack.push(params.next);
244 this.next = stack[stack.length - 1];
245 }
246 else {
247 this.next = stack.length > 1 ? stack[stack.length - 1] : stack.pop();
248 }
249 return params.token;
250 }
251 };
252 };
253 }).call(CsoundPreprocessorHighlightRules.prototype);
254 exports.CsoundPreprocessorHighlightRules = CsoundPreprocessorHighlightRules;
255
256 });
257
258 ace.define("ace/mode/csound_score_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/csound_preprocessor_highlight_rules"], function(require, exports, module){"use strict";
259 var oop = require("../lib/oop");
260 var CsoundPreprocessorHighlightRules = require("./csound_preprocessor_highlight_rules").CsoundPreprocessorHighlightRules;
261 var CsoundScoreHighlightRules = function (embeddedRulePrefix) {
262 CsoundPreprocessorHighlightRules.call(this, embeddedRulePrefix);
263 this.quotedStringContents.push({
264 token: "invalid.illegal.csound-score",
265 regex: /[^"]*$/
266 });
267 var start = this.$rules.start;
268 start.push({
269 token: "keyword.control.csound-score",
270 regex: /[aBbCdefiqstvxy]/
271 }, {
272 token: "invalid.illegal.csound-score",
273 regex: /w/
274 }, {
275 token: "constant.numeric.language.csound-score",
276 regex: /z/
277 }, {
278 token: ["keyword.control.csound-score", "constant.numeric.integer.decimal.csound-score"],
279 regex: /([nNpP][pP])(\d+)/
280 }, {
281 token: "keyword.other.csound-score",
282 regex: /[mn]/,
283 push: [
284 {
285 token: "empty",
286 regex: /$/,
287 next: "pop"
288 },
289 this.comments,
290 {
291 token: "entity.name.label.csound-score",
292 regex: /[A-Z_a-z]\w*/
293 }
294 ]
295 }, {
296 token: "keyword.preprocessor.csound-score",
297 regex: /r\b/,
298 next: "repeat section"
299 }, this.numbers, {
300 token: "keyword.operator.csound-score",
301 regex: "[!+\\-*/^%&|<>#~.]"
302 }, this.pushRule({
303 token: "punctuation.definition.string.begin.csound-score",
304 regex: /"/,
305 next: "quoted string"
306 }), this.pushRule({
307 token: "punctuation.braced-loop.begin.csound-score",
308 regex: /{/,
309 next: "loop after left brace"
310 }));
311 this.addRules({
312 "repeat section": [
313 {
314 token: "empty",
315 regex: /$/,
316 next: "start"
317 },
318 this.comments,
319 {
320 token: "constant.numeric.integer.decimal.csound-score",
321 regex: /\d+/,
322 next: "repeat section before label"
323 }
324 ],
325 "repeat section before label": [
326 {
327 token: "empty",
328 regex: /$/,
329 next: "start"
330 },
331 this.comments,
332 {
333 token: "entity.name.label.csound-score",
334 regex: /[A-Z_a-z]\w*/,
335 next: "start"
336 }
337 ],
338 "quoted string": [
339 this.popRule({
340 token: "punctuation.definition.string.end.csound-score",
341 regex: /"/
342 }),
343 this.quotedStringContents,
344 {
345 defaultToken: "string.quoted.csound-score"
346 }
347 ],
348 "loop after left brace": [
349 this.popRule({
350 token: "constant.numeric.integer.decimal.csound-score",
351 regex: /\d+/,
352 next: "loop after repeat count"
353 }),
354 this.comments,
355 {
356 token: "invalid.illegal.csound",
357 regex: /\S.*/
358 }
359 ],
360 "loop after repeat count": [
361 this.popRule({
362 token: "entity.name.function.preprocessor.csound-score",
363 regex: /[A-Z_a-z]\w*\b/,
364 next: "loop after macro name"
365 }),
366 this.comments,
367 {
368 token: "invalid.illegal.csound",
369 regex: /\S.*/
370 }
371 ],
372 "loop after macro name": [
373 start,
374 this.popRule({
375 token: "punctuation.braced-loop.end.csound-score",
376 regex: /}/
377 })
378 ]
379 });
380 this.normalizeRules();
381 };
382 oop.inherits(CsoundScoreHighlightRules, CsoundPreprocessorHighlightRules);
383 exports.CsoundScoreHighlightRules = CsoundScoreHighlightRules;
384
385 });
386
387 ace.define("ace/mode/lua_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module){"use strict";
388 var oop = require("../lib/oop");
389 var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
390 var LuaHighlightRules = function () {
391 var keywords = ("break|do|else|elseif|end|for|function|if|in|local|repeat|" +
392 "return|then|until|while|or|and|not");
393 var builtinConstants = ("true|false|nil|_G|_VERSION");
394 var functions = (
395 "string|xpcall|package|tostring|print|os|unpack|require|" +
396 "getfenv|setmetatable|next|assert|tonumber|io|rawequal|" +
397 "collectgarbage|getmetatable|module|rawset|math|debug|" +
398 "pcall|table|newproxy|type|coroutine|_G|select|gcinfo|" +
399 "pairs|rawget|loadstring|ipairs|_VERSION|dofile|setfenv|" +
400 "load|error|loadfile|" +
401 "sub|upper|len|gfind|rep|find|match|char|dump|gmatch|" +
402 "reverse|byte|format|gsub|lower|preload|loadlib|loaded|" +
403 "loaders|cpath|config|path|seeall|exit|setlocale|date|" +
404 "getenv|difftime|remove|time|clock|tmpname|rename|execute|" +
405 "lines|write|close|flush|open|output|type|read|stderr|" +
406 "stdin|input|stdout|popen|tmpfile|log|max|acos|huge|" +
407 "ldexp|pi|cos|tanh|pow|deg|tan|cosh|sinh|random|randomseed|" +
408 "frexp|ceil|floor|rad|abs|sqrt|modf|asin|min|mod|fmod|log10|" +
409 "atan2|exp|sin|atan|getupvalue|debug|sethook|getmetatable|" +
410 "gethook|setmetatable|setlocal|traceback|setfenv|getinfo|" +
411 "setupvalue|getlocal|getregistry|getfenv|setn|insert|getn|" +
412 "foreachi|maxn|foreach|concat|sort|remove|resume|yield|" +
413 "status|wrap|create|running|" +
414 "__add|__sub|__mod|__unm|__concat|__lt|__index|__call|__gc|__metatable|" +
415 "__mul|__div|__pow|__len|__eq|__le|__newindex|__tostring|__mode|__tonumber");
416 var stdLibaries = ("string|package|os|io|math|debug|table|coroutine");
417 var deprecatedIn5152 = ("setn|foreach|foreachi|gcinfo|log10|maxn");
418 var keywordMapper = this.createKeywordMapper({
419 "keyword": keywords,
420 "support.function": functions,
421 "keyword.deprecated": deprecatedIn5152,
422 "constant.library": stdLibaries,
423 "constant.language": builtinConstants,
424 "variable.language": "self"
425 }, "identifier");
426 var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
427 var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
428 var integer = "(?:" + decimalInteger + "|" + hexInteger + ")";
429 var fraction = "(?:\\.\\d+)";
430 var intPart = "(?:\\d+)";
431 var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
432 var floatNumber = "(?:" + pointFloat + ")";
433 this.$rules = {
434 "start": [{
435 stateName: "bracketedComment",
436 onMatch: function (value, currentState, stack) {
437 stack.unshift(this.next, value.length - 2, currentState);
438 return "comment";
439 },
440 regex: /\-\-\[=*\[/,
441 next: [
442 {
443 onMatch: function (value, currentState, stack) {
444 if (value.length == stack[1]) {
445 stack.shift();
446 stack.shift();
447 this.next = stack.shift();
448 }
449 else {
450 this.next = "";
451 }
452 return "comment";
453 },
454 regex: /\]=*\]/,
455 next: "start"
456 }, {
457 defaultToken: "comment"
458 }
459 ]
460 },
461 {
462 token: "comment",
463 regex: "\\-\\-.*$"
464 },
465 {
466 stateName: "bracketedString",
467 onMatch: function (value, currentState, stack) {
468 stack.unshift(this.next, value.length, currentState);
469 return "string.start";
470 },
471 regex: /\[=*\[/,
472 next: [
473 {
474 onMatch: function (value, currentState, stack) {
475 if (value.length == stack[1]) {
476 stack.shift();
477 stack.shift();
478 this.next = stack.shift();
479 }
480 else {
481 this.next = "";
482 }
483 return "string.end";
484 },
485 regex: /\]=*\]/,
486 next: "start"
487 }, {
488 defaultToken: "string"
489 }
490 ]
491 },
492 {
493 token: "string", // " string
494 regex: '"(?:[^\\\\]|\\\\.)*?"'
495 }, {
496 token: "string", // ' string
497 regex: "'(?:[^\\\\]|\\\\.)*?'"
498 }, {
499 token: "constant.numeric", // float
500 regex: floatNumber
501 }, {
502 token: "constant.numeric", // integer
503 regex: integer + "\\b"
504 }, {
505 token: keywordMapper,
506 regex: "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
507 }, {
508 token: "keyword.operator",
509 regex: "\\+|\\-|\\*|\\/|%|\\#|\\^|~|<|>|<=|=>|==|~=|=|\\:|\\.\\.\\.|\\.\\."
510 }, {
511 token: "paren.lparen",
512 regex: "[\\[\\(\\{]"
513 }, {
514 token: "paren.rparen",
515 regex: "[\\]\\)\\}]"
516 }, {
517 token: "text",
518 regex: "\\s+|\\w+"
519 }]
520 };
521 this.normalizeRules();
522 };
523 oop.inherits(LuaHighlightRules, TextHighlightRules);
524 exports.LuaHighlightRules = LuaHighlightRules;
525
526 });
527
528 ace.define("ace/mode/python_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module){/*
529 * TODO: python delimiters
530 */
531 "use strict";
532 var oop = require("../lib/oop");
533 var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
534 var PythonHighlightRules = function () {
535 var keywords = ("and|as|assert|break|class|continue|def|del|elif|else|except|exec|" +
536 "finally|for|from|global|if|import|in|is|lambda|not|or|pass|print|" +
537 "raise|return|try|while|with|yield|async|await|nonlocal");
538 var builtinConstants = ("True|False|None|NotImplemented|Ellipsis|__debug__");
539 var builtinFunctions = ("abs|divmod|input|open|staticmethod|all|enumerate|int|ord|str|any|" +
540 "eval|isinstance|pow|sum|basestring|execfile|issubclass|print|super|" +
541 "binfile|bin|iter|property|tuple|bool|filter|len|range|type|bytearray|" +
542 "float|list|raw_input|unichr|callable|format|locals|reduce|unicode|" +
543 "chr|frozenset|long|reload|vars|classmethod|getattr|map|repr|xrange|" +
544 "cmp|globals|max|reversed|zip|compile|hasattr|memoryview|round|" +
545 "__import__|complex|hash|min|apply|delattr|help|next|setattr|set|" +
546 "buffer|dict|hex|object|slice|coerce|dir|id|oct|sorted|intern|" +
547 "ascii|breakpoint|bytes");
548 var keywordMapper = this.createKeywordMapper({
549 "invalid.deprecated": "debugger",
550 "support.function": builtinFunctions,
551 "variable.language": "self|cls",
552 "constant.language": builtinConstants,
553 "keyword": keywords
554 }, "identifier");
555 var strPre = "[uU]?";
556 var strRawPre = "[rR]";
557 var strFormatPre = "[fF]";
558 var strRawFormatPre = "(?:[rR][fF]|[fF][rR])";
559 var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
560 var octInteger = "(?:0[oO]?[0-7]+)";
561 var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
562 var binInteger = "(?:0[bB][01]+)";
563 var integer = "(?:" + decimalInteger + "|" + octInteger + "|" + hexInteger + "|" + binInteger + ")";
564 var exponent = "(?:[eE][+-]?\\d+)";
565 var fraction = "(?:\\.\\d+)";
566 var intPart = "(?:\\d+)";
567 var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
568 var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + exponent + ")";
569 var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
570 var stringEscape = "\\\\(x[0-9A-Fa-f]{2}|[0-7]{3}|[\\\\abfnrtv'\"]|U[0-9A-Fa-f]{8}|u[0-9A-Fa-f]{4})";
571 this.$rules = {
572 "start": [{
573 token: "comment",
574 regex: "#.*$"
575 }, {
576 token: "string", // multi line """ string start
577 regex: strPre + '"{3}',
578 next: "qqstring3"
579 }, {
580 token: "string", // " string
581 regex: strPre + '"(?=.)',
582 next: "qqstring"
583 }, {
584 token: "string", // multi line ''' string start
585 regex: strPre + "'{3}",
586 next: "qstring3"
587 }, {
588 token: "string", // ' string
589 regex: strPre + "'(?=.)",
590 next: "qstring"
591 }, {
592 token: "string",
593 regex: strRawPre + '"{3}',
594 next: "rawqqstring3"
595 }, {
596 token: "string",
597 regex: strRawPre + '"(?=.)',
598 next: "rawqqstring"
599 }, {
600 token: "string",
601 regex: strRawPre + "'{3}",
602 next: "rawqstring3"
603 }, {
604 token: "string",
605 regex: strRawPre + "'(?=.)",
606 next: "rawqstring"
607 }, {
608 token: "string",
609 regex: strFormatPre + '"{3}',
610 next: "fqqstring3"
611 }, {
612 token: "string",
613 regex: strFormatPre + '"(?=.)',
614 next: "fqqstring"
615 }, {
616 token: "string",
617 regex: strFormatPre + "'{3}",
618 next: "fqstring3"
619 }, {
620 token: "string",
621 regex: strFormatPre + "'(?=.)",
622 next: "fqstring"
623 }, {
624 token: "string",
625 regex: strRawFormatPre + '"{3}',
626 next: "rfqqstring3"
627 }, {
628 token: "string",
629 regex: strRawFormatPre + '"(?=.)',
630 next: "rfqqstring"
631 }, {
632 token: "string",
633 regex: strRawFormatPre + "'{3}",
634 next: "rfqstring3"
635 }, {
636 token: "string",
637 regex: strRawFormatPre + "'(?=.)",
638 next: "rfqstring"
639 }, {
640 token: "keyword.operator",
641 regex: "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|%|@|<<|>>|&|\\||\\^|~|<|>|<=|=>|==|!=|<>|="
642 }, {
643 token: "punctuation",
644 regex: ",|:|;|\\->|\\+=|\\-=|\\*=|\\/=|\\/\\/=|%=|@=|&=|\\|=|^=|>>=|<<=|\\*\\*="
645 }, {
646 token: "paren.lparen",
647 regex: "[\\[\\(\\{]"
648 }, {
649 token: "paren.rparen",
650 regex: "[\\]\\)\\}]"
651 }, {
652 token: ["keyword", "text", "entity.name.function"],
653 regex: "(def|class)(\\s+)([\\u00BF-\\u1FFF\\u2C00-\\uD7FF\\w]+)"
654 }, {
655 token: "text",
656 regex: "\\s+"
657 }, {
658 include: "constants"
659 }],
660 "qqstring3": [{
661 token: "constant.language.escape",
662 regex: stringEscape
663 }, {
664 token: "string", // multi line """ string end
665 regex: '"{3}',
666 next: "start"
667 }, {
668 defaultToken: "string"
669 }],
670 "qstring3": [{
671 token: "constant.language.escape",
672 regex: stringEscape
673 }, {
674 token: "string", // multi line ''' string end
675 regex: "'{3}",
676 next: "start"
677 }, {
678 defaultToken: "string"
679 }],
680 "qqstring": [{
681 token: "constant.language.escape",
682 regex: stringEscape
683 }, {
684 token: "string",
685 regex: "\\\\$",
686 next: "qqstring"
687 }, {
688 token: "string",
689 regex: '"|$',
690 next: "start"
691 }, {
692 defaultToken: "string"
693 }],
694 "qstring": [{
695 token: "constant.language.escape",
696 regex: stringEscape
697 }, {
698 token: "string",
699 regex: "\\\\$",
700 next: "qstring"
701 }, {
702 token: "string",
703 regex: "'|$",
704 next: "start"
705 }, {
706 defaultToken: "string"
707 }],
708 "rawqqstring3": [{
709 token: "string", // multi line """ string end
710 regex: '"{3}',
711 next: "start"
712 }, {
713 defaultToken: "string"
714 }],
715 "rawqstring3": [{
716 token: "string", // multi line ''' string end
717 regex: "'{3}",
718 next: "start"
719 }, {
720 defaultToken: "string"
721 }],
722 "rawqqstring": [{
723 token: "string",
724 regex: "\\\\$",
725 next: "rawqqstring"
726 }, {
727 token: "string",
728 regex: '"|$',
729 next: "start"
730 }, {
731 defaultToken: "string"
732 }],
733 "rawqstring": [{
734 token: "string",
735 regex: "\\\\$",
736 next: "rawqstring"
737 }, {
738 token: "string",
739 regex: "'|$",
740 next: "start"
741 }, {
742 defaultToken: "string"
743 }],
744 "fqqstring3": [{
745 token: "constant.language.escape",
746 regex: stringEscape
747 }, {
748 token: "string", // multi line """ string end
749 regex: '"{3}',
750 next: "start"
751 }, {
752 token: "paren.lparen",
753 regex: "{",
754 push: "fqstringParRules"
755 }, {
756 defaultToken: "string"
757 }],
758 "fqstring3": [{
759 token: "constant.language.escape",
760 regex: stringEscape
761 }, {
762 token: "string", // multi line ''' string end
763 regex: "'{3}",
764 next: "start"
765 }, {
766 token: "paren.lparen",
767 regex: "{",
768 push: "fqstringParRules"
769 }, {
770 defaultToken: "string"
771 }],
772 "fqqstring": [{
773 token: "constant.language.escape",
774 regex: stringEscape
775 }, {
776 token: "string",
777 regex: "\\\\$",
778 next: "fqqstring"
779 }, {
780 token: "string",
781 regex: '"|$',
782 next: "start"
783 }, {
784 token: "paren.lparen",
785 regex: "{",
786 push: "fqstringParRules"
787 }, {
788 defaultToken: "string"
789 }],
790 "fqstring": [{
791 token: "constant.language.escape",
792 regex: stringEscape
793 }, {
794 token: "string",
795 regex: "'|$",
796 next: "start"
797 }, {
798 token: "paren.lparen",
799 regex: "{",
800 push: "fqstringParRules"
801 }, {
802 defaultToken: "string"
803 }],
804 "rfqqstring3": [{
805 token: "string", // multi line """ string end
806 regex: '"{3}',
807 next: "start"
808 }, {
809 token: "paren.lparen",
810 regex: "{",
811 push: "fqstringParRules"
812 }, {
813 defaultToken: "string"
814 }],
815 "rfqstring3": [{
816 token: "string", // multi line ''' string end
817 regex: "'{3}",
818 next: "start"
819 }, {
820 token: "paren.lparen",
821 regex: "{",
822 push: "fqstringParRules"
823 }, {
824 defaultToken: "string"
825 }],
826 "rfqqstring": [{
827 token: "string",
828 regex: "\\\\$",
829 next: "rfqqstring"
830 }, {
831 token: "string",
832 regex: '"|$',
833 next: "start"
834 }, {
835 token: "paren.lparen",
836 regex: "{",
837 push: "fqstringParRules"
838 }, {
839 defaultToken: "string"
840 }],
841 "rfqstring": [{
842 token: "string",
843 regex: "'|$",
844 next: "start"
845 }, {
846 token: "paren.lparen",
847 regex: "{",
848 push: "fqstringParRules"
849 }, {
850 defaultToken: "string"
851 }],
852 "fqstringParRules": [{
853 token: "paren.lparen",
854 regex: "[\\[\\(]"
855 }, {
856 token: "paren.rparen",
857 regex: "[\\]\\)]"
858 }, {
859 token: "string",
860 regex: "\\s+"
861 }, {
862 token: "string",
863 regex: "'[^']*'"
864 }, {
865 token: "string",
866 regex: '"[^"]*"'
867 }, {
868 token: "function.support",
869 regex: "(!s|!r|!a)"
870 }, {
871 include: "constants"
872 }, {
873 token: 'paren.rparen',
874 regex: "}",
875 next: 'pop'
876 }, {
877 token: 'paren.lparen',
878 regex: "{",
879 push: "fqstringParRules"
880 }],
881 "constants": [{
882 token: "constant.numeric", // imaginary
883 regex: "(?:" + floatNumber + "|\\d+)[jJ]\\b"
884 }, {
885 token: "constant.numeric", // float
886 regex: floatNumber
887 }, {
888 token: "constant.numeric", // long integer
889 regex: integer + "[lL]\\b"
890 }, {
891 token: "constant.numeric", // integer
892 regex: integer + "\\b"
893 }, {
894 token: ["punctuation", "function.support"], // method
895 regex: "(\\.)([a-zA-Z_]+)\\b"
896 }, {
897 token: keywordMapper,
898 regex: "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
899 }]
900 };
901 this.normalizeRules();
902 };
903 oop.inherits(PythonHighlightRules, TextHighlightRules);
904 exports.PythonHighlightRules = PythonHighlightRules;
905
906 });
907
908 ace.define("ace/mode/csound_orchestra_highlight_rules",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/mode/csound_preprocessor_highlight_rules","ace/mode/csound_score_highlight_rules","ace/mode/lua_highlight_rules","ace/mode/python_highlight_rules"], function(require, exports, module){"use strict";
909 var lang = require("../lib/lang");
910 var oop = require("../lib/oop");
911 var CsoundPreprocessorHighlightRules = require("./csound_preprocessor_highlight_rules").CsoundPreprocessorHighlightRules;
912 var CsoundScoreHighlightRules = require("./csound_score_highlight_rules").CsoundScoreHighlightRules;
913 var LuaHighlightRules = require("./lua_highlight_rules").LuaHighlightRules;
914 var PythonHighlightRules = require("./python_highlight_rules").PythonHighlightRules;
915 var CsoundOrchestraHighlightRules = function (embeddedRulePrefix) {
916 CsoundPreprocessorHighlightRules.call(this, embeddedRulePrefix);
917 var opcodes = [
918 "ATSadd",
919 "ATSaddnz",
920 "ATSbufread",
921 "ATScross",
922 "ATSinfo",
923 "ATSinterpread",
924 "ATSpartialtap",
925 "ATSread",
926 "ATSreadnz",
927 "ATSsinnoi",
928 "FLbox",
929 "FLbutBank",
930 "FLbutton",
931 "FLcloseButton",
932 "FLcolor",
933 "FLcolor2",
934 "FLcount",
935 "FLexecButton",
936 "FLgetsnap",
937 "FLgroup",
938 "FLgroupEnd",
939 "FLgroup_end",
940 "FLhide",
941 "FLhvsBox",
942 "FLhvsBoxSetValue",
943 "FLjoy",
944 "FLkeyIn",
945 "FLknob",
946 "FLlabel",
947 "FLloadsnap",
948 "FLmouse",
949 "FLpack",
950 "FLpackEnd",
951 "FLpack_end",
952 "FLpanel",
953 "FLpanelEnd",
954 "FLpanel_end",
955 "FLprintk",
956 "FLprintk2",
957 "FLroller",
958 "FLrun",
959 "FLsavesnap",
960 "FLscroll",
961 "FLscrollEnd",
962 "FLscroll_end",
963 "FLsetAlign",
964 "FLsetBox",
965 "FLsetColor",
966 "FLsetColor2",
967 "FLsetFont",
968 "FLsetPosition",
969 "FLsetSize",
970 "FLsetSnapGroup",
971 "FLsetText",
972 "FLsetTextColor",
973 "FLsetTextSize",
974 "FLsetTextType",
975 "FLsetVal",
976 "FLsetVal_i",
977 "FLsetVali",
978 "FLsetsnap",
979 "FLshow",
980 "FLslidBnk",
981 "FLslidBnk2",
982 "FLslidBnk2Set",
983 "FLslidBnk2Setk",
984 "FLslidBnkGetHandle",
985 "FLslidBnkSet",
986 "FLslidBnkSetk",
987 "FLslider",
988 "FLtabs",
989 "FLtabsEnd",
990 "FLtabs_end",
991 "FLtext",
992 "FLupdate",
993 "FLvalue",
994 "FLvkeybd",
995 "FLvslidBnk",
996 "FLvslidBnk2",
997 "FLxyin",
998 "JackoAudioIn",
999 "JackoAudioInConnect",
1000 "JackoAudioOut",
1001 "JackoAudioOutConnect",
1002 "JackoFreewheel",
1003 "JackoInfo",
1004 "JackoInit",
1005 "JackoMidiInConnect",
1006 "JackoMidiOut",
1007 "JackoMidiOutConnect",
1008 "JackoNoteOut",
1009 "JackoOn",
1010 "JackoTransport",
1011 "K35_hpf",
1012 "K35_lpf",
1013 "MixerClear",
1014 "MixerGetLevel",
1015 "MixerReceive",
1016 "MixerSend",
1017 "MixerSetLevel",
1018 "MixerSetLevel_i",
1019 "OSCbundle",
1020 "OSCcount",
1021 "OSCinit",
1022 "OSCinitM",
1023 "OSClisten",
1024 "OSCraw",
1025 "OSCsend",
1026 "OSCsend_lo",
1027 "S",
1028 "STKBandedWG",
1029 "STKBeeThree",
1030 "STKBlowBotl",
1031 "STKBlowHole",
1032 "STKBowed",
1033 "STKBrass",
1034 "STKClarinet",
1035 "STKDrummer",
1036 "STKFMVoices",
1037 "STKFlute",
1038 "STKHevyMetl",
1039 "STKMandolin",
1040 "STKModalBar",
1041 "STKMoog",
1042 "STKPercFlut",
1043 "STKPlucked",
1044 "STKResonate",
1045 "STKRhodey",
1046 "STKSaxofony",
1047 "STKShakers",
1048 "STKSimple",
1049 "STKSitar",
1050 "STKStifKarp",
1051 "STKTubeBell",
1052 "STKVoicForm",
1053 "STKWhistle",
1054 "STKWurley",
1055 "a",
1056 "abs",
1057 "active",
1058 "adsr",
1059 "adsyn",
1060 "adsynt",
1061 "adsynt2",
1062 "aftouch",
1063 "allpole",
1064 "alpass",
1065 "alwayson",
1066 "ampdb",
1067 "ampdbfs",
1068 "ampmidi",
1069 "ampmidicurve",
1070 "ampmidid",
1071 "apoleparams",
1072 "arduinoRead",
1073 "arduinoReadF",
1074 "arduinoStart",
1075 "arduinoStop",
1076 "areson",
1077 "aresonk",
1078 "atone",
1079 "atonek",
1080 "atonex",
1081 "autocorr",
1082 "babo",
1083 "balance",
1084 "balance2",
1085 "bamboo",
1086 "barmodel",
1087 "bbcutm",
1088 "bbcuts",
1089 "betarand",
1090 "bexprnd",
1091 "bformdec1",
1092 "bformdec2",
1093 "bformenc1",
1094 "binit",
1095 "biquad",
1096 "biquada",
1097 "birnd",
1098 "bob",
1099 "bpf",
1100 "bpfcos",
1101 "bqrez",
1102 "butbp",
1103 "butbr",
1104 "buthp",
1105 "butlp",
1106 "butterbp",
1107 "butterbr",
1108 "butterhp",
1109 "butterlp",
1110 "button",
1111 "buzz",
1112 "c2r",
1113 "cabasa",
1114 "cauchy",
1115 "cauchyi",
1116 "cbrt",
1117 "ceil",
1118 "cell",
1119 "cent",
1120 "centroid",
1121 "ceps",
1122 "cepsinv",
1123 "chanctrl",
1124 "changed",
1125 "changed2",
1126 "chani",
1127 "chano",
1128 "chebyshevpoly",
1129 "checkbox",
1130 "chn_S",
1131 "chn_a",
1132 "chn_k",
1133 "chnclear",
1134 "chnexport",
1135 "chnget",
1136 "chngeta",
1137 "chngeti",
1138 "chngetk",
1139 "chngetks",
1140 "chngets",
1141 "chnmix",
1142 "chnparams",
1143 "chnset",
1144 "chnseta",
1145 "chnseti",
1146 "chnsetk",
1147 "chnsetks",
1148 "chnsets",
1149 "chuap",
1150 "clear",
1151 "clfilt",
1152 "clip",
1153 "clockoff",
1154 "clockon",
1155 "cmp",
1156 "cmplxprod",
1157 "cntCreate",
1158 "cntCycles",
1159 "cntDelete",
1160 "cntDelete_i",
1161 "cntRead",
1162 "cntReset",
1163 "cntState",
1164 "comb",
1165 "combinv",
1166 "compilecsd",
1167 "compileorc",
1168 "compilestr",
1169 "compress",
1170 "compress2",
1171 "connect",
1172 "control",
1173 "convle",
1174 "convolve",
1175 "copya2ftab",
1176 "copyf2array",
1177 "cos",
1178 "cosh",
1179 "cosinv",
1180 "cosseg",
1181 "cossegb",
1182 "cossegr",
1183 "count",
1184 "count_i",
1185 "cps2pch",
1186 "cpsmidi",
1187 "cpsmidib",
1188 "cpsmidinn",
1189 "cpsoct",
1190 "cpspch",
1191 "cpstmid",
1192 "cpstun",
1193 "cpstuni",
1194 "cpsxpch",
1195 "cpumeter",
1196 "cpuprc",
1197 "cross2",
1198 "crossfm",
1199 "crossfmi",
1200 "crossfmpm",
1201 "crossfmpmi",
1202 "crosspm",
1203 "crosspmi",
1204 "crunch",
1205 "ctlchn",
1206 "ctrl14",
1207 "ctrl21",
1208 "ctrl7",
1209 "ctrlinit",
1210 "ctrlpreset",
1211 "ctrlprint",
1212 "ctrlprintpresets",
1213 "ctrlsave",
1214 "ctrlselect",
1215 "cuserrnd",
1216 "dam",
1217 "date",
1218 "dates",
1219 "db",
1220 "dbamp",
1221 "dbfsamp",
1222 "dcblock",
1223 "dcblock2",
1224 "dconv",
1225 "dct",
1226 "dctinv",
1227 "deinterleave",
1228 "delay",
1229 "delay1",
1230 "delayk",
1231 "delayr",
1232 "delayw",
1233 "deltap",
1234 "deltap3",
1235 "deltapi",
1236 "deltapn",
1237 "deltapx",
1238 "deltapxw",
1239 "denorm",
1240 "diff",
1241 "diode_ladder",
1242 "directory",
1243 "diskgrain",
1244 "diskin",
1245 "diskin2",
1246 "dispfft",
1247 "display",
1248 "distort",
1249 "distort1",
1250 "divz",
1251 "doppler",
1252 "dot",
1253 "downsamp",
1254 "dripwater",
1255 "dssiactivate",
1256 "dssiaudio",
1257 "dssictls",
1258 "dssiinit",
1259 "dssilist",
1260 "dumpk",
1261 "dumpk2",
1262 "dumpk3",
1263 "dumpk4",
1264 "duserrnd",
1265 "dust",
1266 "dust2",
1267 "elapsedcycles",
1268 "elapsedtime",
1269 "envlpx",
1270 "envlpxr",
1271 "ephasor",
1272 "eqfil",
1273 "evalstr",
1274 "event",
1275 "event_i",
1276 "eventcycles",
1277 "eventtime",
1278 "exciter",
1279 "exitnow",
1280 "exp",
1281 "expcurve",
1282 "expon",
1283 "exprand",
1284 "exprandi",
1285 "expseg",
1286 "expsega",
1287 "expsegb",
1288 "expsegba",
1289 "expsegr",
1290 "fareylen",
1291 "fareyleni",
1292 "faustaudio",
1293 "faustcompile",
1294 "faustctl",
1295 "faustdsp",
1296 "faustgen",
1297 "faustplay",
1298 "fft",
1299 "fftinv",
1300 "ficlose",
1301 "filebit",
1302 "filelen",
1303 "filenchnls",
1304 "filepeak",
1305 "filescal",
1306 "filesr",
1307 "filevalid",
1308 "fillarray",
1309 "filter2",
1310 "fin",
1311 "fini",
1312 "fink",
1313 "fiopen",
1314 "flanger",
1315 "flashtxt",
1316 "flooper",
1317 "flooper2",
1318 "floor",
1319 "fluidAllOut",
1320 "fluidCCi",
1321 "fluidCCk",
1322 "fluidControl",
1323 "fluidEngine",
1324 "fluidInfo",
1325 "fluidLoad",
1326 "fluidNote",
1327 "fluidOut",
1328 "fluidProgramSelect",
1329 "fluidSetInterpMethod",
1330 "fmanal",
1331 "fmax",
1332 "fmb3",
1333 "fmbell",
1334 "fmin",
1335 "fmmetal",
1336 "fmod",
1337 "fmpercfl",
1338 "fmrhode",
1339 "fmvoice",
1340 "fmwurlie",
1341 "fof",
1342 "fof2",
1343 "fofilter",
1344 "fog",
1345 "fold",
1346 "follow",
1347 "follow2",
1348 "foscil",
1349 "foscili",
1350 "fout",
1351 "fouti",
1352 "foutir",
1353 "foutk",
1354 "fprintks",
1355 "fprints",
1356 "frac",
1357 "fractalnoise",
1358 "framebuffer",
1359 "freeverb",
1360 "ftaudio",
1361 "ftchnls",
1362 "ftconv",
1363 "ftcps",
1364 "ftexists",
1365 "ftfree",
1366 "ftgen",
1367 "ftgenonce",
1368 "ftgentmp",
1369 "ftlen",
1370 "ftload",
1371 "ftloadk",
1372 "ftlptim",
1373 "ftmorf",
1374 "ftom",
1375 "ftprint",
1376 "ftresize",
1377 "ftresizei",
1378 "ftsamplebank",
1379 "ftsave",
1380 "ftsavek",
1381 "ftset",
1382 "ftslice",
1383 "ftslicei",
1384 "ftsr",
1385 "gain",
1386 "gainslider",
1387 "gauss",
1388 "gaussi",
1389 "gausstrig",
1390 "gbuzz",
1391 "genarray",
1392 "genarray_i",
1393 "gendy",
1394 "gendyc",
1395 "gendyx",
1396 "getcfg",
1397 "getcol",
1398 "getftargs",
1399 "getrow",
1400 "getseed",
1401 "gogobel",
1402 "grain",
1403 "grain2",
1404 "grain3",
1405 "granule",
1406 "gtadsr",
1407 "gtf",
1408 "guiro",
1409 "harmon",
1410 "harmon2",
1411 "harmon3",
1412 "harmon4",
1413 "hdf5read",
1414 "hdf5write",
1415 "hilbert",
1416 "hilbert2",
1417 "hrtfearly",
1418 "hrtfmove",
1419 "hrtfmove2",
1420 "hrtfreverb",
1421 "hrtfstat",
1422 "hsboscil",
1423 "hvs1",
1424 "hvs2",
1425 "hvs3",
1426 "hypot",
1427 "i",
1428 "ihold",
1429 "imagecreate",
1430 "imagefree",
1431 "imagegetpixel",
1432 "imageload",
1433 "imagesave",
1434 "imagesetpixel",
1435 "imagesize",
1436 "in",
1437 "in32",
1438 "inch",
1439 "inh",
1440 "init",
1441 "initc14",
1442 "initc21",
1443 "initc7",
1444 "inleta",
1445 "inletf",
1446 "inletk",
1447 "inletkid",
1448 "inletv",
1449 "ino",
1450 "inq",
1451 "inrg",
1452 "ins",
1453 "insglobal",
1454 "insremot",
1455 "int",
1456 "integ",
1457 "interleave",
1458 "interp",
1459 "invalue",
1460 "inx",
1461 "inz",
1462 "jacktransport",
1463 "jitter",
1464 "jitter2",
1465 "joystick",
1466 "jspline",
1467 "k",
1468 "la_i_add_mc",
1469 "la_i_add_mr",
1470 "la_i_add_vc",
1471 "la_i_add_vr",
1472 "la_i_assign_mc",
1473 "la_i_assign_mr",
1474 "la_i_assign_t",
1475 "la_i_assign_vc",
1476 "la_i_assign_vr",
1477 "la_i_conjugate_mc",
1478 "la_i_conjugate_mr",
1479 "la_i_conjugate_vc",
1480 "la_i_conjugate_vr",
1481 "la_i_distance_vc",
1482 "la_i_distance_vr",
1483 "la_i_divide_mc",
1484 "la_i_divide_mr",
1485 "la_i_divide_vc",
1486 "la_i_divide_vr",
1487 "la_i_dot_mc",
1488 "la_i_dot_mc_vc",
1489 "la_i_dot_mr",
1490 "la_i_dot_mr_vr",
1491 "la_i_dot_vc",
1492 "la_i_dot_vr",
1493 "la_i_get_mc",
1494 "la_i_get_mr",
1495 "la_i_get_vc",
1496 "la_i_get_vr",
1497 "la_i_invert_mc",
1498 "la_i_invert_mr",
1499 "la_i_lower_solve_mc",
1500 "la_i_lower_solve_mr",
1501 "la_i_lu_det_mc",
1502 "la_i_lu_det_mr",
1503 "la_i_lu_factor_mc",
1504 "la_i_lu_factor_mr",
1505 "la_i_lu_solve_mc",
1506 "la_i_lu_solve_mr",
1507 "la_i_mc_create",
1508 "la_i_mc_set",
1509 "la_i_mr_create",
1510 "la_i_mr_set",
1511 "la_i_multiply_mc",
1512 "la_i_multiply_mr",
1513 "la_i_multiply_vc",
1514 "la_i_multiply_vr",
1515 "la_i_norm1_mc",
1516 "la_i_norm1_mr",
1517 "la_i_norm1_vc",
1518 "la_i_norm1_vr",
1519 "la_i_norm_euclid_mc",
1520 "la_i_norm_euclid_mr",
1521 "la_i_norm_euclid_vc",
1522 "la_i_norm_euclid_vr",
1523 "la_i_norm_inf_mc",
1524 "la_i_norm_inf_mr",
1525 "la_i_norm_inf_vc",
1526 "la_i_norm_inf_vr",
1527 "la_i_norm_max_mc",
1528 "la_i_norm_max_mr",
1529 "la_i_print_mc",
1530 "la_i_print_mr",
1531 "la_i_print_vc",
1532 "la_i_print_vr",
1533 "la_i_qr_eigen_mc",
1534 "la_i_qr_eigen_mr",
1535 "la_i_qr_factor_mc",
1536 "la_i_qr_factor_mr",
1537 "la_i_qr_sym_eigen_mc",
1538 "la_i_qr_sym_eigen_mr",
1539 "la_i_random_mc",
1540 "la_i_random_mr",
1541 "la_i_random_vc",
1542 "la_i_random_vr",
1543 "la_i_size_mc",
1544 "la_i_size_mr",
1545 "la_i_size_vc",
1546 "la_i_size_vr",
1547 "la_i_subtract_mc",
1548 "la_i_subtract_mr",
1549 "la_i_subtract_vc",
1550 "la_i_subtract_vr",
1551 "la_i_t_assign",
1552 "la_i_trace_mc",
1553 "la_i_trace_mr",
1554 "la_i_transpose_mc",
1555 "la_i_transpose_mr",
1556 "la_i_upper_solve_mc",
1557 "la_i_upper_solve_mr",
1558 "la_i_vc_create",
1559 "la_i_vc_set",
1560 "la_i_vr_create",
1561 "la_i_vr_set",
1562 "la_k_a_assign",
1563 "la_k_add_mc",
1564 "la_k_add_mr",
1565 "la_k_add_vc",
1566 "la_k_add_vr",
1567 "la_k_assign_a",
1568 "la_k_assign_f",
1569 "la_k_assign_mc",
1570 "la_k_assign_mr",
1571 "la_k_assign_t",
1572 "la_k_assign_vc",
1573 "la_k_assign_vr",
1574 "la_k_conjugate_mc",
1575 "la_k_conjugate_mr",
1576 "la_k_conjugate_vc",
1577 "la_k_conjugate_vr",
1578 "la_k_current_f",
1579 "la_k_current_vr",
1580 "la_k_distance_vc",
1581 "la_k_distance_vr",
1582 "la_k_divide_mc",
1583 "la_k_divide_mr",
1584 "la_k_divide_vc",
1585 "la_k_divide_vr",
1586 "la_k_dot_mc",
1587 "la_k_dot_mc_vc",
1588 "la_k_dot_mr",
1589 "la_k_dot_mr_vr",
1590 "la_k_dot_vc",
1591 "la_k_dot_vr",
1592 "la_k_f_assign",
1593 "la_k_get_mc",
1594 "la_k_get_mr",
1595 "la_k_get_vc",
1596 "la_k_get_vr",
1597 "la_k_invert_mc",
1598 "la_k_invert_mr",
1599 "la_k_lower_solve_mc",
1600 "la_k_lower_solve_mr",
1601 "la_k_lu_det_mc",
1602 "la_k_lu_det_mr",
1603 "la_k_lu_factor_mc",
1604 "la_k_lu_factor_mr",
1605 "la_k_lu_solve_mc",
1606 "la_k_lu_solve_mr",
1607 "la_k_mc_set",
1608 "la_k_mr_set",
1609 "la_k_multiply_mc",
1610 "la_k_multiply_mr",
1611 "la_k_multiply_vc",
1612 "la_k_multiply_vr",
1613 "la_k_norm1_mc",
1614 "la_k_norm1_mr",
1615 "la_k_norm1_vc",
1616 "la_k_norm1_vr",
1617 "la_k_norm_euclid_mc",
1618 "la_k_norm_euclid_mr",
1619 "la_k_norm_euclid_vc",
1620 "la_k_norm_euclid_vr",
1621 "la_k_norm_inf_mc",
1622 "la_k_norm_inf_mr",
1623 "la_k_norm_inf_vc",
1624 "la_k_norm_inf_vr",
1625 "la_k_norm_max_mc",
1626 "la_k_norm_max_mr",
1627 "la_k_qr_eigen_mc",
1628 "la_k_qr_eigen_mr",
1629 "la_k_qr_factor_mc",
1630 "la_k_qr_factor_mr",
1631 "la_k_qr_sym_eigen_mc",
1632 "la_k_qr_sym_eigen_mr",
1633 "la_k_random_mc",
1634 "la_k_random_mr",
1635 "la_k_random_vc",
1636 "la_k_random_vr",
1637 "la_k_subtract_mc",
1638 "la_k_subtract_mr",
1639 "la_k_subtract_vc",
1640 "la_k_subtract_vr",
1641 "la_k_t_assign",
1642 "la_k_trace_mc",
1643 "la_k_trace_mr",
1644 "la_k_upper_solve_mc",
1645 "la_k_upper_solve_mr",
1646 "la_k_vc_set",
1647 "la_k_vr_set",
1648 "lag",
1649 "lagud",
1650 "lastcycle",
1651 "lenarray",
1652 "lfo",
1653 "lfsr",
1654 "limit",
1655 "limit1",
1656 "lincos",
1657 "line",
1658 "linen",
1659 "linenr",
1660 "lineto",
1661 "link_beat_force",
1662 "link_beat_get",
1663 "link_beat_request",
1664 "link_create",
1665 "link_enable",
1666 "link_is_enabled",
1667 "link_metro",
1668 "link_peers",
1669 "link_tempo_get",
1670 "link_tempo_set",
1671 "linlin",
1672 "linrand",
1673 "linseg",
1674 "linsegb",
1675 "linsegr",
1676 "liveconv",
1677 "locsend",
1678 "locsig",
1679 "log",
1680 "log10",
1681 "log2",
1682 "logbtwo",
1683 "logcurve",
1684 "loopseg",
1685 "loopsegp",
1686 "looptseg",
1687 "loopxseg",
1688 "lorenz",
1689 "loscil",
1690 "loscil3",
1691 "loscil3phs",
1692 "loscilphs",
1693 "loscilx",
1694 "lowpass2",
1695 "lowres",
1696 "lowresx",
1697 "lpcanal",
1698 "lpcfilter",
1699 "lpf18",
1700 "lpform",
1701 "lpfreson",
1702 "lphasor",
1703 "lpinterp",
1704 "lposcil",
1705 "lposcil3",
1706 "lposcila",
1707 "lposcilsa",
1708 "lposcilsa2",
1709 "lpread",
1710 "lpreson",
1711 "lpshold",
1712 "lpsholdp",
1713 "lpslot",
1714 "lufs",
1715 "mac",
1716 "maca",
1717 "madsr",
1718 "mags",
1719 "mandel",
1720 "mandol",
1721 "maparray",
1722 "maparray_i",
1723 "marimba",
1724 "massign",
1725 "max",
1726 "max_k",
1727 "maxabs",
1728 "maxabsaccum",
1729 "maxaccum",
1730 "maxalloc",
1731 "maxarray",
1732 "mclock",
1733 "mdelay",
1734 "median",
1735 "mediank",
1736 "metro",
1737 "metro2",
1738 "metrobpm",
1739 "mfb",
1740 "midglobal",
1741 "midiarp",
1742 "midic14",
1743 "midic21",
1744 "midic7",
1745 "midichannelaftertouch",
1746 "midichn",
1747 "midicontrolchange",
1748 "midictrl",
1749 "mididefault",
1750 "midifilestatus",
1751 "midiin",
1752 "midinoteoff",
1753 "midinoteoncps",
1754 "midinoteonkey",
1755 "midinoteonoct",
1756 "midinoteonpch",
1757 "midion",
1758 "midion2",
1759 "midiout",
1760 "midiout_i",
1761 "midipgm",
1762 "midipitchbend",
1763 "midipolyaftertouch",
1764 "midiprogramchange",
1765 "miditempo",
1766 "midremot",
1767 "min",
1768 "minabs",
1769 "minabsaccum",
1770 "minaccum",
1771 "minarray",
1772 "mincer",
1773 "mirror",
1774 "mode",
1775 "modmatrix",
1776 "monitor",
1777 "moog",
1778 "moogladder",
1779 "moogladder2",
1780 "moogvcf",
1781 "moogvcf2",
1782 "moscil",
1783 "mp3bitrate",
1784 "mp3in",
1785 "mp3len",
1786 "mp3nchnls",
1787 "mp3out",
1788 "mp3scal",
1789 "mp3sr",
1790 "mpulse",
1791 "mrtmsg",
1792 "ms2st",
1793 "mtof",
1794 "mton",
1795 "multitap",
1796 "mute",
1797 "mvchpf",
1798 "mvclpf1",
1799 "mvclpf2",
1800 "mvclpf3",
1801 "mvclpf4",
1802 "mvmfilter",
1803 "mxadsr",
1804 "nchnls_hw",
1805 "nestedap",
1806 "nlalp",
1807 "nlfilt",
1808 "nlfilt2",
1809 "noise",
1810 "noteoff",
1811 "noteon",
1812 "noteondur",
1813 "noteondur2",
1814 "notnum",
1815 "nreverb",
1816 "nrpn",
1817 "nsamp",
1818 "nstance",
1819 "nstrnum",
1820 "nstrstr",
1821 "ntof",
1822 "ntom",
1823 "ntrpol",
1824 "nxtpow2",
1825 "octave",
1826 "octcps",
1827 "octmidi",
1828 "octmidib",
1829 "octmidinn",
1830 "octpch",
1831 "olabuffer",
1832 "oscbnk",
1833 "oscil",
1834 "oscil1",
1835 "oscil1i",
1836 "oscil3",
1837 "oscili",
1838 "oscilikt",
1839 "osciliktp",
1840 "oscilikts",
1841 "osciln",
1842 "oscils",
1843 "oscilx",
1844 "out",
1845 "out32",
1846 "outall",
1847 "outc",
1848 "outch",
1849 "outh",
1850 "outiat",
1851 "outic",
1852 "outic14",
1853 "outipat",
1854 "outipb",
1855 "outipc",
1856 "outkat",
1857 "outkc",
1858 "outkc14",
1859 "outkpat",
1860 "outkpb",
1861 "outkpc",
1862 "outleta",
1863 "outletf",
1864 "outletk",
1865 "outletkid",
1866 "outletv",
1867 "outo",
1868 "outq",
1869 "outq1",
1870 "outq2",
1871 "outq3",
1872 "outq4",
1873 "outrg",
1874 "outs",
1875 "outs1",
1876 "outs2",
1877 "outvalue",
1878 "outx",
1879 "outz",
1880 "p",
1881 "p5gconnect",
1882 "p5gdata",
1883 "pan",
1884 "pan2",
1885 "pareq",
1886 "part2txt",
1887 "partials",
1888 "partikkel",
1889 "partikkelget",
1890 "partikkelset",
1891 "partikkelsync",
1892 "passign",
1893 "paulstretch",
1894 "pcauchy",
1895 "pchbend",
1896 "pchmidi",
1897 "pchmidib",
1898 "pchmidinn",
1899 "pchoct",
1900 "pchtom",
1901 "pconvolve",
1902 "pcount",
1903 "pdclip",
1904 "pdhalf",
1905 "pdhalfy",
1906 "peak",
1907 "pgmassign",
1908 "pgmchn",
1909 "phaser1",
1910 "phaser2",
1911 "phasor",
1912 "phasorbnk",
1913 "phs",
1914 "pindex",
1915 "pinker",
1916 "pinkish",
1917 "pitch",
1918 "pitchac",
1919 "pitchamdf",
1920 "planet",
1921 "platerev",
1922 "plltrack",
1923 "pluck",
1924 "poisson",
1925 "pol2rect",
1926 "polyaft",
1927 "polynomial",
1928 "port",
1929 "portk",
1930 "poscil",
1931 "poscil3",
1932 "pow",
1933 "powershape",
1934 "powoftwo",
1935 "pows",
1936 "prealloc",
1937 "prepiano",
1938 "print",
1939 "print_type",
1940 "printarray",
1941 "printf",
1942 "printf_i",
1943 "printk",
1944 "printk2",
1945 "printks",
1946 "printks2",
1947 "println",
1948 "prints",
1949 "printsk",
1950 "product",
1951 "pset",
1952 "ptablew",
1953 "ptrack",
1954 "puts",
1955 "pvadd",
1956 "pvbufread",
1957 "pvcross",
1958 "pvinterp",
1959 "pvoc",
1960 "pvread",
1961 "pvs2array",
1962 "pvs2tab",
1963 "pvsadsyn",
1964 "pvsanal",
1965 "pvsarp",
1966 "pvsbandp",
1967 "pvsbandr",
1968 "pvsbandwidth",
1969 "pvsbin",
1970 "pvsblur",
1971 "pvsbuffer",
1972 "pvsbufread",
1973 "pvsbufread2",
1974 "pvscale",
1975 "pvscent",
1976 "pvsceps",
1977 "pvscfs",
1978 "pvscross",
1979 "pvsdemix",
1980 "pvsdiskin",
1981 "pvsdisp",
1982 "pvsenvftw",
1983 "pvsfilter",
1984 "pvsfread",
1985 "pvsfreeze",
1986 "pvsfromarray",
1987 "pvsftr",
1988 "pvsftw",
1989 "pvsfwrite",
1990 "pvsgain",
1991 "pvsgendy",
1992 "pvshift",
1993 "pvsifd",
1994 "pvsin",
1995 "pvsinfo",
1996 "pvsinit",
1997 "pvslock",
1998 "pvslpc",
1999 "pvsmaska",
2000 "pvsmix",
2001 "pvsmooth",
2002 "pvsmorph",
2003 "pvsosc",
2004 "pvsout",
2005 "pvspitch",
2006 "pvstanal",
2007 "pvstencil",
2008 "pvstrace",
2009 "pvsvoc",
2010 "pvswarp",
2011 "pvsynth",
2012 "pwd",
2013 "pyassign",
2014 "pyassigni",
2015 "pyassignt",
2016 "pycall",
2017 "pycall1",
2018 "pycall1i",
2019 "pycall1t",
2020 "pycall2",
2021 "pycall2i",
2022 "pycall2t",
2023 "pycall3",
2024 "pycall3i",
2025 "pycall3t",
2026 "pycall4",
2027 "pycall4i",
2028 "pycall4t",
2029 "pycall5",
2030 "pycall5i",
2031 "pycall5t",
2032 "pycall6",
2033 "pycall6i",
2034 "pycall6t",
2035 "pycall7",
2036 "pycall7i",
2037 "pycall7t",
2038 "pycall8",
2039 "pycall8i",
2040 "pycall8t",
2041 "pycalli",
2042 "pycalln",
2043 "pycallni",
2044 "pycallt",
2045 "pyeval",
2046 "pyevali",
2047 "pyevalt",
2048 "pyexec",
2049 "pyexeci",
2050 "pyexect",
2051 "pyinit",
2052 "pylassign",
2053 "pylassigni",
2054 "pylassignt",
2055 "pylcall",
2056 "pylcall1",
2057 "pylcall1i",
2058 "pylcall1t",
2059 "pylcall2",
2060 "pylcall2i",
2061 "pylcall2t",
2062 "pylcall3",
2063 "pylcall3i",
2064 "pylcall3t",
2065 "pylcall4",
2066 "pylcall4i",
2067 "pylcall4t",
2068 "pylcall5",
2069 "pylcall5i",
2070 "pylcall5t",
2071 "pylcall6",
2072 "pylcall6i",
2073 "pylcall6t",
2074 "pylcall7",
2075 "pylcall7i",
2076 "pylcall7t",
2077 "pylcall8",
2078 "pylcall8i",
2079 "pylcall8t",
2080 "pylcalli",
2081 "pylcalln",
2082 "pylcallni",
2083 "pylcallt",
2084 "pyleval",
2085 "pylevali",
2086 "pylevalt",
2087 "pylexec",
2088 "pylexeci",
2089 "pylexect",
2090 "pylrun",
2091 "pylruni",
2092 "pylrunt",
2093 "pyrun",
2094 "pyruni",
2095 "pyrunt",
2096 "qinf",
2097 "qnan",
2098 "r2c",
2099 "rand",
2100 "randc",
2101 "randh",
2102 "randi",
2103 "random",
2104 "randomh",
2105 "randomi",
2106 "rbjeq",
2107 "readclock",
2108 "readf",
2109 "readfi",
2110 "readk",
2111 "readk2",
2112 "readk3",
2113 "readk4",
2114 "readks",
2115 "readscore",
2116 "readscratch",
2117 "rect2pol",
2118 "release",
2119 "remoteport",
2120 "remove",
2121 "repluck",
2122 "reshapearray",
2123 "reson",
2124 "resonbnk",
2125 "resonk",
2126 "resonr",
2127 "resonx",
2128 "resonxk",
2129 "resony",
2130 "resonz",
2131 "resyn",
2132 "reverb",
2133 "reverb2",
2134 "reverbsc",
2135 "rewindscore",
2136 "rezzy",
2137 "rfft",
2138 "rifft",
2139 "rms",
2140 "rnd",
2141 "rnd31",
2142 "rndseed",
2143 "round",
2144 "rspline",
2145 "rtclock",
2146 "s16b14",
2147 "s32b14",
2148 "samphold",
2149 "sandpaper",
2150 "sc_lag",
2151 "sc_lagud",
2152 "sc_phasor",
2153 "sc_trig",
2154 "scale",
2155 "scale2",
2156 "scalearray",
2157 "scanhammer",
2158 "scanmap",
2159 "scans",
2160 "scansmap",
2161 "scantable",
2162 "scanu",
2163 "scanu2",
2164 "schedkwhen",
2165 "schedkwhennamed",
2166 "schedule",
2167 "schedulek",
2168 "schedwhen",
2169 "scoreline",
2170 "scoreline_i",
2171 "seed",
2172 "sekere",
2173 "select",
2174 "semitone",
2175 "sense",
2176 "sensekey",
2177 "seqtime",
2178 "seqtime2",
2179 "sequ",
2180 "sequstate",
2181 "serialBegin",
2182 "serialEnd",
2183 "serialFlush",
2184 "serialPrint",
2185 "serialRead",
2186 "serialWrite",
2187 "serialWrite_i",
2188 "setcol",
2189 "setctrl",
2190 "setksmps",
2191 "setrow",
2192 "setscorepos",
2193 "sfilist",
2194 "sfinstr",
2195 "sfinstr3",
2196 "sfinstr3m",
2197 "sfinstrm",
2198 "sfload",
2199 "sflooper",
2200 "sfpassign",
2201 "sfplay",
2202 "sfplay3",
2203 "sfplay3m",
2204 "sfplaym",
2205 "sfplist",
2206 "sfpreset",
2207 "shaker",
2208 "shiftin",
2209 "shiftout",
2210 "signum",
2211 "sin",
2212 "sinh",
2213 "sininv",
2214 "sinsyn",
2215 "skf",
2216 "sleighbells",
2217 "slicearray",
2218 "slicearray_i",
2219 "slider16",
2220 "slider16f",
2221 "slider16table",
2222 "slider16tablef",
2223 "slider32",
2224 "slider32f",
2225 "slider32table",
2226 "slider32tablef",
2227 "slider64",
2228 "slider64f",
2229 "slider64table",
2230 "slider64tablef",
2231 "slider8",
2232 "slider8f",
2233 "slider8table",
2234 "slider8tablef",
2235 "sliderKawai",
2236 "sndloop",
2237 "sndwarp",
2238 "sndwarpst",
2239 "sockrecv",
2240 "sockrecvs",
2241 "socksend",
2242 "socksends",
2243 "sorta",
2244 "sortd",
2245 "soundin",
2246 "space",
2247 "spat3d",
2248 "spat3di",
2249 "spat3dt",
2250 "spdist",
2251 "spf",
2252 "splitrig",
2253 "sprintf",
2254 "sprintfk",
2255 "spsend",
2256 "sqrt",
2257 "squinewave",
2258 "st2ms",
2259 "statevar",
2260 "sterrain",
2261 "stix",
2262 "strcat",
2263 "strcatk",
2264 "strchar",
2265 "strchark",
2266 "strcmp",
2267 "strcmpk",
2268 "strcpy",
2269 "strcpyk",
2270 "strecv",
2271 "streson",
2272 "strfromurl",
2273 "strget",
2274 "strindex",
2275 "strindexk",
2276 "string2array",
2277 "strlen",
2278 "strlenk",
2279 "strlower",
2280 "strlowerk",
2281 "strrindex",
2282 "strrindexk",
2283 "strset",
2284 "strstrip",
2285 "strsub",
2286 "strsubk",
2287 "strtod",
2288 "strtodk",
2289 "strtol",
2290 "strtolk",
2291 "strupper",
2292 "strupperk",
2293 "stsend",
2294 "subinstr",
2295 "subinstrinit",
2296 "sum",
2297 "sumarray",
2298 "svfilter",
2299 "svn",
2300 "syncgrain",
2301 "syncloop",
2302 "syncphasor",
2303 "system",
2304 "system_i",
2305 "tab",
2306 "tab2array",
2307 "tab2pvs",
2308 "tab_i",
2309 "tabifd",
2310 "table",
2311 "table3",
2312 "table3kt",
2313 "tablecopy",
2314 "tablefilter",
2315 "tablefilteri",
2316 "tablegpw",
2317 "tablei",
2318 "tableicopy",
2319 "tableigpw",
2320 "tableikt",
2321 "tableimix",
2322 "tablekt",
2323 "tablemix",
2324 "tableng",
2325 "tablera",
2326 "tableseg",
2327 "tableshuffle",
2328 "tableshufflei",
2329 "tablew",
2330 "tablewa",
2331 "tablewkt",
2332 "tablexkt",
2333 "tablexseg",
2334 "tabmorph",
2335 "tabmorpha",
2336 "tabmorphak",
2337 "tabmorphi",
2338 "tabplay",
2339 "tabrec",
2340 "tabsum",
2341 "tabw",
2342 "tabw_i",
2343 "tambourine",
2344 "tan",
2345 "tanh",
2346 "taninv",
2347 "taninv2",
2348 "tbvcf",
2349 "tempest",
2350 "tempo",
2351 "temposcal",
2352 "tempoval",
2353 "timedseq",
2354 "timeinstk",
2355 "timeinsts",
2356 "timek",
2357 "times",
2358 "tival",
2359 "tlineto",
2360 "tone",
2361 "tonek",
2362 "tonex",
2363 "tradsyn",
2364 "trandom",
2365 "transeg",
2366 "transegb",
2367 "transegr",
2368 "trcross",
2369 "trfilter",
2370 "trhighest",
2371 "trigExpseg",
2372 "trigLinseg",
2373 "trigexpseg",
2374 "trigger",
2375 "trighold",
2376 "triglinseg",
2377 "trigphasor",
2378 "trigseq",
2379 "trim",
2380 "trim_i",
2381 "trirand",
2382 "trlowest",
2383 "trmix",
2384 "trscale",
2385 "trshift",
2386 "trsplit",
2387 "turnoff",
2388 "turnoff2",
2389 "turnoff2_i",
2390 "turnoff3",
2391 "turnon",
2392 "tvconv",
2393 "unirand",
2394 "unwrap",
2395 "upsamp",
2396 "urandom",
2397 "urd",
2398 "vactrol",
2399 "vadd",
2400 "vadd_i",
2401 "vaddv",
2402 "vaddv_i",
2403 "vaget",
2404 "valpass",
2405 "vaset",
2406 "vbap",
2407 "vbapg",
2408 "vbapgmove",
2409 "vbaplsinit",
2410 "vbapmove",
2411 "vbapz",
2412 "vbapzmove",
2413 "vcella",
2414 "vclpf",
2415 "vco",
2416 "vco2",
2417 "vco2ft",
2418 "vco2ift",
2419 "vco2init",
2420 "vcomb",
2421 "vcopy",
2422 "vcopy_i",
2423 "vdel_k",
2424 "vdelay",
2425 "vdelay3",
2426 "vdelayk",
2427 "vdelayx",
2428 "vdelayxq",
2429 "vdelayxs",
2430 "vdelayxw",
2431 "vdelayxwq",
2432 "vdelayxws",
2433 "vdivv",
2434 "vdivv_i",
2435 "vecdelay",
2436 "veloc",
2437 "vexp",
2438 "vexp_i",
2439 "vexpseg",
2440 "vexpv",
2441 "vexpv_i",
2442 "vibes",
2443 "vibr",
2444 "vibrato",
2445 "vincr",
2446 "vlimit",
2447 "vlinseg",
2448 "vlowres",
2449 "vmap",
2450 "vmirror",
2451 "vmult",
2452 "vmult_i",
2453 "vmultv",
2454 "vmultv_i",
2455 "voice",
2456 "vosim",
2457 "vphaseseg",
2458 "vport",
2459 "vpow",
2460 "vpow_i",
2461 "vpowv",
2462 "vpowv_i",
2463 "vps",
2464 "vpvoc",
2465 "vrandh",
2466 "vrandi",
2467 "vsubv",
2468 "vsubv_i",
2469 "vtaba",
2470 "vtabi",
2471 "vtabk",
2472 "vtable1k",
2473 "vtablea",
2474 "vtablei",
2475 "vtablek",
2476 "vtablewa",
2477 "vtablewi",
2478 "vtablewk",
2479 "vtabwa",
2480 "vtabwi",
2481 "vtabwk",
2482 "vwrap",
2483 "waveset",
2484 "websocket",
2485 "weibull",
2486 "wgbow",
2487 "wgbowedbar",
2488 "wgbrass",
2489 "wgclar",
2490 "wgflute",
2491 "wgpluck",
2492 "wgpluck2",
2493 "wguide1",
2494 "wguide2",
2495 "wiiconnect",
2496 "wiidata",
2497 "wiirange",
2498 "wiisend",
2499 "window",
2500 "wrap",
2501 "writescratch",
2502 "wterrain",
2503 "wterrain2",
2504 "xadsr",
2505 "xin",
2506 "xout",
2507 "xtratim",
2508 "xyscale",
2509 "zacl",
2510 "zakinit",
2511 "zamod",
2512 "zar",
2513 "zarg",
2514 "zaw",
2515 "zawm",
2516 "zdf_1pole",
2517 "zdf_1pole_mode",
2518 "zdf_2pole",
2519 "zdf_2pole_mode",
2520 "zdf_ladder",
2521 "zfilter2",
2522 "zir",
2523 "ziw",
2524 "ziwm",
2525 "zkcl",
2526 "zkmod",
2527 "zkr",
2528 "zkw",
2529 "zkwm"
2530 ];
2531 var deprecatedOpcodes = [
2532 "OSCsendA",
2533 "array",
2534 "beadsynt",
2535 "beosc",
2536 "bformdec",
2537 "bformenc",
2538 "buchla",
2539 "copy2ftab",
2540 "copy2ttab",
2541 "getrowlin",
2542 "hrtfer",
2543 "ktableseg",
2544 "lentab",
2545 "lua_exec",
2546 "lua_iaopcall",
2547 "lua_iaopcall_off",
2548 "lua_ikopcall",
2549 "lua_ikopcall_off",
2550 "lua_iopcall",
2551 "lua_iopcall_off",
2552 "lua_opdef",
2553 "maxtab",
2554 "mintab",
2555 "mp3scal_check",
2556 "mp3scal_load",
2557 "mp3scal_load2",
2558 "mp3scal_play",
2559 "mp3scal_play2",
2560 "pop",
2561 "pop_f",
2562 "ptable",
2563 "ptable3",
2564 "ptablei",
2565 "ptableiw",
2566 "push",
2567 "push_f",
2568 "pvsgendy",
2569 "scalet",
2570 "signalflowgraph",
2571 "sndload",
2572 "socksend_k",
2573 "soundout",
2574 "soundouts",
2575 "specaddm",
2576 "specdiff",
2577 "specdisp",
2578 "specfilt",
2579 "spechist",
2580 "specptrk",
2581 "specscal",
2582 "specsum",
2583 "spectrum",
2584 "stack",
2585 "sumTableFilter",
2586 "sumtab",
2587 "systime",
2588 "tabgen",
2589 "tableiw",
2590 "tabmap",
2591 "tabmap_i",
2592 "tabrowlin",
2593 "tabslice",
2594 "tb0",
2595 "tb0_init",
2596 "tb1",
2597 "tb10",
2598 "tb10_init",
2599 "tb11",
2600 "tb11_init",
2601 "tb12",
2602 "tb12_init",
2603 "tb13",
2604 "tb13_init",
2605 "tb14",
2606 "tb14_init",
2607 "tb15",
2608 "tb15_init",
2609 "tb1_init",
2610 "tb2",
2611 "tb2_init",
2612 "tb3",
2613 "tb3_init",
2614 "tb4",
2615 "tb4_init",
2616 "tb5",
2617 "tb5_init",
2618 "tb6",
2619 "tb6_init",
2620 "tb7",
2621 "tb7_init",
2622 "tb8",
2623 "tb8_init",
2624 "tb9",
2625 "tb9_init",
2626 "vbap16",
2627 "vbap1move",
2628 "vbap4",
2629 "vbap4move",
2630 "vbap8",
2631 "vbap8move",
2632 "xscanmap",
2633 "xscans",
2634 "xscansmap",
2635 "xscanu",
2636 "xyin"
2637 ];
2638 opcodes = lang.arrayToMap(opcodes);
2639 deprecatedOpcodes = lang.arrayToMap(deprecatedOpcodes);
2640 this.lineContinuations = [
2641 {
2642 token: "constant.character.escape.line-continuation.csound",
2643 regex: /\\$/
2644 }, this.pushRule({
2645 token: "constant.character.escape.line-continuation.csound",
2646 regex: /\\/,
2647 next: "line continuation"
2648 })
2649 ];
2650 this.comments.push(this.lineContinuations);
2651 this.quotedStringContents.push(this.lineContinuations, {
2652 token: "invalid.illegal",
2653 regex: /[^"\\]*$/
2654 });
2655 var start = this.$rules.start;
2656 start.splice(1, 0, {
2657 token: ["text.csound", "entity.name.label.csound", "entity.punctuation.label.csound", "text.csound"],
2658 regex: /^([ \t]*)(\w+)(:)([ \t]+|$)/
2659 });
2660 start.push(this.pushRule({
2661 token: "keyword.function.csound",
2662 regex: /\binstr\b/,
2663 next: "instrument numbers and identifiers"
2664 }), this.pushRule({
2665 token: "keyword.function.csound",
2666 regex: /\bopcode\b/,
2667 next: "after opcode keyword"
2668 }), {
2669 token: "keyword.other.csound",
2670 regex: /\bend(?:in|op)\b/
2671 }, {
2672 token: "variable.language.csound",
2673 regex: /\b(?:0dbfs|A4|k(?:r|smps)|nchnls(?:_i)?|sr)\b/
2674 }, this.numbers, {
2675 token: "keyword.operator.csound",
2676 regex: "\\+=|-=|\\*=|/=|<<|>>|<=|>=|==|!=|&&|\\|\\||[~¬]|[=!+\\-*/^%&|<>#?:]"
2677 }, this.pushRule({
2678 token: "punctuation.definition.string.begin.csound",
2679 regex: /"/,
2680 next: "quoted string"
2681 }), this.pushRule({
2682 token: "punctuation.definition.string.begin.csound",
2683 regex: /{{/,
2684 next: "braced string"
2685 }), {
2686 token: "keyword.control.csound",
2687 regex: /\b(?:do|else(?:if)?|end(?:if|until)|fi|i(?:f|then)|kthen|od|r(?:ir)?eturn|then|until|while)\b/
2688 }, this.pushRule({
2689 token: "keyword.control.csound",
2690 regex: /\b[ik]?goto\b/,
2691 next: "goto before label"
2692 }), this.pushRule({
2693 token: "keyword.control.csound",
2694 regex: /\b(?:r(?:einit|igoto)|tigoto)\b/,
2695 next: "goto before label"
2696 }), this.pushRule({
2697 token: "keyword.control.csound",
2698 regex: /\bc(?:g|in?|k|nk?)goto\b/,
2699 next: ["goto before label", "goto before argument"]
2700 }), this.pushRule({
2701 token: "keyword.control.csound",
2702 regex: /\btimout\b/,
2703 next: ["goto before label", "goto before argument", "goto before argument"]
2704 }), this.pushRule({
2705 token: "keyword.control.csound",
2706 regex: /\bloop_[gl][et]\b/,
2707 next: ["goto before label", "goto before argument", "goto before argument", "goto before argument"]
2708 }), this.pushRule({
2709 token: "support.function.csound",
2710 regex: /\b(?:readscore|scoreline(?:_i)?)\b/,
2711 next: "Csound score opcode"
2712 }), this.pushRule({
2713 token: "support.function.csound",
2714 regex: /\bpyl?run[it]?\b(?!$)/,
2715 next: "Python opcode"
2716 }), this.pushRule({
2717 token: "support.function.csound",
2718 regex: /\blua_(?:exec|opdef)\b(?!$)/,
2719 next: "Lua opcode"
2720 }), {
2721 token: "support.variable.csound",
2722 regex: /\bp\d+\b/
2723 }, {
2724 regex: /\b([A-Z_a-z]\w*)(?:(:)([A-Za-z]))?\b/, onMatch: function (value, currentState, stack, line) {
2725 var tokens = value.split(this.splitRegex);
2726 var name = tokens[1];
2727 var type;
2728 if (opcodes.hasOwnProperty(name))
2729 type = "support.function.csound";
2730 else if (deprecatedOpcodes.hasOwnProperty(name))
2731 type = "invalid.deprecated.csound";
2732 if (type) {
2733 if (tokens[2]) {
2734 return [
2735 { type: type, value: name },
2736 { type: "punctuation.type-annotation.csound", value: tokens[2] },
2737 { type: "type-annotation.storage.type.csound", value: tokens[3] }
2738 ];
2739 }
2740 return type;
2741 }
2742 return "text.csound";
2743 }
2744 });
2745 this.$rules["macro parameter value list"].splice(2, 0, {
2746 token: "punctuation.definition.string.begin.csound",
2747 regex: /{{/,
2748 next: "macro parameter value braced string"
2749 });
2750 var scoreHighlightRules = new CsoundScoreHighlightRules("csound-score-");
2751 this.addRules({
2752 "macro parameter value braced string": [
2753 {
2754 token: "constant.character.escape.csound",
2755 regex: /\\[#'()]/
2756 }, {
2757 token: "invalid.illegal.csound.csound",
2758 regex: /[#'()]/
2759 }, {
2760 token: "punctuation.definition.string.end.csound",
2761 regex: /}}/,
2762 next: "macro parameter value list"
2763 }, {
2764 defaultToken: "string.braced.csound"
2765 }
2766 ],
2767 "instrument numbers and identifiers": [
2768 this.comments,
2769 {
2770 token: "entity.name.function.csound",
2771 regex: /\d+|[A-Z_a-z]\w*/
2772 }, this.popRule({
2773 token: "empty",
2774 regex: /$/
2775 })
2776 ],
2777 "after opcode keyword": [
2778 this.comments,
2779 this.popRule({
2780 token: "empty",
2781 regex: /$/
2782 }), this.popRule({
2783 token: "entity.name.function.opcode.csound",
2784 regex: /[A-Z_a-z]\w*/,
2785 next: "opcode type signatures"
2786 })
2787 ],
2788 "opcode type signatures": [
2789 this.comments,
2790 this.popRule({
2791 token: "empty",
2792 regex: /$/
2793 }), {
2794 token: "storage.type.csound",
2795 regex: /\b(?:0|[afijkKoOpPStV\[\]]+)/
2796 }
2797 ],
2798 "quoted string": [
2799 this.popRule({
2800 token: "punctuation.definition.string.end.csound",
2801 regex: /"/
2802 }),
2803 this.quotedStringContents,
2804 {
2805 defaultToken: "string.quoted.csound"
2806 }
2807 ],
2808 "braced string": [
2809 this.popRule({
2810 token: "punctuation.definition.string.end.csound",
2811 regex: /}}/
2812 }),
2813 this.bracedStringContents,
2814 {
2815 defaultToken: "string.braced.csound"
2816 }
2817 ],
2818 "goto before argument": [
2819 this.popRule({
2820 token: "text.csound",
2821 regex: /,/
2822 }),
2823 start
2824 ],
2825 "goto before label": [
2826 {
2827 token: "text.csound",
2828 regex: /\s+/
2829 },
2830 this.comments,
2831 this.popRule({
2832 token: "entity.name.label.csound",
2833 regex: /\w+/
2834 }), this.popRule({
2835 token: "empty",
2836 regex: /(?!\w)/
2837 })
2838 ],
2839 "Csound score opcode": [
2840 this.comments,
2841 {
2842 token: "punctuation.definition.string.begin.csound",
2843 regex: /{{/,
2844 next: scoreHighlightRules.embeddedRulePrefix + "start"
2845 }, this.popRule({
2846 token: "empty",
2847 regex: /$/
2848 })
2849 ],
2850 "Python opcode": [
2851 this.comments,
2852 {
2853 token: "punctuation.definition.string.begin.csound",
2854 regex: /{{/,
2855 next: "python-start"
2856 }, this.popRule({
2857 token: "empty",
2858 regex: /$/
2859 })
2860 ],
2861 "Lua opcode": [
2862 this.comments,
2863 {
2864 token: "punctuation.definition.string.begin.csound",
2865 regex: /{{/,
2866 next: "lua-start"
2867 }, this.popRule({
2868 token: "empty",
2869 regex: /$/
2870 })
2871 ],
2872 "line continuation": [
2873 this.popRule({
2874 token: "empty",
2875 regex: /$/
2876 }),
2877 this.semicolonComments,
2878 {
2879 token: "invalid.illegal.csound",
2880 regex: /\S.*/
2881 }
2882 ]
2883 });
2884 var rules = [
2885 this.popRule({
2886 token: "punctuation.definition.string.end.csound",
2887 regex: /}}/
2888 })
2889 ];
2890 this.embedRules(scoreHighlightRules.getRules(), scoreHighlightRules.embeddedRulePrefix, rules);
2891 this.embedRules(PythonHighlightRules, "python-", rules);
2892 this.embedRules(LuaHighlightRules, "lua-", rules);
2893 this.normalizeRules();
2894 };
2895 oop.inherits(CsoundOrchestraHighlightRules, CsoundPreprocessorHighlightRules);
2896 exports.CsoundOrchestraHighlightRules = CsoundOrchestraHighlightRules;
2897
2898 });
2899
2900 ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module){"use strict";
2901 var oop = require("../lib/oop");
2902 var lang = require("../lib/lang");
2903 var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
2904 var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|max-zoom|min-height|min-width|min-zoom|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|user-select|user-zoom|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
2905 var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
2906 var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|flex-end|flex-start|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero|zoom";
2907 var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
2908 var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
2909 var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
2910 var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
2911 var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
2912 var CssHighlightRules = function () {
2913 var keywordMapper = this.createKeywordMapper({
2914 "support.function": supportFunction,
2915 "support.constant": supportConstant,
2916 "support.type": supportType,
2917 "support.constant.color": supportConstantColor,
2918 "support.constant.fonts": supportConstantFonts
2919 }, "text", true);
2920 this.$rules = {
2921 "start": [{
2922 include: ["strings", "url", "comments"]
2923 }, {
2924 token: "paren.lparen",
2925 regex: "\\{",
2926 next: "ruleset"
2927 }, {
2928 token: "paren.rparen",
2929 regex: "\\}"
2930 }, {
2931 token: "string",
2932 regex: "@(?!viewport)",
2933 next: "media"
2934 }, {
2935 token: "keyword",
2936 regex: "#[a-z0-9-_]+"
2937 }, {
2938 token: "keyword",
2939 regex: "%"
2940 }, {
2941 token: "variable",
2942 regex: "\\.[a-z0-9-_]+"
2943 }, {
2944 token: "string",
2945 regex: ":[a-z0-9-_]+"
2946 }, {
2947 token: "constant.numeric",
2948 regex: numRe
2949 }, {
2950 token: "constant",
2951 regex: "[a-z0-9-_]+"
2952 }, {
2953 caseInsensitive: true
2954 }],
2955 "media": [{
2956 include: ["strings", "url", "comments"]
2957 }, {
2958 token: "paren.lparen",
2959 regex: "\\{",
2960 next: "start"
2961 }, {
2962 token: "paren.rparen",
2963 regex: "\\}",
2964 next: "start"
2965 }, {
2966 token: "string",
2967 regex: ";",
2968 next: "start"
2969 }, {
2970 token: "keyword",
2971 regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
2972 + "|page|font|keyframes|viewport|counter-style|font-feature-values"
2973 + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
2974 }],
2975 "comments": [{
2976 token: "comment", // multi line comment
2977 regex: "\\/\\*",
2978 push: [{
2979 token: "comment",
2980 regex: "\\*\\/",
2981 next: "pop"
2982 }, {
2983 defaultToken: "comment"
2984 }]
2985 }],
2986 "ruleset": [{
2987 regex: "-(webkit|ms|moz|o)-",
2988 token: "text"
2989 }, {
2990 token: "punctuation.operator",
2991 regex: "[:;]"
2992 }, {
2993 token: "paren.rparen",
2994 regex: "\\}",
2995 next: "start"
2996 }, {
2997 include: ["strings", "url", "comments"]
2998 }, {
2999 token: ["constant.numeric", "keyword"],
3000 regex: "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vmax|vmin|vm|vw|%)"
3001 }, {
3002 token: "constant.numeric",
3003 regex: numRe
3004 }, {
3005 token: "constant.numeric", // hex6 color
3006 regex: "#[a-f0-9]{6}"
3007 }, {
3008 token: "constant.numeric", // hex3 color
3009 regex: "#[a-f0-9]{3}"
3010 }, {
3011 token: ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
3012 regex: pseudoElements
3013 }, {
3014 token: ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
3015 regex: pseudoClasses
3016 }, {
3017 include: "url"
3018 }, {
3019 token: keywordMapper,
3020 regex: "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
3021 }, {
3022 caseInsensitive: true
3023 }],
3024 url: [{
3025 token: "support.function",
3026 regex: "(?:url(:?-prefix)?|domain|regexp)\\(",
3027 push: [{
3028 token: "support.function",
3029 regex: "\\)",
3030 next: "pop"
3031 }, {
3032 defaultToken: "string"
3033 }]
3034 }],
3035 strings: [{
3036 token: "string.start",
3037 regex: "'",
3038 push: [{
3039 token: "string.end",
3040 regex: "'|$",
3041 next: "pop"
3042 }, {
3043 include: "escapes"
3044 }, {
3045 token: "constant.language.escape",
3046 regex: /\\$/,
3047 consumeLineEnd: true
3048 }, {
3049 defaultToken: "string"
3050 }]
3051 }, {
3052 token: "string.start",
3053 regex: '"',
3054 push: [{
3055 token: "string.end",
3056 regex: '"|$',
3057 next: "pop"
3058 }, {
3059 include: "escapes"
3060 }, {
3061 token: "constant.language.escape",
3062 regex: /\\$/,
3063 consumeLineEnd: true
3064 }, {
3065 defaultToken: "string"
3066 }]
3067 }],
3068 escapes: [{
3069 token: "constant.language.escape",
3070 regex: /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
3071 }]
3072 };
3073 this.normalizeRules();
3074 };
3075 oop.inherits(CssHighlightRules, TextHighlightRules);
3076 exports.CssHighlightRules = CssHighlightRules;
3077
3078 });
3079
3080 ace.define("ace/mode/jsdoc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module){"use strict";
3081 var oop = require("../lib/oop");
3082 var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
3083 var JsDocCommentHighlightRules = function () {
3084 this.$rules = {
3085 "start": [
3086 {
3087 token: ["comment.doc.tag", "comment.doc.text", "lparen.doc"],
3088 regex: "(@(?:param|member|typedef|property|namespace|var|const|callback))(\\s*)({)",
3089 push: [
3090 {
3091 token: "lparen.doc",
3092 regex: "{",
3093 push: [
3094 {
3095 include: "doc-syntax"
3096 }, {
3097 token: "rparen.doc",
3098 regex: "}|(?=$)",
3099 next: "pop"
3100 }
3101 ]
3102 }, {
3103 token: ["rparen.doc", "text.doc", "variable.parameter.doc", "lparen.doc", "variable.parameter.doc", "rparen.doc"],
3104 regex: /(})(\s*)(?:([\w=:\/\.]+)|(?:(\[)([\w=:\/\.]+)(\])))/,
3105 next: "pop"
3106 }, {
3107 token: "rparen.doc",
3108 regex: "}|(?=$)",
3109 next: "pop"
3110 }, {
3111 include: "doc-syntax"
3112 }, {
3113 defaultToken: "text.doc"
3114 }
3115 ]
3116 }, {
3117 token: ["comment.doc.tag", "text.doc", "lparen.doc"],
3118 regex: "(@(?:returns?|yields|type|this|suppress|public|protected|private|package|modifies|"
3119 + "implements|external|exception|throws|enum|define|extends))(\\s*)({)",
3120 push: [
3121 {
3122 token: "lparen.doc",
3123 regex: "{",
3124 push: [
3125 {
3126 include: "doc-syntax"
3127 }, {
3128 token: "rparen.doc",
3129 regex: "}|(?=$)",
3130 next: "pop"
3131 }
3132 ]
3133 }, {
3134 token: "rparen.doc",
3135 regex: "}|(?=$)",
3136 next: "pop"
3137 }, {
3138 include: "doc-syntax"
3139 }, {
3140 defaultToken: "text.doc"
3141 }
3142 ]
3143 }, {
3144 token: ["comment.doc.tag", "text.doc", "variable.parameter.doc"],
3145 regex: "(@(?:alias|memberof|instance|module|name|lends|namespace|external|this|template|"
3146 + "requires|param|implements|function|extends|typedef|mixes|constructor|var|"
3147 + "memberof\\!|event|listens|exports|class|constructs|interface|emits|fires|"
3148 + "throws|const|callback|borrows|augments))(\\s+)(\\w[\\w#\.:\/~\"\\-]*)?"
3149 }, {
3150 token: ["comment.doc.tag", "text.doc", "variable.parameter.doc"],
3151 regex: "(@method)(\\s+)(\\w[\\w\.\\(\\)]*)"
3152 }, {
3153 token: "comment.doc.tag",
3154 regex: "@access\\s+(?:private|public|protected)"
3155 }, {
3156 token: "comment.doc.tag",
3157 regex: "@kind\\s+(?:class|constant|event|external|file|function|member|mixin|module|namespace|typedef)"
3158 }, {
3159 token: "comment.doc.tag",
3160 regex: "@\\w+(?=\\s|$)"
3161 },
3162 JsDocCommentHighlightRules.getTagRule(),
3163 {
3164 defaultToken: "comment.doc",
3165 caseInsensitive: true
3166 }
3167 ],
3168 "doc-syntax": [{
3169 token: "operator.doc",
3170 regex: /[|:]/
3171 }, {
3172 token: "paren.doc",
3173 regex: /[\[\]]/
3174 }]
3175 };
3176 this.normalizeRules();
3177 };
3178 oop.inherits(JsDocCommentHighlightRules, TextHighlightRules);
3179 JsDocCommentHighlightRules.getTagRule = function (start) {
3180 return {
3181 token: "comment.doc.tag.storage.type",
3182 regex: "\\b(?:TODO|FIXME|XXX|HACK)\\b"
3183 };
3184 };
3185 JsDocCommentHighlightRules.getStartRule = function (start) {
3186 return {
3187 token: "comment.doc", // doc comment
3188 regex: "\\/\\*(?=\\*)",
3189 next: start
3190 };
3191 };
3192 JsDocCommentHighlightRules.getEndRule = function (start) {
3193 return {
3194 token: "comment.doc", // closing comment
3195 regex: "\\*\\/",
3196 next: start
3197 };
3198 };
3199 exports.JsDocCommentHighlightRules = JsDocCommentHighlightRules;
3200
3201 });
3202
3203 ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/jsdoc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module){"use strict";
3204 var oop = require("../lib/oop");
3205 var DocCommentHighlightRules = require("./jsdoc_comment_highlight_rules").JsDocCommentHighlightRules;
3206 var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
3207 var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
3208 var JavaScriptHighlightRules = function (options) {
3209 var keywordMapper = this.createKeywordMapper({
3210 "variable.language": "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|Symbol|" + // Constructors
3211 "Namespace|QName|XML|XMLList|" + // E4X
3212 "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
3213 "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
3214 "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
3215 "SyntaxError|TypeError|URIError|" +
3216 "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
3217 "isNaN|parseFloat|parseInt|" +
3218 "JSON|Math|" + // Other
3219 "this|arguments|prototype|window|document", // Pseudo
3220 "keyword": "const|yield|import|get|set|async|await|" +
3221 "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
3222 "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
3223 "__parent__|__count__|escape|unescape|with|__proto__|" +
3224 "class|enum|extends|super|export|implements|private|public|interface|package|protected|static|constructor",
3225 "storage.type": "const|let|var|function",
3226 "constant.language": "null|Infinity|NaN|undefined",
3227 "support.function": "alert",
3228 "constant.language.boolean": "true|false"
3229 }, "identifier");
3230 var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
3231 var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
3232 "u[0-9a-fA-F]{4}|" + // unicode
3233 "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
3234 "[0-2][0-7]{0,2}|" + // oct
3235 "3[0-7][0-7]?|" + // oct
3236 "[4-7][0-7]?|" + //oct
3237 ".)";
3238 this.$rules = {
3239 "no_regex": [
3240 DocCommentHighlightRules.getStartRule("doc-start"),
3241 comments("no_regex"),
3242 {
3243 token: "string",
3244 regex: "'(?=.)",
3245 next: "qstring"
3246 }, {
3247 token: "string",
3248 regex: '"(?=.)',
3249 next: "qqstring"
3250 }, {
3251 token: "constant.numeric", // hexadecimal, octal and binary
3252 regex: /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
3253 }, {
3254 token: "constant.numeric", // decimal integers and floats
3255 regex: /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
3256 }, {
3257 token: [
3258 "storage.type", "punctuation.operator", "support.function",
3259 "punctuation.operator", "entity.name.function", "text", "keyword.operator"
3260 ],
3261 regex: "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe + ")(\\s*)(=)",
3262 next: "function_arguments"
3263 }, {
3264 token: [
3265 "storage.type", "punctuation.operator", "entity.name.function", "text",
3266 "keyword.operator", "text", "storage.type", "text", "paren.lparen"
3267 ],
3268 regex: "(" + identifierRe + ")(\\.)(" + identifierRe + ")(\\s*)(=)(\\s*)(function\\*?)(\\s*)(\\()",
3269 next: "function_arguments"
3270 }, {
3271 token: [
3272 "entity.name.function", "text", "keyword.operator", "text", "storage.type",
3273 "text", "paren.lparen"
3274 ],
3275 regex: "(" + identifierRe + ")(\\s*)(=)(\\s*)(function\\*?)(\\s*)(\\()",
3276 next: "function_arguments"
3277 }, {
3278 token: [
3279 "storage.type", "punctuation.operator", "entity.name.function", "text",
3280 "keyword.operator", "text",
3281 "storage.type", "text", "entity.name.function", "text", "paren.lparen"
3282 ],
3283 regex: "(" + identifierRe + ")(\\.)(" + identifierRe + ")(\\s*)(=)(\\s*)(function\\*?)(\\s+)(\\w+)(\\s*)(\\()",
3284 next: "function_arguments"
3285 }, {
3286 token: [
3287 "storage.type", "text", "entity.name.function", "text", "paren.lparen"
3288 ],
3289 regex: "(function\\*?)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
3290 next: "function_arguments"
3291 }, {
3292 token: [
3293 "entity.name.function", "text", "punctuation.operator",
3294 "text", "storage.type", "text", "paren.lparen"
3295 ],
3296 regex: "(" + identifierRe + ")(\\s*)(:)(\\s*)(function\\*?)(\\s*)(\\()",
3297 next: "function_arguments"
3298 }, {
3299 token: [
3300 "text", "text", "storage.type", "text", "paren.lparen"
3301 ],
3302 regex: "(:)(\\s*)(function\\*?)(\\s*)(\\()",
3303 next: "function_arguments"
3304 }, {
3305 token: "keyword",
3306 regex: "from(?=\\s*('|\"))"
3307 }, {
3308 token: "keyword",
3309 regex: "(?:" + kwBeforeRe + ")\\b",
3310 next: "start"
3311 }, {
3312 token: "support.constant",
3313 regex: /that\b/
3314 }, {
3315 token: ["storage.type", "punctuation.operator", "support.function.firebug"],
3316 regex: /(console)(\.)(warn|info|log|error|debug|time|trace|timeEnd|assert)\b/
3317 }, {
3318 token: keywordMapper,
3319 regex: identifierRe
3320 }, {
3321 token: "punctuation.operator",
3322 regex: /[.](?![.])/,
3323 next: "property"
3324 }, {
3325 token: "storage.type",
3326 regex: /=>/,
3327 next: "start"
3328 }, {
3329 token: "keyword.operator",
3330 regex: /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
3331 next: "start"
3332 }, {
3333 token: "punctuation.operator",
3334 regex: /[?:,;.]/,
3335 next: "start"
3336 }, {
3337 token: "paren.lparen",
3338 regex: /[\[({]/,
3339 next: "start"
3340 }, {
3341 token: "paren.rparen",
3342 regex: /[\])}]/
3343 }, {
3344 token: "comment",
3345 regex: /^#!.*$/
3346 }
3347 ],
3348 property: [{
3349 token: "text",
3350 regex: "\\s+"
3351 }, {
3352 token: [
3353 "storage.type", "punctuation.operator", "entity.name.function", "text",
3354 "keyword.operator", "text",
3355 "storage.type", "text", "entity.name.function", "text", "paren.lparen"
3356 ],
3357 regex: "(" + identifierRe + ")(\\.)(" + identifierRe + ")(\\s*)(=)(\\s*)(function\\*?)(?:(\\s+)(\\w+))?(\\s*)(\\()",
3358 next: "function_arguments"
3359 }, {
3360 token: "punctuation.operator",
3361 regex: /[.](?![.])/
3362 }, {
3363 token: "support.function",
3364 regex: /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|lter|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward|rEach)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
3365 }, {
3366 token: "support.function.dom",
3367 regex: /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
3368 }, {
3369 token: "support.constant",
3370 regex: /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
3371 }, {
3372 token: "identifier",
3373 regex: identifierRe
3374 }, {
3375 regex: "",
3376 token: "empty",
3377 next: "no_regex"
3378 }
3379 ],
3380 "start": [
3381 DocCommentHighlightRules.getStartRule("doc-start"),
3382 comments("start"),
3383 {
3384 token: "string.regexp",
3385 regex: "\\/",
3386 next: "regex"
3387 }, {
3388 token: "text",
3389 regex: "\\s+|^$",
3390 next: "start"
3391 }, {
3392 token: "empty",
3393 regex: "",
3394 next: "no_regex"
3395 }
3396 ],
3397 "regex": [
3398 {
3399 token: "regexp.keyword.operator",
3400 regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
3401 }, {
3402 token: "string.regexp",
3403 regex: "/[sxngimy]*",
3404 next: "no_regex"
3405 }, {
3406 token: "invalid",
3407 regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
3408 }, {
3409 token: "constant.language.escape",
3410 regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
3411 }, {
3412 token: "constant.language.delimiter",
3413 regex: /\|/
3414 }, {
3415 token: "constant.language.escape",
3416 regex: /\[\^?/,
3417 next: "regex_character_class"
3418 }, {
3419 token: "empty",
3420 regex: "$",
3421 next: "no_regex"
3422 }, {
3423 defaultToken: "string.regexp"
3424 }
3425 ],
3426 "regex_character_class": [
3427 {
3428 token: "regexp.charclass.keyword.operator",
3429 regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
3430 }, {
3431 token: "constant.language.escape",
3432 regex: "]",
3433 next: "regex"
3434 }, {
3435 token: "constant.language.escape",
3436 regex: "-"
3437 }, {
3438 token: "empty",
3439 regex: "$",
3440 next: "no_regex"
3441 }, {
3442 defaultToken: "string.regexp.charachterclass"
3443 }
3444 ],
3445 "default_parameter": [
3446 {
3447 token: "string",
3448 regex: "'(?=.)",
3449 push: [
3450 {
3451 token: "string",
3452 regex: "'|$",
3453 next: "pop"
3454 }, {
3455 include: "qstring"
3456 }
3457 ]
3458 }, {
3459 token: "string",
3460 regex: '"(?=.)',
3461 push: [
3462 {
3463 token: "string",
3464 regex: '"|$',
3465 next: "pop"
3466 }, {
3467 include: "qqstring"
3468 }
3469 ]
3470 }, {
3471 token: "constant.language",
3472 regex: "null|Infinity|NaN|undefined"
3473 }, {
3474 token: "constant.numeric", // hexadecimal, octal and binary
3475 regex: /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
3476 }, {
3477 token: "constant.numeric", // decimal integers and floats
3478 regex: /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
3479 }, {
3480 token: "punctuation.operator",
3481 regex: ",",
3482 next: "function_arguments"
3483 }, {
3484 token: "text",
3485 regex: "\\s+"
3486 }, {
3487 token: "punctuation.operator",
3488 regex: "$"
3489 }, {
3490 token: "empty",
3491 regex: "",
3492 next: "no_regex"
3493 }
3494 ],
3495 "function_arguments": [
3496 comments("function_arguments"),
3497 {
3498 token: "variable.parameter",
3499 regex: identifierRe
3500 }, {
3501 token: "punctuation.operator",
3502 regex: ","
3503 }, {
3504 token: "text",
3505 regex: "\\s+"
3506 }, {
3507 token: "punctuation.operator",
3508 regex: "$"
3509 }, {
3510 token: "empty",
3511 regex: "",
3512 next: "no_regex"
3513 }
3514 ],
3515 "qqstring": [
3516 {
3517 token: "constant.language.escape",
3518 regex: escapedRe
3519 }, {
3520 token: "string",
3521 regex: "\\\\$",
3522 consumeLineEnd: true
3523 }, {
3524 token: "string",
3525 regex: '"|$',
3526 next: "no_regex"
3527 }, {
3528 defaultToken: "string"
3529 }
3530 ],
3531 "qstring": [
3532 {
3533 token: "constant.language.escape",
3534 regex: escapedRe
3535 }, {
3536 token: "string",
3537 regex: "\\\\$",
3538 consumeLineEnd: true
3539 }, {
3540 token: "string",
3541 regex: "'|$",
3542 next: "no_regex"
3543 }, {
3544 defaultToken: "string"
3545 }
3546 ]
3547 };
3548 if (!options || !options.noES6) {
3549 this.$rules.no_regex.unshift({
3550 regex: "[{}]", onMatch: function (val, state, stack) {
3551 this.next = val == "{" ? this.nextState : "";
3552 if (val == "{" && stack.length) {
3553 stack.unshift("start", state);
3554 }
3555 else if (val == "}" && stack.length) {
3556 stack.shift();
3557 this.next = stack.shift();
3558 if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
3559 return "paren.quasi.end";
3560 }
3561 return val == "{" ? "paren.lparen" : "paren.rparen";
3562 },
3563 nextState: "start"
3564 }, {
3565 token: "string.quasi.start",
3566 regex: /`/,
3567 push: [{
3568 token: "constant.language.escape",
3569 regex: escapedRe
3570 }, {
3571 token: "paren.quasi.start",
3572 regex: /\${/,
3573 push: "start"
3574 }, {
3575 token: "string.quasi.end",
3576 regex: /`/,
3577 next: "pop"
3578 }, {
3579 defaultToken: "string.quasi"
3580 }]
3581 }, {
3582 token: ["variable.parameter", "text"],
3583 regex: "(" + identifierRe + ")(\\s*)(?=\\=>)"
3584 }, {
3585 token: "paren.lparen",
3586 regex: "(\\()(?=.+\\s*=>)",
3587 next: "function_arguments"
3588 }, {
3589 token: "variable.language",
3590 regex: "(?:(?:(?:Weak)?(?:Set|Map))|Promise)\\b"
3591 });
3592 this.$rules["function_arguments"].unshift({
3593 token: "keyword.operator",
3594 regex: "=",
3595 next: "default_parameter"
3596 }, {
3597 token: "keyword.operator",
3598 regex: "\\.{3}"
3599 });
3600 this.$rules["property"].unshift({
3601 token: "support.function",
3602 regex: "(findIndex|repeat|startsWith|endsWith|includes|isSafeInteger|trunc|cbrt|log2|log10|sign|then|catch|"
3603 + "finally|resolve|reject|race|any|all|allSettled|keys|entries|isInteger)\\b(?=\\()"
3604 }, {
3605 token: "constant.language",
3606 regex: "(?:MAX_SAFE_INTEGER|MIN_SAFE_INTEGER|EPSILON)\\b"
3607 });
3608 if (!options || options.jsx != false)
3609 JSX.call(this);
3610 }
3611 this.embedRules(DocCommentHighlightRules, "doc-", [DocCommentHighlightRules.getEndRule("no_regex")]);
3612 this.normalizeRules();
3613 };
3614 oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
3615 function JSX() {
3616 var tagRegex = identifierRe.replace("\\d", "\\d\\-");
3617 var jsxTag = {
3618 onMatch: function (val, state, stack) {
3619 var offset = val.charAt(1) == "/" ? 2 : 1;
3620 if (offset == 1) {
3621 if (state != this.nextState)
3622 stack.unshift(this.next, this.nextState, 0);
3623 else
3624 stack.unshift(this.next);
3625 stack[2]++;
3626 }
3627 else if (offset == 2) {
3628 if (state == this.nextState) {
3629 stack[1]--;
3630 if (!stack[1] || stack[1] < 0) {
3631 stack.shift();
3632 stack.shift();
3633 }
3634 }
3635 }
3636 return [{
3637 type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
3638 value: val.slice(0, offset)
3639 }, {
3640 type: "meta.tag.tag-name.xml",
3641 value: val.substr(offset)
3642 }];
3643 },
3644 regex: "</?" + tagRegex + "",
3645 next: "jsxAttributes",
3646 nextState: "jsx"
3647 };
3648 this.$rules.start.unshift(jsxTag);
3649 var jsxJsRule = {
3650 regex: "{",
3651 token: "paren.quasi.start",
3652 push: "start"
3653 };
3654 this.$rules.jsx = [
3655 jsxJsRule,
3656 jsxTag,
3657 { include: "reference" },
3658 { defaultToken: "string" }
3659 ];
3660 this.$rules.jsxAttributes = [{
3661 token: "meta.tag.punctuation.tag-close.xml",
3662 regex: "/?>",
3663 onMatch: function (value, currentState, stack) {
3664 if (currentState == stack[0])
3665 stack.shift();
3666 if (value.length == 2) {
3667 if (stack[0] == this.nextState)
3668 stack[1]--;
3669 if (!stack[1] || stack[1] < 0) {
3670 stack.splice(0, 2);
3671 }
3672 }
3673 this.next = stack[0] || "start";
3674 return [{ type: this.token, value: value }];
3675 },
3676 nextState: "jsx"
3677 },
3678 jsxJsRule,
3679 comments("jsxAttributes"),
3680 {
3681 token: "entity.other.attribute-name.xml",
3682 regex: tagRegex
3683 }, {
3684 token: "keyword.operator.attribute-equals.xml",
3685 regex: "="
3686 }, {
3687 token: "text.tag-whitespace.xml",
3688 regex: "\\s+"
3689 }, {
3690 token: "string.attribute-value.xml",
3691 regex: "'",
3692 stateName: "jsx_attr_q",
3693 push: [
3694 { token: "string.attribute-value.xml", regex: "'", next: "pop" },
3695 { include: "reference" },
3696 { defaultToken: "string.attribute-value.xml" }
3697 ]
3698 }, {
3699 token: "string.attribute-value.xml",
3700 regex: '"',
3701 stateName: "jsx_attr_qq",
3702 push: [
3703 { token: "string.attribute-value.xml", regex: '"', next: "pop" },
3704 { include: "reference" },
3705 { defaultToken: "string.attribute-value.xml" }
3706 ]
3707 },
3708 jsxTag
3709 ];
3710 this.$rules.reference = [{
3711 token: "constant.language.escape.reference.xml",
3712 regex: "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
3713 }];
3714 }
3715 function comments(next) {
3716 return [
3717 {
3718 token: "comment", // multi line comment
3719 regex: /\/\*/,
3720 next: [
3721 DocCommentHighlightRules.getTagRule(),
3722 { token: "comment", regex: "\\*\\/", next: next || "pop" },
3723 { defaultToken: "comment", caseInsensitive: true }
3724 ]
3725 }, {
3726 token: "comment",
3727 regex: "\\/\\/",
3728 next: [
3729 DocCommentHighlightRules.getTagRule(),
3730 { token: "comment", regex: "$|^", next: next || "pop" },
3731 { defaultToken: "comment", caseInsensitive: true }
3732 ]
3733 }
3734 ];
3735 }
3736 exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
3737
3738 });
3739
3740 ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module){"use strict";
3741 var oop = require("../lib/oop");
3742 var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
3743 var XmlHighlightRules = function (normalize) {
3744 var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
3745 this.$rules = {
3746 start: [
3747 { token: "string.cdata.xml", regex: "<\\!\\[CDATA\\[", next: "cdata" },
3748 {
3749 token: ["punctuation.instruction.xml", "keyword.instruction.xml"],
3750 regex: "(<\\?)(" + tagRegex + ")", next: "processing_instruction"
3751 },
3752 { token: "comment.start.xml", regex: "<\\!--", next: "comment" },
3753 {
3754 token: ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
3755 regex: "(<\\!)(DOCTYPE)(?=[\\s])", next: "doctype", caseInsensitive: true
3756 },
3757 { include: "tag" },
3758 { token: "text.end-tag-open.xml", regex: "</" },
3759 { token: "text.tag-open.xml", regex: "<" },
3760 { include: "reference" },
3761 { defaultToken: "text.xml" }
3762 ],
3763 processing_instruction: [{
3764 token: "entity.other.attribute-name.decl-attribute-name.xml",
3765 regex: tagRegex
3766 }, {
3767 token: "keyword.operator.decl-attribute-equals.xml",
3768 regex: "="
3769 }, {
3770 include: "whitespace"
3771 }, {
3772 include: "string"
3773 }, {
3774 token: "punctuation.xml-decl.xml",
3775 regex: "\\?>",
3776 next: "start"
3777 }],
3778 doctype: [
3779 { include: "whitespace" },
3780 { include: "string" },
3781 { token: "xml-pe.doctype.xml", regex: ">", next: "start" },
3782 { token: "xml-pe.xml", regex: "[-_a-zA-Z0-9:]+" },
3783 { token: "punctuation.int-subset", regex: "\\[", push: "int_subset" }
3784 ],
3785 int_subset: [{
3786 token: "text.xml",
3787 regex: "\\s+"
3788 }, {
3789 token: "punctuation.int-subset.xml",
3790 regex: "]",
3791 next: "pop"
3792 }, {
3793 token: ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
3794 regex: "(<\\!)(" + tagRegex + ")",
3795 push: [{
3796 token: "text",
3797 regex: "\\s+"
3798 },
3799 {
3800 token: "punctuation.markup-decl.xml",
3801 regex: ">",
3802 next: "pop"
3803 },
3804 { include: "string" }]
3805 }],
3806 cdata: [
3807 { token: "string.cdata.xml", regex: "\\]\\]>", next: "start" },
3808 { token: "text.xml", regex: "\\s+" },
3809 { token: "text.xml", regex: "(?:[^\\]]|\\](?!\\]>))+" }
3810 ],
3811 comment: [
3812 { token: "comment.end.xml", regex: "-->", next: "start" },
3813 { defaultToken: "comment.xml" }
3814 ],
3815 reference: [{
3816 token: "constant.language.escape.reference.xml",
3817 regex: "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
3818 }],
3819 attr_reference: [{
3820 token: "constant.language.escape.reference.attribute-value.xml",
3821 regex: "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
3822 }],
3823 tag: [{
3824 token: ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
3825 regex: "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
3826 next: [
3827 { include: "attributes" },
3828 { token: "meta.tag.punctuation.tag-close.xml", regex: "/?>", next: "start" }
3829 ]
3830 }],
3831 tag_whitespace: [
3832 { token: "text.tag-whitespace.xml", regex: "\\s+" }
3833 ],
3834 whitespace: [
3835 { token: "text.whitespace.xml", regex: "\\s+" }
3836 ],
3837 string: [{
3838 token: "string.xml",
3839 regex: "'",
3840 push: [
3841 { token: "string.xml", regex: "'", next: "pop" },
3842 { defaultToken: "string.xml" }
3843 ]
3844 }, {
3845 token: "string.xml",
3846 regex: '"',
3847 push: [
3848 { token: "string.xml", regex: '"', next: "pop" },
3849 { defaultToken: "string.xml" }
3850 ]
3851 }],
3852 attributes: [{
3853 token: "entity.other.attribute-name.xml",
3854 regex: tagRegex
3855 }, {
3856 token: "keyword.operator.attribute-equals.xml",
3857 regex: "="
3858 }, {
3859 include: "tag_whitespace"
3860 }, {
3861 include: "attribute_value"
3862 }],
3863 attribute_value: [{
3864 token: "string.attribute-value.xml",
3865 regex: "'",
3866 push: [
3867 { token: "string.attribute-value.xml", regex: "'", next: "pop" },
3868 { include: "attr_reference" },
3869 { defaultToken: "string.attribute-value.xml" }
3870 ]
3871 }, {
3872 token: "string.attribute-value.xml",
3873 regex: '"',
3874 push: [
3875 { token: "string.attribute-value.xml", regex: '"', next: "pop" },
3876 { include: "attr_reference" },
3877 { defaultToken: "string.attribute-value.xml" }
3878 ]
3879 }]
3880 };
3881 if (this.constructor === XmlHighlightRules)
3882 this.normalizeRules();
3883 };
3884 (function () {
3885 this.embedTagRules = function (HighlightRules, prefix, tag) {
3886 this.$rules.tag.unshift({
3887 token: ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
3888 regex: "(<)(" + tag + "(?=\\s|>|$))",
3889 next: [
3890 { include: "attributes" },
3891 { token: "meta.tag.punctuation.tag-close.xml", regex: "/?>", next: prefix + "start" }
3892 ]
3893 });
3894 this.$rules[tag + "-end"] = [
3895 { include: "attributes" },
3896 { token: "meta.tag.punctuation.tag-close.xml", regex: "/?>", next: "start",
3897 onMatch: function (value, currentState, stack) {
3898 stack.splice(0);
3899 return this.token;
3900 } }
3901 ];
3902 this.embedRules(HighlightRules, prefix, [{
3903 token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
3904 regex: "(</)(" + tag + "(?=\\s|>|$))",
3905 next: tag + "-end"
3906 }, {
3907 token: "string.cdata.xml",
3908 regex: "<\\!\\[CDATA\\["
3909 }, {
3910 token: "string.cdata.xml",
3911 regex: "\\]\\]>"
3912 }]);
3913 };
3914 }).call(TextHighlightRules.prototype);
3915 oop.inherits(XmlHighlightRules, TextHighlightRules);
3916 exports.XmlHighlightRules = XmlHighlightRules;
3917
3918 });
3919
3920 ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module){"use strict";
3921 var oop = require("../lib/oop");
3922 var lang = require("../lib/lang");
3923 var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
3924 var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
3925 var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
3926 var tagMap = lang.createMap({
3927 a: 'anchor',
3928 button: 'form',
3929 form: 'form',
3930 img: 'image',
3931 input: 'form',
3932 label: 'form',
3933 option: 'form',
3934 script: 'script',
3935 select: 'form',
3936 textarea: 'form',
3937 style: 'style',
3938 table: 'table',
3939 tbody: 'table',
3940 td: 'table',
3941 tfoot: 'table',
3942 th: 'table',
3943 tr: 'table'
3944 });
3945 var HtmlHighlightRules = function () {
3946 XmlHighlightRules.call(this);
3947 this.addRules({
3948 attributes: [{
3949 include: "tag_whitespace"
3950 }, {
3951 token: "entity.other.attribute-name.xml",
3952 regex: "[-_a-zA-Z0-9:.]+"
3953 }, {
3954 token: "keyword.operator.attribute-equals.xml",
3955 regex: "=",
3956 push: [{
3957 include: "tag_whitespace"
3958 }, {
3959 token: "string.unquoted.attribute-value.html",
3960 regex: "[^<>='\"`\\s]+",
3961 next: "pop"
3962 }, {
3963 token: "empty",
3964 regex: "",
3965 next: "pop"
3966 }]
3967 }, {
3968 include: "attribute_value"
3969 }],
3970 tag: [{
3971 token: function (start, tag) {
3972 var group = tagMap[tag];
3973 return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
3974 "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
3975 },
3976 regex: "(</?)([-_a-zA-Z0-9:.]+)",
3977 next: "tag_stuff"
3978 }],
3979 tag_stuff: [
3980 { include: "attributes" },
3981 { token: "meta.tag.punctuation.tag-close.xml", regex: "/?>", next: "start" }
3982 ]
3983 });
3984 this.embedTagRules(CssHighlightRules, "css-", "style");
3985 this.embedTagRules(new JavaScriptHighlightRules({ jsx: false }).getRules(), "js-", "script");
3986 if (this.constructor === HtmlHighlightRules)
3987 this.normalizeRules();
3988 };
3989 oop.inherits(HtmlHighlightRules, XmlHighlightRules);
3990 exports.HtmlHighlightRules = HtmlHighlightRules;
3991
3992 });
3993
3994 ace.define("ace/mode/csound_document_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/csound_orchestra_highlight_rules","ace/mode/csound_score_highlight_rules","ace/mode/html_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module){"use strict";
3995 var oop = require("../lib/oop");
3996 var CsoundOrchestraHighlightRules = require("./csound_orchestra_highlight_rules").CsoundOrchestraHighlightRules;
3997 var CsoundScoreHighlightRules = require("./csound_score_highlight_rules").CsoundScoreHighlightRules;
3998 var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
3999 var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
4000 var CsoundDocumentHighlightRules = function () {
4001 var orchestraHighlightRules = new CsoundOrchestraHighlightRules("csound-");
4002 var scoreHighlightRules = new CsoundScoreHighlightRules("csound-score-");
4003 this.$rules = {
4004 "start": [
4005 {
4006 token: ["meta.tag.punctuation.tag-open.csound-document", "entity.name.tag.begin.csound-document", "meta.tag.punctuation.tag-close.csound-document"],
4007 regex: /(<)(CsoundSynthesi[sz]er)(>)/,
4008 next: "synthesizer"
4009 },
4010 { defaultToken: "text.csound-document" }
4011 ],
4012 "synthesizer": [
4013 {
4014 token: ["meta.tag.punctuation.end-tag-open.csound-document", "entity.name.tag.begin.csound-document", "meta.tag.punctuation.tag-close.csound-document"],
4015 regex: "(</)(CsoundSynthesi[sz]er)(>)",
4016 next: "start"
4017 }, {
4018 token: ["meta.tag.punctuation.tag-open.csound-document", "entity.name.tag.begin.csound-document", "meta.tag.punctuation.tag-close.csound-document"],
4019 regex: "(<)(CsInstruments)(>)",
4020 next: orchestraHighlightRules.embeddedRulePrefix + "start"
4021 }, {
4022 token: ["meta.tag.punctuation.tag-open.csound-document", "entity.name.tag.begin.csound-document", "meta.tag.punctuation.tag-close.csound-document"],
4023 regex: "(<)(CsScore)(>)",
4024 next: scoreHighlightRules.embeddedRulePrefix + "start"
4025 }, {
4026 token: ["meta.tag.punctuation.tag-open.csound-document", "entity.name.tag.begin.csound-document", "meta.tag.punctuation.tag-close.csound-document"],
4027 regex: "(<)([Hh][Tt][Mm][Ll])(>)",
4028 next: "html-start"
4029 }
4030 ]
4031 };
4032 this.embedRules(orchestraHighlightRules.getRules(), orchestraHighlightRules.embeddedRulePrefix, [{
4033 token: ["meta.tag.punctuation.end-tag-open.csound-document", "entity.name.tag.begin.csound-document", "meta.tag.punctuation.tag-close.csound-document"],
4034 regex: "(</)(CsInstruments)(>)",
4035 next: "synthesizer"
4036 }]);
4037 this.embedRules(scoreHighlightRules.getRules(), scoreHighlightRules.embeddedRulePrefix, [{
4038 token: ["meta.tag.punctuation.end-tag-open.csound-document", "entity.name.tag.begin.csound-document", "meta.tag.punctuation.tag-close.csound-document"],
4039 regex: "(</)(CsScore)(>)",
4040 next: "synthesizer"
4041 }]);
4042 this.embedRules(HtmlHighlightRules, "html-", [{
4043 token: ["meta.tag.punctuation.end-tag-open.csound-document", "entity.name.tag.begin.csound-document", "meta.tag.punctuation.tag-close.csound-document"],
4044 regex: "(</)([Hh][Tt][Mm][Ll])(>)",
4045 next: "synthesizer"
4046 }]);
4047 this.normalizeRules();
4048 };
4049 oop.inherits(CsoundDocumentHighlightRules, TextHighlightRules);
4050 exports.CsoundDocumentHighlightRules = CsoundDocumentHighlightRules;
4051
4052 });
4053
4054 ace.define("ace/mode/csound_document",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/csound_document_highlight_rules"], function(require, exports, module){"use strict";
4055 var oop = require("../lib/oop");
4056 var TextMode = require("./text").Mode;
4057 var CsoundDocumentHighlightRules = require("./csound_document_highlight_rules").CsoundDocumentHighlightRules;
4058 var Mode = function () {
4059 this.HighlightRules = CsoundDocumentHighlightRules;
4060 };
4061 oop.inherits(Mode, TextMode);
4062 (function () {
4063 this.$id = "ace/mode/csound_document";
4064 this.snippetFileId = "ace/snippets/csound_document";
4065 }).call(Mode.prototype);
4066 exports.Mode = Mode;
4067
4068 }); (function() {
4069 ace.require(["ace/mode/csound_document"], function(m) {
4070 if (typeof module == "object" && typeof exports == "object" && module) {
4071 module.exports = m;
4072 }
4073 });
4074 })();
4075