cf5993b8385b33190730126e703eb9c4.js 123 KB

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