mode-csound_document.js 121 KB

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