(function(){function f(a){var d=k;a&&(k[a]||(k[a]={}),d=k[a]);d.define&&d.define.packaged||(r.original=d.define,d.define=r,d.define.packaged=!0);d.require&&d.require.packaged||(m.original=d.require,d.require=m,d.require.packaged=!0)}var k=function(){return this}();k||"undefined"==typeof window||(k=window);if("undefined"===typeof requirejs){var r=function(a,d,g){"string"!==typeof a?r.original?r.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace()):
(2==arguments.length&&(g=d),r.modules[a]||(r.payloads[a]=g,r.modules[a]=null))};r.modules={};r.payloads={};var e=function(a,d,g){if("string"===typeof d){if(a=c(a,d),void 0!=a)return g&&g(),a}else if("[object Array]"===Object.prototype.toString.call(d)){for(var b=[],h=0,t=d.length;h<t;++h){var l=c(a,d[h]);if(void 0==l&&m.original)return;b.push(l)}return g&&g.apply(null,b)||!0}},m=function(a,d){var g=e("",a,d);return void 0==g&&m.original?m.original.apply(this,arguments):g},b=function(a,d){if(-1!==
d.indexOf("!")){var g=d.split("!");return b(a,g[0])+"!"+b(a,g[1])}if("."==d.charAt(0))for(d=a.split("/").slice(0,-1).join("/")+"/"+d;-1!==d.indexOf(".")&&g!=d;)g=d,d=d.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"");return d},c=function(a,d){d=b(a,d);var g=r.modules[d];if(!g){g=r.payloads[d];if("function"===typeof g){var c={},h={id:d,uri:"",exports:c,packaged:!0},c=g(function(a,g){return e(d,a,g)},c,h)||h.exports;r.modules[d]=c;delete r.payloads[d]}g=r.modules[d]=c||g}return g};f("")}})();
define("ace/lib/regexp",["require","exports","module"],function(f,k,r){function e(a,d,b){if(Array.prototype.indexOf)return a.indexOf(d,b);for(b=b||0;b<a.length;b++)if(a[b]===d)return b;return-1}var m=RegExp.prototype.exec,b=RegExp.prototype.test,c=String.prototype.replace,a=void 0===m.call(/()??/,"")[1],d=function(){var a=/^/g;b.call(a,"");return!a.lastIndex}();d&&a||(RegExp.prototype.exec=function(g){var b=m.apply(this,arguments),h;if("string"==typeof g&&b){!a&&1<b.length&&-1<e(b,"")&&(h=RegExp(this.source,
c.call((this.global?"g":"")+(this.ignoreCase?"i":"")+(this.multiline?"m":"")+(this.extended?"x":"")+(this.sticky?"y":""),"g","")),c.call(g.slice(b.index),h,function(){for(var a=1;a<arguments.length-2;a++)void 0===arguments[a]&&(b[a]=void 0)}));if(this._xregexp&&this._xregexp.captureNames)for(var t=1;t<b.length;t++)(h=this._xregexp.captureNames[t-1])&&(b[h]=b[t]);!d&&this.global&&!b[0].length&&this.lastIndex>b.index&&this.lastIndex--}return b},d||(RegExp.prototype.test=function(a){(a=m.call(this,a))&&
this.global&&!a[0].length&&this.lastIndex>a.index&&this.lastIndex--;return!!a}))});
define("ace/lib/es5-shim",["require","exports","module"],function(f,k,r){function e(){}function m(a){try{return Object.defineProperty(a,"sentinel",{}),"sentinel"in a}catch(d){}}function b(a){a=+a;a!==a?a=0:0!==a&&a!==1/0&&a!==-(1/0)&&(a=(0<a||-1)*Math.floor(Math.abs(a)));return a}Function.prototype.bind||(Function.prototype.bind=function(d){var g=this;if("function"!=typeof g)throw new TypeError("Function.prototype.bind called on incompatible "+g);var b=a.call(arguments,1),s=function(){if(this instanceof
s){var c=g.apply(this,b.concat(a.call(arguments)));return Object(c)===c?c:this}return g.apply(d,b.concat(a.call(arguments)))};g.prototype&&(e.prototype=g.prototype,s.prototype=new e,e.prototype=null);return s});f=Function.prototype.call;var c=Object.prototype,a=Array.prototype.slice,d=f.bind(c.toString),g=f.bind(c.hasOwnProperty),n,h,t,l,p;if(p=g(c,"__defineGetter__"))n=f.bind(c.__defineGetter__),h=f.bind(c.__defineSetter__),t=f.bind(c.__lookupGetter__),l=f.bind(c.__lookupSetter__);if(2!=[1,2].splice(0).length)if(function(){function a(d){d=
Array(d+2);d[0]=d[1]=0;return d}var d=[],g;d.splice.apply(d,a(20));d.splice.apply(d,a(26));g=d.length;d.splice(5,0,"XXX");g+1==d.length;if(g+1==d.length)return!0}()){var D=Array.prototype.splice;Array.prototype.splice=function(d,g){return arguments.length?D.apply(this,[void 0===d?0:d,void 0===g?this.length-d:g].concat(a.call(arguments,2))):[]}}else Array.prototype.splice=function(d,g){var b=this.length;0<d?d>b&&(d=b):void 0==d?d=0:0>d&&(d=Math.max(b+d,0));d+g<b||(g=b-d);var s=this.slice(d,d+g),c=
a.call(arguments,2),n=c.length;if(d===b)n&&this.push.apply(this,c);else{var h=Math.min(g,b-d),u=d+h,l=u+n-h,q=b-u,b=b-h;if(l<u)for(h=0;h<q;++h)this[l+h]=this[u+h];else if(l>u)for(h=q;h--;)this[l+h]=this[u+h];if(n&&d===b)this.length=b,this.push.apply(this,c);else for(this.length=b+n,h=0;h<n;++h)this[d+h]=c[h]}return s};Array.isArray||(Array.isArray=function(a){return"[object Array]"==d(a)});f=Object("a");var s="a"!=f[0]||!(0 in f);Array.prototype.forEach||(Array.prototype.forEach=function(a,g){var b=
G(this),c=s&&"[object String]"==d(this)?this.split(""):b,n=-1,h=c.length>>>0;if("[object Function]"!=d(a))throw new TypeError;for(;++n<h;)n in c&&a.call(g,c[n],n,b)});Array.prototype.map||(Array.prototype.map=function(a,g){var b=G(this),c=s&&"[object String]"==d(this)?this.split(""):b,n=c.length>>>0,h=Array(n);if("[object Function]"!=d(a))throw new TypeError(a+" is not a function");for(var u=0;u<n;u++)u in c&&(h[u]=a.call(g,c[u],u,b));return h});Array.prototype.filter||(Array.prototype.filter=function(a,
g){var b=G(this),c=s&&"[object String]"==d(this)?this.split(""):b,n=c.length>>>0,h=[],u;if("[object Function]"!=d(a))throw new TypeError(a+" is not a function");for(var l=0;l<n;l++)l in c&&(u=c[l],a.call(g,u,l,b)&&h.push(u));return h});Array.prototype.every||(Array.prototype.every=function(a,g){var b=G(this),c=s&&"[object String]"==d(this)?this.split(""):b,n=c.length>>>0;if("[object Function]"!=d(a))throw new TypeError(a+" is not a function");for(var h=0;h<n;h++)if(h in c&&!a.call(g,c[h],h,b))return!1;
return!0});Array.prototype.some||(Array.prototype.some=function(a,g){var b=G(this),c=s&&"[object String]"==d(this)?this.split(""):b,n=c.length>>>0;if("[object Function]"!=d(a))throw new TypeError(a+" is not a function");for(var h=0;h<n;h++)if(h in c&&a.call(g,c[h],h,b))return!0;return!1});Array.prototype.reduce||(Array.prototype.reduce=function(a){var g=G(this),b=s&&"[object String]"==d(this)?this.split(""):g,c=b.length>>>0;if("[object Function]"!=d(a))throw new TypeError(a+" is not a function");
if(!c&&1==arguments.length)throw new TypeError("reduce of empty array with no initial value");var n=0,h;if(2<=arguments.length)h=arguments[1];else{do{if(n in b){h=b[n++];break}if(++n>=c)throw new TypeError("reduce of empty array with no initial value");}while(1)}for(;n<c;n++)n in b&&(h=a.call(void 0,h,b[n],n,g));return h});Array.prototype.reduceRight||(Array.prototype.reduceRight=function(a){var g=G(this),b=s&&"[object String]"==d(this)?this.split(""):g,c=b.length>>>0;if("[object Function]"!=d(a))throw new TypeError(a+
" is not a function");if(!c&&1==arguments.length)throw new TypeError("reduceRight of empty array with no initial value");var n,c=c-1;if(2<=arguments.length)n=arguments[1];else{do{if(c in b){n=b[c--];break}if(0>--c)throw new TypeError("reduceRight of empty array with no initial value");}while(1)}do c in this&&(n=a.call(void 0,n,b[c],c,g));while(c--);return n});Array.prototype.indexOf&&-1==[0,1].indexOf(1,2)||(Array.prototype.indexOf=function(a){var g=s&&"[object String]"==d(this)?this.split(""):G(this),
c=g.length>>>0;if(!c)return-1;var n=0;1<arguments.length&&(n=b(arguments[1]));for(n=0<=n?n:Math.max(0,c+n);n<c;n++)if(n in g&&g[n]===a)return n;return-1});Array.prototype.lastIndexOf&&-1==[0,1].lastIndexOf(0,-3)||(Array.prototype.lastIndexOf=function(a){var g=s&&"[object String]"==d(this)?this.split(""):G(this),c=g.length>>>0;if(!c)return-1;var n=c-1;1<arguments.length&&(n=Math.min(n,b(arguments[1])));for(n=0<=n?n:c-Math.abs(n);0<=n;n--)if(n in g&&a===g[n])return n;return-1});Object.getPrototypeOf||
(Object.getPrototypeOf=function(a){return a.__proto__||(a.constructor?a.constructor.prototype:c)});Object.getOwnPropertyDescriptor||(Object.getOwnPropertyDescriptor=function(a,d){if("object"!=typeof a&&"function"!=typeof a||null===a)throw new TypeError("Object.getOwnPropertyDescriptor called on a non-object: "+a);if(g(a,d)){var b,s,n;b={enumerable:!0,configurable:!0};if(p){var h=a.__proto__;a.__proto__=c;s=t(a,d);n=l(a,d);a.__proto__=h;if(s||n)return s&&(b.get=s),n&&(b.set=n),b}b.value=a[d];return b}});
Object.getOwnPropertyNames||(Object.getOwnPropertyNames=function(a){return Object.keys(a)});if(!Object.create){var q;q=null===Object.prototype.__proto__?function(){return{__proto__:null}}:function(){var a={},d;for(d in a)a[d]=null;a.constructor=a.hasOwnProperty=a.propertyIsEnumerable=a.isPrototypeOf=a.toLocaleString=a.toString=a.valueOf=a.__proto__=null;return a};Object.create=function(a,d){var g;if(null===a)g=q();else{if("object"!=typeof a)throw new TypeError("typeof prototype["+typeof a+"] != 'object'");
g=function(){};g.prototype=a;g=new g;g.__proto__=a}void 0!==d&&Object.defineProperties(g,d);return g}}if(Object.defineProperty&&(f=m({}),k="undefined"==typeof document||m(document.createElement("div")),!f||!k))var v=Object.defineProperty;if(!Object.defineProperty||v)Object.defineProperty=function(a,d,b){if("object"!=typeof a&&"function"!=typeof a||null===a)throw new TypeError("Object.defineProperty called on non-object: "+a);if("object"!=typeof b&&"function"!=typeof b||null===b)throw new TypeError("Property description must be an object: "+
b);if(v)try{return v.call(Object,a,d,b)}catch(s){}if(g(b,"value"))if(p&&(t(a,d)||l(a,d))){var u=a.__proto__;a.__proto__=c;delete a[d];a[d]=b.value;a.__proto__=u}else a[d]=b.value;else{if(!p)throw new TypeError("getters & setters can not be defined on this javascript engine");g(b,"get")&&n(a,d,b.get);g(b,"set")&&h(a,d,b.set)}return a};Object.defineProperties||(Object.defineProperties=function(a,d){for(var b in d)g(d,b)&&Object.defineProperty(a,b,d[b]);return a});Object.seal||(Object.seal=function(a){return a});
Object.freeze||(Object.freeze=function(a){return a});try{Object.freeze(function(){})}catch(u){Object.freeze=function(a){return function(d){return"function"==typeof d?d:a(d)}}(Object.freeze)}Object.preventExtensions||(Object.preventExtensions=function(a){return a});Object.isSealed||(Object.isSealed=function(a){return!1});Object.isFrozen||(Object.isFrozen=function(a){return!1});Object.isExtensible||(Object.isExtensible=function(a){if(Object(a)===a)throw new TypeError;for(var d="";g(a,d);)d+="?";a[d]=
!0;var b=g(a,d);delete a[d];return b});if(!Object.keys){var x=!0,B="toString toLocaleString valueOf hasOwnProperty isPrototypeOf propertyIsEnumerable constructor".split(" "),I=B.length,C;for(C in{toString:null})x=!1;Object.keys=function(a){if("object"!=typeof a&&"function"!=typeof a||null===a)throw new TypeError("Object.keys called on a non-object");var d=[],b;for(b in a)g(a,b)&&d.push(b);if(x)for(b=0;b<I;b++){var c=B[b];g(a,c)&&d.push(c)}return d}}Date.now||(Date.now=function(){return(new Date).getTime()});
C="\t\n\x0B\f\r \u00a0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029\ufeff";if(!String.prototype.trim||C.trim()){C="["+C+"]";var y=new RegExp("^"+C+C+"*"),A=new RegExp(C+C+"*$");String.prototype.trim=function(){return String(this).replace(y,"").replace(A,"")}}var G=function(a){if(null==a)throw new TypeError("can't convert "+a+" to object");return Object(a)}});
define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/regexp","ace/lib/es5-shim"],function(f,k,r){f("./regexp");f("./es5-shim")});
define("ace/lib/dom",["require","exports","module"],function(f,k,r){k.getDocumentHead=function(e){e||(e=document);return e.head||e.getElementsByTagName("head")[0]||e.documentElement};k.createElement=function(e,m){return document.createElementNS?document.createElementNS(m||"http://www.w3.org/1999/xhtml",e):document.createElement(e)};k.hasCssClass=function(e,m){return-1!==(e.className||"").split(/\s+/g).indexOf(m)};k.addCssClass=function(e,m){k.hasCssClass(e,m)||(e.className+=" "+m)};k.removeCssClass=
function(e,m){for(var b=e.className.split(/\s+/g);;){var c=b.indexOf(m);if(-1==c)break;b.splice(c,1)}e.className=b.join(" ")};k.toggleCssClass=function(e,m){for(var b=e.className.split(/\s+/g),c=!0;;){var a=b.indexOf(m);if(-1==a)break;c=!1;b.splice(a,1)}c&&b.push(m);e.className=b.join(" ");return c};"undefined"==typeof document?k.importCssString=function(){}:(k.setCssClass=function(e,m,b){b?k.addCssClass(e,m):k.removeCssClass(e,m)},k.hasCssString=function(e,m){var b=0,c;m=m||document;if(m.createStyleSheet&&
(c=m.styleSheets))for(;b<c.length;){if(c[b++].owningElement.id===e)return!0}else if(c=m.getElementsByTagName("style"))for(;b<c.length;)if(c[b++].id===e)return!0;return!1},k.importCssString=function(e,m,b){b=b||document;if(m&&k.hasCssString(m,b))return null;var c;b.createStyleSheet?(c=b.createStyleSheet(),c.cssText=e,m&&(c.owningElement.id=m)):(c=b.createElementNS?b.createElementNS("http://www.w3.org/1999/xhtml","style"):b.createElement("style"),c.appendChild(b.createTextNode(e)),m&&(c.id=m),k.getDocumentHead(b).appendChild(c))},
k.importCssStylsheet=function(e,m){if(m.createStyleSheet)m.createStyleSheet(e);else{var b=k.createElement("link");b.rel="stylesheet";b.href=e;k.getDocumentHead(m).appendChild(b)}},k.getInnerWidth=function(e){return parseInt(k.computedStyle(e,"paddingLeft"),10)+parseInt(k.computedStyle(e,"paddingRight"),10)+e.clientWidth},k.getInnerHeight=function(e){return parseInt(k.computedStyle(e,"paddingTop"),10)+parseInt(k.computedStyle(e,"paddingBottom"),10)+e.clientHeight},void 0!==window.pageYOffset?(k.getPageScrollTop=
function(){return window.pageYOffset},k.getPageScrollLeft=function(){return window.pageXOffset}):(k.getPageScrollTop=function(){return document.body.scrollTop},k.getPageScrollLeft=function(){return document.body.scrollLeft}),k.computedStyle=window.getComputedStyle?function(e,m){return m?(window.getComputedStyle(e,"")||{})[m]||"":window.getComputedStyle(e,"")||{}}:function(e,m){return m?e.currentStyle[m]:e.currentStyle},k.scrollbarWidth=function(e){var m=k.createElement("ace_inner");m.style.width=
"100%";m.style.minWidth="0px";m.style.height="200px";m.style.display="block";var b=k.createElement("ace_outer"),c=b.style;c.position="absolute";c.left="-10000px";c.overflow="hidden";c.width="200px";c.minWidth="0px";c.height="150px";c.display="block";b.appendChild(m);e=e.documentElement;e.appendChild(b);var a=m.offsetWidth;c.overflow="scroll";m=m.offsetWidth;a==m&&(m=b.clientWidth);e.removeChild(b);return a-m},k.setInnerHtml=function(e,m){var b=e.cloneNode(!1);b.innerHTML=m;e.parentNode.replaceChild(b,
e);return b},"textContent"in document.documentElement?(k.setInnerText=function(e,m){e.textContent=m},k.getInnerText=function(e){return e.textContent}):(k.setInnerText=function(e,m){e.innerText=m},k.getInnerText=function(e){return e.innerText}),k.getParentWindow=function(e){return e.defaultView||e.parentWindow})});
define("ace/lib/oop",["require","exports","module"],function(f,k,r){k.inherits=function(e,m){e.super_=m;e.prototype=Object.create(m.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})};k.mixin=function(e,m){for(var b in m)e[b]=m[b];return e};k.implement=function(e,m){k.mixin(e,m)}});
define("ace/lib/keys",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/oop"],function(f,k,r){f("./fixoldbrowsers");var e=f("./oop"),m=function(){var b={MODIFIER_KEYS:{16:"Shift",17:"Ctrl",18:"Alt",224:"Meta"},KEY_MODS:{ctrl:1,alt:2,option:2,shift:4,"super":8,meta:8,command:8,cmd:8},FUNCTION_KEYS:{8:"Backspace",9:"Tab",13:"Return",19:"Pause",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"Print",45:"Insert",46:"Delete",96:"Numpad0",
97:"Numpad1",98:"Numpad2",99:"Numpad3",100:"Numpad4",101:"Numpad5",102:"Numpad6",103:"Numpad7",104:"Numpad8",105:"Numpad9","-13":"NumpadEnter",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"Numlock",145:"Scrolllock"},PRINTABLE_KEYS:{32:" ",48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",59:";",61:"=",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",
81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",107:"+",109:"-",110:".",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"}},c,a;for(a in b.FUNCTION_KEYS)c=b.FUNCTION_KEYS[a].toLowerCase(),b[c]=parseInt(a,10);for(a in b.PRINTABLE_KEYS)c=b.PRINTABLE_KEYS[a].toLowerCase(),b[c]=parseInt(a,10);e.mixin(b,b.MODIFIER_KEYS);e.mixin(b,b.PRINTABLE_KEYS);e.mixin(b,b.FUNCTION_KEYS);b.enter=b["return"];b.escape=b.esc;b.del=b["delete"];b[173]="-";(function(){for(var a=
["cmd","ctrl","alt","shift"],g=Math.pow(2,a.length);g--;)b.KEY_MODS[g]=a.filter(function(a){return g&b.KEY_MODS[a]}).join("-")+"-"})();b.KEY_MODS[0]="";b.KEY_MODS[-1]="input-";return b}();e.mixin(k,m);k.keyCodeToString=function(b){var c=m[b];"string"!=typeof c&&(c=String.fromCharCode(b));return c.toLowerCase()}});
define("ace/lib/useragent",["require","exports","module"],function(f,k,r){k.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"};k.getOS=function(){return k.isMac?k.OS.MAC:k.isLinux?k.OS.LINUX:k.OS.WINDOWS};"object"==typeof navigator&&(f=(navigator.platform.match(/mac|win|linux/i)||["other"])[0].toLowerCase(),r=navigator.userAgent,k.isWin="win"==f,k.isMac="mac"==f,k.isLinux="linux"==f,k.isIE="Microsoft Internet Explorer"==navigator.appName||0<=navigator.appName.indexOf("MSAppHost")?parseFloat((r.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||
[])[1]):parseFloat((r.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),k.isOldIE=k.isIE&&9>k.isIE,k.isGecko=k.isMozilla=(window.Controllers||window.controllers)&&"Gecko"===window.navigator.product,k.isOldGecko=k.isGecko&&4>parseInt((r.match(/rv\:(\d+)/)||[])[1],10),k.isOpera=window.opera&&"[object Opera]"==Object.prototype.toString.call(window.opera),k.isWebKit=parseFloat(r.split("WebKit/")[1])||void 0,k.isChrome=parseFloat(r.split(" Chrome/")[1])||void 0,k.isAIR=0<=r.indexOf("AdobeAIR"),
k.isIPad=0<=r.indexOf("iPad"),k.isTouchPad=0<=r.indexOf("TouchPad"),k.isChromeOS=0<=r.indexOf(" CrOS "))});
define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(f,k,r){function e(n,h,t){var l=a(h);if(!c.isMac&&d){if(d[91]||d[92])l|=8;if(d.altGr)if(3!=(3&l))d.altGr=0;else return;if(18===t||17===t){var p="location"in h?h.location:h.keyLocation;17===t&&1===p?1==d[t]&&(g=h.timeStamp):18===t&&3===l&&2===p&&50>h.timeStamp-g&&(d.altGr=!0)}}t in b.MODIFIER_KEYS&&(t=-1);l&8&&(91===t||93===t)&&(t=-1);if(!l&&13===t&&(p="location"in h?h.location:h.keyLocation,3===p&&(n(h,
l,-t),h.defaultPrevented)))return;if(c.isChromeOS&&l&8){n(h,l,t);if(h.defaultPrevented)return;l&=-9}return l||t in b.FUNCTION_KEYS||t in b.PRINTABLE_KEYS?n(h,l,t):!1}function m(a){d=Object.create(null)}var b=f("./keys"),c=f("./useragent");k.addListener=function(a,d,g){if(a.addEventListener)return a.addEventListener(d,g,!1);if(a.attachEvent){var b=function(){g.call(a,window.event)};g._wrapper=b;a.attachEvent("on"+d,b)}};k.removeListener=function(a,d,g){if(a.removeEventListener)return a.removeEventListener(d,
g,!1);a.detachEvent&&a.detachEvent("on"+d,g._wrapper||g)};k.stopEvent=function(a){k.stopPropagation(a);k.preventDefault(a);return!1};k.stopPropagation=function(a){a.stopPropagation?a.stopPropagation():a.cancelBubble=!0};k.preventDefault=function(a){a.preventDefault?a.preventDefault():a.returnValue=!1};k.getButton=function(a){return"dblclick"==a.type?0:"contextmenu"==a.type||c.isMac&&a.ctrlKey&&!a.altKey&&!a.shiftKey?2:a.preventDefault?a.button:{1:0,2:2,4:1}[a.button]};k.capture=function(a,d,g){function b(a){d&&
d(a);g&&g(a);k.removeListener(document,"mousemove",d,!0);k.removeListener(document,"mouseup",b,!0);k.removeListener(document,"dragstart",b,!0)}k.addListener(document,"mousemove",d,!0);k.addListener(document,"mouseup",b,!0);k.addListener(document,"dragstart",b,!0);return b};k.addMouseWheelListener=function(a,d){"onmousewheel"in a?k.addListener(a,"mousewheel",function(a){void 0!==a.wheelDeltaX?(a.wheelX=-a.wheelDeltaX/8,a.wheelY=-a.wheelDeltaY/8):(a.wheelX=0,a.wheelY=-a.wheelDelta/8);d(a)}):"onwheel"in
a?k.addListener(a,"wheel",function(a){switch(a.deltaMode){case a.DOM_DELTA_PIXEL:a.wheelX=.35*a.deltaX||0;a.wheelY=.35*a.deltaY||0;break;case a.DOM_DELTA_LINE:case a.DOM_DELTA_PAGE:a.wheelX=5*(a.deltaX||0),a.wheelY=5*(a.deltaY||0)}d(a)}):k.addListener(a,"DOMMouseScroll",function(a){a.axis&&a.axis==a.HORIZONTAL_AXIS?(a.wheelX=5*(a.detail||0),a.wheelY=0):(a.wheelX=0,a.wheelY=5*(a.detail||0));d(a)})};k.addMultiMouseDownListener=function(a,d,g,b){var p=0,e,s,q,m={2:"dblclick",3:"tripleclick",4:"quadclick"};
k.addListener(a,"mousedown",function(a){0!==k.getButton(a)?p=0:1<a.detail?(p++,4<p&&(p=1)):p=1;if(c.isIE){var n=5<Math.abs(a.clientX-e)||5<Math.abs(a.clientY-s);if(!q||n)p=1;q&&clearTimeout(q);q=setTimeout(function(){q=null},d[p-1]||600);1==p&&(e=a.clientX,s=a.clientY)}a._clicks=p;g[b]("mousedown",a);if(4<p)p=0;else if(1<p)return g[b](m[p],a)});c.isOldIE&&k.addListener(a,"dblclick",function(a){p=2;q&&clearTimeout(q);q=setTimeout(function(){q=null},d[p-1]||600);g[b]("mousedown",a);g[b](m[p],a)})};
var a=!c.isMac||!c.isOpera||"KeyboardEvent"in window?function(a){return 0|(a.ctrlKey?1:0)|(a.altKey?2:0)|(a.shiftKey?4:0)|(a.metaKey?8:0)}:function(a){return 0|(a.metaKey?1:0)|(a.altKey?2:0)|(a.shiftKey?4:0)|(a.ctrlKey?8:0)};k.getModifierString=function(d){return b.KEY_MODS[a(d)]};var d=null,g=0;k.addCommandKeyListener=function(a,g){var b=k.addListener;if(c.isOldGecko||c.isOpera&&!("KeyboardEvent"in window)){var l=null;b(a,"keydown",function(a){l=a.keyCode});b(a,"keypress",function(a){return e(g,
a,l)})}else{var p=null;b(a,"keydown",function(a){d[a.keyCode]=(d[a.keyCode]||0)+1;var b=e(g,a,a.keyCode);p=a.defaultPrevented;return b});b(a,"keypress",function(a){p&&(a.ctrlKey||a.altKey||a.shiftKey||a.metaKey)&&(k.stopEvent(a),p=null)});b(a,"keyup",function(a){d[a.keyCode]=null});d||(m(),b(window,"focus",m))}};window.postMessage&&!c.isOldIE&&(k.nextTick=function(a,d){d=d||window;k.addListener(d,"message",function l(g){"zero-timeout-message-1"==g.data&&(k.stopPropagation(g),k.removeListener(d,"message",
l),a())});d.postMessage("zero-timeout-message-1","*")});k.nextFrame=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame;k.nextFrame=k.nextFrame?k.nextFrame.bind(window):function(a){setTimeout(a,17)}});
define("ace/lib/lang",["require","exports","module"],function(f,k,r){k.last=function(b){return b[b.length-1]};k.stringReverse=function(b){return b.split("").reverse().join("")};k.stringRepeat=function(b,c){for(var a="";0<c;)if(c&1&&(a+=b),c>>=1)b+=b;return a};var e=/^\s\s*/,m=/\s\s*$/;k.stringTrimLeft=function(b){return b.replace(e,"")};k.stringTrimRight=function(b){return b.replace(m,"")};k.copyObject=function(b){var c={},a;for(a in b)c[a]=b[a];return c};k.copyArray=function(b){for(var c=[],a=0,
d=b.length;a<d;a++)c[a]=b[a]&&"object"==typeof b[a]?this.copyObject(b[a]):b[a];return c};k.deepCopy=function c(a){if("object"!==typeof a||!a)return a;var d;if(Array.isArray(a)){d=[];for(var g=0;g<a.length;g++)d[g]=c(a[g]);return d}d=a.constructor;if(d===RegExp)return a;d=d();for(g in a)d[g]=c(a[g]);return d};k.arrayToMap=function(c){for(var a={},d=0;d<c.length;d++)a[c[d]]=1;return a};k.createMap=function(c){var a=Object.create(null),d;for(d in c)a[d]=c[d];return a};k.arrayRemove=function(c,a){for(var d=
0;d<=c.length;d++)a===c[d]&&c.splice(d,1)};k.escapeRegExp=function(c){return c.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")};k.escapeHTML=function(c){return c.replace(/&/g,"&#38;").replace(/"/g,"&#34;").replace(/'/g,"&#39;").replace(/</g,"&#60;")};k.getMatchOffsets=function(c,a){var d=[];c.replace(a,function(a){d.push({offset:arguments[arguments.length-2],length:a.length})});return d};k.deferredCall=function(c){var a=null,d=function(){a=null;c()},g=function(c){g.cancel();a=setTimeout(d,c||0);return g};
g.schedule=g;g.call=function(){this.cancel();c();return g};g.cancel=function(){clearTimeout(a);a=null;return g};g.isPending=function(){return a};return g};k.delayedCall=function(c,a){var d=null,g=function(){d=null;c()},n=function(c){null==d&&(d=setTimeout(g,c||a))};n.delay=function(c){d&&clearTimeout(d);d=setTimeout(g,c||a)};n.schedule=n;n.call=function(){this.cancel();c()};n.cancel=function(){d&&clearTimeout(d);d=null};n.isPending=function(){return d};return n}});
define("ace/keyboard/textinput","require exports module ace/lib/event ace/lib/useragent ace/lib/dom ace/lib/lang".split(" "),function(f,k,r){var e=f("../lib/event"),m=f("../lib/useragent"),b=f("../lib/dom"),c=f("../lib/lang"),a=18>m.isChrome,d=m.isIE;k.TextInput=function(g,n){function h(a){if(!q){q=!0;if(w)d=0,a=a?0:p.value.length-1;else{var d=a?2:1;a=2}try{p.setSelectionRange(d,a)}catch(g){}q=!1}}function t(){q||(p.value="\u0001\u0001",m.isWebKit&&C.schedule())}function l(){clearTimeout(R);R=setTimeout(function(){v&&
(p.style.cssText=v,v="");null==n.renderer.$keepTextAreaAtCursor&&(n.renderer.$keepTextAreaAtCursor=!0,n.renderer.$moveTextAreaToCursor())},m.isOldIE?200:0)}var p=b.createElement("textarea");p.className="ace_text-input";m.isTouchPad&&p.setAttribute("x-palm-disable-auto-cap",!0);p.setAttribute("wrap","off");p.setAttribute("autocorrect","off");p.setAttribute("autocapitalize","off");p.setAttribute("spellcheck",!1);p.style.opacity="0";m.isOldIE&&(p.style.top="-1000px");g.insertBefore(p,g.firstChild);var f=
!1,s=!1,q=!1,v="",u=!0;try{var x=document.activeElement===p}catch(B){}e.addListener(p,"blur",function(a){n.onBlur(a);x=!1});e.addListener(p,"focus",function(a){x=!0;n.onFocus(a);h()});this.focus=function(){if(v)return p.focus();p.style.position="fixed";p.style.top="-1000px";p.focus();setTimeout(function(){p.style.position=""},0)};this.blur=function(){p.blur()};this.isFocused=function(){return x};var k=c.delayedCall(function(){x&&h(u)}),C=c.delayedCall(function(){q||(p.value="\u0001\u0001",x&&h())});
m.isWebKit||n.addEventListener("changeSelection",function(){n.selection.isEmpty()!=u&&(u=!u,k.schedule())});t();if(x)n.onFocus();var y=function(a){return 0===a.selectionStart&&a.selectionEnd===a.value.length};!p.setSelectionRange&&p.createTextRange&&(p.setSelectionRange=function(a,d){var g=this.createTextRange();g.collapse(!0);g.moveStart("character",a);g.moveEnd("character",d);g.select()},y=function(a){try{var d=a.ownerDocument.selection.createRange()}catch(g){}return d&&d.parentElement()==a?d.text==
a.value:!1});if(m.isOldIE){var A=!1,r=function(a){if(!A){var d=p.value;if(!q&&d&&"\u0001\u0001"!=d){if(a&&d=="\u0001\u0001"[0])return z.schedule();H(d);A=!0;t();A=!1}}},z=c.delayedCall(r);e.addListener(p,"propertychange",r);var F={13:1,27:1};e.addListener(p,"keyup",function(a){!q||p.value&&!F[a.keyCode]||setTimeout(J,0);if(129>(p.value.charCodeAt(0)||0))return z.call();q?K():S()});e.addListener(p,"keydown",function(a){z.schedule(50)})}var w=null;this.setInputHandler=function(a){w=a};this.getInputHandler=
function(){return w};var E=!1,H=function(a){w&&(a=w(a),w=null);if(s){h();if(a)n.onPaste(a);s=!1}else if("\u0001"==a)E?n.execCommand("del",{source:"ace"}):n.execCommand("backspace",{source:"ace"});else if("\u0001\u0001"==a.substring(0,2)?a=a.substr(2):"\u0001"==a.charAt(0)?a=a.substr(1):"\u0001"==a.charAt(a.length-1)&&(a=a.slice(0,-1)),"\u0001"==a.charAt(a.length-1)&&(a=a.slice(0,-1)),a)n.onTextInput(a);E&&(E=!1)},M=function(g,b){var c=g.clipboardData||window.clipboardData;if(c&&!a){var s=d?"Text":
"text/plain";return b?!1!==c.setData(s,b):c.getData(s)}},N=function(a,d){var g=n.getCopyText();if(!g)return e.preventDefault(a);M(a,g)?(d?n.onCut():n.onCopy(),e.preventDefault(a)):(f=!0,p.value=g,p.select(),setTimeout(function(){f=!1;t();h();d?n.onCut():n.onCopy()}))},O=function(a){N(a,!0)},P=function(a){N(a,!1)},Q=function(a){var d=M(a);if("string"==typeof d){if(d)n.onPaste(d,a);m.isIE&&setTimeout(h);e.preventDefault(a)}else p.value="",s=!0};e.addCommandKeyListener(p,n.onCommandKey.bind(n));e.addListener(p,
"select",function(a){f?f=!1:y(p)?(n.selectAll(),h()):w&&h(n.selection.isEmpty())});e.addListener(p,"input",function(a){q||(H(p.value),t())});e.addListener(p,"cut",O);e.addListener(p,"copy",P);e.addListener(p,"paste",Q);"oncut"in p&&"oncopy"in p&&"onpaste"in p||e.addListener(g,"keydown",function(a){if((!m.isMac||a.metaKey)&&a.ctrlKey)switch(a.keyCode){case 67:P(a);break;case 86:Q(a);break;case 88:O(a)}});var S=function(a){q||!n.onCompositionStart||n.$readOnly||(q={},n.onCompositionStart(),setTimeout(K,
0),n.on("mousedown",J),n.selection.isEmpty()||(n.insert(""),n.session.markUndoGroup(),n.selection.clearSelection()),n.session.markUndoGroup())},K=function(){if(q&&n.onCompositionUpdate&&!n.$readOnly){var a=p.value.replace(/\x01/g,"");q.lastValue!==a&&(n.onCompositionUpdate(a),q.lastValue&&n.undo(),q.lastValue=a,q.lastValue&&(a=n.selection.getRange(),n.insert(q.lastValue),n.session.markUndoGroup(),q.range=n.selection.getRange(),n.selection.setRange(a),n.selection.clearSelection()))}},J=function(a){if(n.onCompositionEnd&&
!n.$readOnly){var d=q;q=!1;var g=setTimeout(function(){g=null;var a=p.value.replace(/\x01/g,"");q||(a==d.lastValue?t():!d.lastValue&&a&&(t(),H(a)))});w=function(a){g&&clearTimeout(g);a=a.replace(/\x01/g,"");if(a==d.lastValue)return"";d.lastValue&&g&&n.undo();return a};n.onCompositionEnd();n.removeListener("mousedown",J);"compositionend"==a.type&&d.range&&n.selection.setRange(d.range)}},L=c.delayedCall(K,50);e.addListener(p,"compositionstart",S);m.isGecko?e.addListener(p,"text",function(){L.schedule()}):
(e.addListener(p,"keyup",function(){L.schedule()}),e.addListener(p,"keydown",function(){L.schedule()}));e.addListener(p,"compositionend",J);this.getElement=function(){return p};this.setReadOnly=function(a){p.readOnly=a};this.onContextMenu=function(a){E=!0;h(n.selection.isEmpty());n._emit("nativecontextmenu",{target:n,domEvent:a});this.moveToMouse(a,!0)};this.moveToMouse=function(a,d){if(d||!m.isOldIE){v||(v=p.style.cssText);p.style.cssText=(d?"z-index:100000;":"")+"height:"+p.style.height+";"+(m.isIE?
"opacity:0.1;":"");var g=n.container.getBoundingClientRect(),c=b.computedStyle(n.container),s=g.top+(parseInt(c.borderTopWidth)||0),h=g.left+(parseInt(g.borderLeftWidth)||0),u=g.bottom-s-p.clientHeight-2,g=function(a){p.style.left=a.clientX-h-2+"px";p.style.top=Math.min(a.clientY-s-2,u)+"px"};g(a);"mousedown"==a.type&&(n.renderer.$keepTextAreaAtCursor&&(n.renderer.$keepTextAreaAtCursor=null),m.isWin&&!m.isOldIE&&e.capture(n.container,g,l))}};this.onContextMenuClose=l;var R,r=function(a){n.textInput.onContextMenu(a);
l()};e.addListener(n.renderer.scroller,"contextmenu",r);e.addListener(p,"contextmenu",r)}});
define("ace/mouse/default_handlers","require exports module ace/lib/dom ace/lib/event ace/lib/useragent".split(" "),function(f,k,r){function e(b){b.$clickSelection=null;var c=b.editor;c.setDefaultHandler("mousedown",this.onMouseDown.bind(b));c.setDefaultHandler("dblclick",this.onDoubleClick.bind(b));c.setDefaultHandler("tripleclick",this.onTripleClick.bind(b));c.setDefaultHandler("quadclick",this.onQuadClick.bind(b));c.setDefaultHandler("mousewheel",this.onMouseWheel.bind(b));"select startSelect selectEnd selectAllEnd selectByWordsEnd selectByLinesEnd dragWait dragWaitEnd focusWait".split(" ").forEach(function(a){b[a]=
this[a]},this);b.selectByLines=this.extendSelectionBy.bind(b,"getLineRange");b.selectByWords=this.extendSelectionBy.bind(b,"getWordRange")}function m(b,c){return 0>(b.start.row==b.end.row?2*c.column-b.start.column-b.end.column:b.start.row!=b.end.row-1||b.start.column||b.end.column?2*c.row-b.start.row-b.end.row:c.column-4)?{cursor:b.start,anchor:b.end}:{cursor:b.end,anchor:b.start}}f("../lib/dom");f("../lib/event");f("../lib/useragent");(function(){this.onMouseDown=function(b){var c=b.inSelection(),
a=b.getDocumentPosition();this.mousedownEvent=b;var d=this.editor;if(0!==b.getButton())c=d.getSelectionRange().isEmpty(),d.$blockScrolling++,c&&d.selection.moveToPosition(a),d.$blockScrolling--,d.textInput.onContextMenu(b.domEvent);else{this.mousedownEvent.time=Date.now();if(c&&!d.isFocused()&&(d.focus(),this.$focusTimout&&!this.$clickSelection&&!d.inMultiSelectMode)){this.setState("focusWait");this.captureMouse(b);return}this.captureMouse(b);this.startSelect(a,1<b.domEvent._clicks);return b.preventDefault()}};
this.startSelect=function(b,c){b=b||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var a=this.editor;a.$blockScrolling++;this.mousedownEvent.getShiftKey()?a.selection.selectToPosition(b):c||a.selection.moveToPosition(b);c||this.select();a.renderer.scroller.setCapture&&a.renderer.scroller.setCapture();a.setStyle("ace_selecting");this.setState("select");a.$blockScrolling--};this.select=function(){var b,c=this.editor,a=c.renderer.screenToTextCoordinates(this.x,this.y);c.$blockScrolling++;
this.$clickSelection&&(b=this.$clickSelection.comparePoint(a),-1==b?b=this.$clickSelection.end:1==b?b=this.$clickSelection.start:(b=m(this.$clickSelection,a),a=b.cursor,b=b.anchor),c.selection.setSelectionAnchor(b.row,b.column));c.selection.selectToPosition(a);c.$blockScrolling--;c.renderer.scrollCursorIntoView()};this.extendSelectionBy=function(b){var c,a=this.editor,d=a.renderer.screenToTextCoordinates(this.x,this.y);b=a.selection[b](d.row,d.column);a.$blockScrolling++;if(this.$clickSelection){c=
this.$clickSelection.comparePoint(b.start);var g=this.$clickSelection.comparePoint(b.end);if(-1==c&&0>=g){if(c=this.$clickSelection.end,b.end.row!=d.row||b.end.column!=d.column)d=b.start}else if(1==g&&0<=c){if(c=this.$clickSelection.start,b.start.row!=d.row||b.start.column!=d.column)d=b.end}else-1==c&&1==g?(d=b.end,c=b.start):(b=m(this.$clickSelection,d),d=b.cursor,c=b.anchor);a.selection.setSelectionAnchor(c.row,c.column)}a.selection.selectToPosition(d);a.$blockScrolling--;a.renderer.scrollCursorIntoView()};
this.selectEnd=this.selectAllEnd=this.selectByWordsEnd=this.selectByLinesEnd=function(){this.$clickSelection=null;this.editor.unsetStyle("ace_selecting");this.editor.renderer.scroller.releaseCapture&&this.editor.renderer.scroller.releaseCapture()};this.focusWait=function(){var b;b=this.mousedownEvent.y;var c=this.y;b=Math.sqrt(Math.pow(this.x-this.mousedownEvent.x,2)+Math.pow(c-b,2));c=Date.now();(0<b||c-this.mousedownEvent.time>this.$focusTimout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())};
this.onDoubleClick=function(b){b=b.getDocumentPosition();var c=this.editor,a=c.session.getBracketRange(b);a?(a.isEmpty()&&(a.start.column--,a.end.column++),this.setState("select")):(a=c.selection.getWordRange(b.row,b.column),this.setState("selectByWords"));this.$clickSelection=a;this.select()};this.onTripleClick=function(b){b=b.getDocumentPosition();var c=this.editor;this.setState("selectByLines");var a=c.getSelectionRange();a.isMultiLine()&&a.contains(b.row,b.column)?(this.$clickSelection=c.selection.getLineRange(a.start.row),
this.$clickSelection.end=c.selection.getLineRange(a.end.row).end):this.$clickSelection=c.selection.getLineRange(b.row);this.select()};this.onQuadClick=function(b){b=this.editor;b.selectAll();this.$clickSelection=b.getSelectionRange();this.setState("selectAll")};this.onMouseWheel=function(b){if(!b.getAccelKey()){b.getShiftKey()&&b.wheelY&&!b.wheelX&&(b.wheelX=b.wheelY,b.wheelY=0);var c=b.domEvent.timeStamp,a=c-(this.$lastScrollTime||0),d=this.editor;if(d.renderer.isScrollableBy(b.wheelX*b.speed,b.wheelY*
b.speed)||200>a)return this.$lastScrollTime=c,d.renderer.scrollBy(b.wheelX*b.speed,b.wheelY*b.speed),b.stop()}}}).call(e.prototype);k.DefaultHandlers=e});
define("ace/tooltip",["require","exports","module","ace/lib/oop","ace/lib/dom"],function(f,k,r){function e(b){this.isOpen=!1;this.$element=null;this.$parentNode=b}f("./lib/oop");var m=f("./lib/dom");(function(){this.$init=function(){this.$element=m.createElement("div");this.$element.className="ace_tooltip";this.$element.style.display="none";this.$parentNode.appendChild(this.$element);return this.$element};this.getElement=function(){return this.$element||this.$init()};this.setText=function(b){m.setInnerText(this.getElement(),
b)};this.setHtml=function(b){this.getElement().innerHTML=b};this.setPosition=function(b,c){this.getElement().style.left=b+"px";this.getElement().style.top=c+"px"};this.setClassName=function(b){m.addCssClass(this.getElement(),b)};this.show=function(b,c,a){null!=b&&this.setText(b);null!=c&&null!=a&&this.setPosition(c,a);this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)};this.hide=function(){this.isOpen&&(this.getElement().style.display="none",this.isOpen=!1)};this.getHeight=function(){return this.getElement().offsetHeight};
this.getWidth=function(){return this.getElement().offsetWidth}}).call(e.prototype);k.Tooltip=e});
define("ace/mouse/default_gutter_handler","require exports module ace/lib/dom ace/lib/oop ace/lib/event ace/tooltip".split(" "),function(f,k,r){function e(a){c.call(this,a)}var m=f("../lib/dom");r=f("../lib/oop");var b=f("../lib/event"),c=f("../tooltip").Tooltip;r.inherits(e,c);(function(){this.setPosition=function(a,d){var g=window.innerWidth||document.documentElement.clientWidth,b=window.innerHeight||document.documentElement.clientHeight,h=this.getWidth(),t=this.getHeight();a+=15;d+=15;a+h>g&&(a-=
a+h-g);d+t>b&&(d-=20+t);c.prototype.setPosition.call(this,a,d)}}).call(e.prototype);k.GutterHandler=function(a){function d(){t&&(t=clearTimeout(t));p&&(h.hide(),p=null,g.removeEventListener("mousewheel",d))}var g=a.editor,c=g.renderer.$gutterLayer,h=new e(g.container);a.editor.setDefaultHandler("guttermousedown",function(d){if(g.isFocused()&&0==d.getButton()&&"foldWidgets"!=c.getRegion(d)){var b=d.getDocumentPosition().row,h=g.session.selection;if(d.getShiftKey())h.selectTo(b,0);else{if(2==d.domEvent.detail)return g.selectAll(),
d.preventDefault();a.$clickSelection=g.selection.getLineRange(b)}a.setState("selectByLines");a.captureMouse(d);return d.preventDefault()}});var t,l,p;a.editor.setDefaultHandler("guttermousemove",function(b){if(m.hasCssClass(b.domEvent.target||b.domEvent.srcElement,"ace_fold-widget"))return d();p&&a.$tooltipFollowsMouse&&h.setPosition(b.x,b.y);l=b;t||(t=setTimeout(function(){t=null;if(l&&!a.isMousePressed)a:{var b=l.getDocumentPosition().row,q=c.$annotations[b];if(q){var e=g.session.getLength();if(b==
e){var e=g.renderer.pixelToScreenCoordinates(0,l.y).row,u=l.$pos;if(e>g.session.documentToScreenRow(u.row,u.column)){d();break a}}p!=q&&(p=q.text.join("<br/>"),h.setHtml(p),h.show(),g.on("mousewheel",d),a.$tooltipFollowsMouse?h.setPosition(l.x,l.y):(b=c.$cells[g.session.documentToScreenRow(b,0)].element.getBoundingClientRect(),q=h.getElement().style,q.left=b.right+"px",q.top=b.bottom+"px"))}else d()}else d()},50))});b.addListener(g.renderer.$gutter,"mouseout",function(a){l=null;p&&!t&&(t=setTimeout(function(){t=
null;d()},50))});g.on("changeSession",d)}});
define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(f,k,r){var e=f("../lib/event"),m=f("../lib/useragent");f=k.MouseEvent=function(b,c){this.domEvent=b;this.editor=c;this.x=this.clientX=b.clientX;this.y=this.clientY=b.clientY;this.$inSelection=this.$pos=null;this.defaultPrevented=this.propagationStopped=!1};(function(){this.stopPropagation=function(){e.stopPropagation(this.domEvent);this.propagationStopped=!0};this.preventDefault=function(){e.preventDefault(this.domEvent);
this.defaultPrevented=!0};this.stop=function(){this.stopPropagation();this.preventDefault()};this.getDocumentPosition=function(){return this.$pos?this.$pos:this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY)};this.inSelection=function(){if(null!==this.$inSelection)return this.$inSelection;var b=this.editor.getSelectionRange();if(b.isEmpty())this.$inSelection=!1;else{var c=this.getDocumentPosition();this.$inSelection=b.contains(c.row,c.column)}return this.$inSelection};
this.getButton=function(){return e.getButton(this.domEvent)};this.getShiftKey=function(){return this.domEvent.shiftKey};this.getAccelKey=m.isMac?function(){return this.domEvent.metaKey}:function(){return this.domEvent.ctrlKey}}).call(f.prototype)});
define("ace/mouse/dragdrop_handler","require exports module ace/lib/dom ace/lib/event ace/lib/useragent".split(" "),function(f,k,r){function e(d){var g,n;function h(){var a=A,d=A=q.renderer.screenToTextCoordinates(f,k),b=Date.now(),c=!a||d.row!=a.row,s=!a||d.column!=a.column;!E||c||s?(q.$blockScrolling+=1,q.moveCursorToPosition(d),q.$blockScrolling-=1,E=b,g=f,n=k):5<m(g,n,f,k)?E=null:200<=b-E&&(q.renderer.scrollCursorIntoView(),E=null);var d=A,b=Date.now(),s=q.renderer.layerConfig.lineHeight,h=q.renderer.layerConfig.characterWidth,
c=q.renderer.scroller.getBoundingClientRect(),u=f-c.left,l=c.right-f,t=k-c.top,x=c.bottom-k,p=Math.min(u,l),e=Math.min(t,x),c={row:d.row,column:d.column};2>=p/h&&(c.column+=u<l?-3:2);1>=e/s&&(c.row+=t<x?-1:1);s=d.column!=c.column;a=!a||d.row!=a.row;d.row!=c.row||s&&!a?w?200<=b-w&&q.renderer.scrollCursorIntoView(c):w=b:w=null}function t(){y=q.selection.toOrientedRange();x=q.session.addMarker(y,"ace_selection",q.getSelectionStyle());q.clearSelection();q.isFocused()&&q.renderer.$cursorLayer.setBlinking(!1);
clearInterval(C);h();C=setInterval(h,20);r=0;c.addListener(document,"mousemove",p)}function l(){clearInterval(C);q.session.removeMarker(x);x=null;q.$blockScrolling+=1;q.selection.fromOrientedRange(y);q.$blockScrolling-=1;q.isFocused()&&!F&&q.renderer.$cursorLayer.setBlinking(!q.getReadOnly());A=y=null;r=0;E=w=null;c.removeListener(document,"mousemove",p)}function p(){null==H&&(H=setTimeout(function(){null!=H&&x&&l()},20))}function e(a){a=a.types;return!a||Array.prototype.some.call(a,function(a){return"text/plain"==
a||"Text"==a})}function s(d){var g=["copy","copymove","all","uninitialized"],b=["move","copymove","linkmove","all","uninitialized"],c=a.isMac?d.altKey:d.ctrlKey,s="uninitialized";try{s=d.dataTransfer.effectAllowed.toLowerCase()}catch(n){}d="none";c&&0<=g.indexOf(s)?d="copy":0<=b.indexOf(s)?d="move":0<=g.indexOf(s)&&(d="copy");return d}var q=d.editor,v=b.createElement("img");v.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==";a.isOpera&&(v.style.cssText="width:1px;height:1px;position:fixed;top:0;left:0;z-index:2147483647;opacity:0;");
["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"].forEach(function(a){d[a]=this[a]},this);q.addEventListener("mousedown",this.onMouseDown.bind(d));var u=q.container,x,f,k,C,y,A,r=0,z,F,w,E;this.onDragStart=function(d){if(this.cancelDrag||!u.draggable){var g=this;setTimeout(function(){g.startSelect();g.captureMouse(d)},0);return d.preventDefault()}y=q.getSelectionRange();var b=d.dataTransfer;b.effectAllowed=q.getReadOnly()?"copy":"copyMove";a.isOpera&&(q.container.appendChild(v),
v.scrollTop=0);b.setDragImage&&b.setDragImage(v,0,0);a.isOpera&&q.container.removeChild(v);b.clearData();b.setData("Text",q.session.getTextRange());F=!0;this.setState("drag")};this.onDragEnd=function(a){F=u.draggable=!1;this.setState(null);q.getReadOnly()||(a=a.dataTransfer.dropEffect,z||"move"!=a||q.session.remove(q.getSelectionRange()),q.renderer.$cursorLayer.setBlinking(!0));this.editor.unsetStyle("ace_dragging");this.editor.renderer.setCursorStyle("")};this.onDragEnter=function(a){if(!q.getReadOnly()&&
e(a.dataTransfer))return f=a.clientX,k=a.clientY,x||t(),r++,a.dataTransfer.dropEffect=z=s(a),c.preventDefault(a)};this.onDragOver=function(a){if(!q.getReadOnly()&&e(a.dataTransfer))return f=a.clientX,k=a.clientY,x||(t(),r++),null!==H&&(H=null),a.dataTransfer.dropEffect=z=s(a),c.preventDefault(a)};this.onDragLeave=function(a){r--;if(0>=r&&x)return l(),z=null,c.preventDefault(a)};this.onDrop=function(a){if(A){var d=a.dataTransfer;if(F)switch(z){case "move":y=y.contains(A.row,A.column)?{start:A,end:A}:
q.moveText(y,A);break;case "copy":y=q.moveText(y,A,!0)}else d=d.getData("Text"),y={start:A,end:q.session.insert(A,d)},q.focus(),z=null;l();return c.preventDefault(a)}};c.addListener(u,"dragstart",this.onDragStart.bind(d));c.addListener(u,"dragend",this.onDragEnd.bind(d));c.addListener(u,"dragenter",this.onDragEnter.bind(d));c.addListener(u,"dragover",this.onDragOver.bind(d));c.addListener(u,"dragleave",this.onDragLeave.bind(d));c.addListener(u,"drop",this.onDrop.bind(d));var H=null}function m(a,g,
b,c){return Math.sqrt(Math.pow(b-a,2)+Math.pow(c-g,2))}var b=f("../lib/dom"),c=f("../lib/event"),a=f("../lib/useragent");(function(){this.dragWait=function(){Date.now()-this.mousedownEvent.time>this.editor.getDragDelay()&&this.startDrag()};this.dragWaitEnd=function(){this.editor.container.draggable=!1;this.startSelect(this.mousedownEvent.getDocumentPosition());this.selectEnd()};this.dragReadyEnd=function(a){this.editor.renderer.$cursorLayer.setBlinking(!this.editor.getReadOnly());this.editor.unsetStyle("ace_dragging");
this.editor.renderer.setCursorStyle("");this.dragWaitEnd()};this.startDrag=function(){this.cancelDrag=!1;var d=this.editor;d.container.draggable=!0;d.renderer.$cursorLayer.setBlinking(!1);d.setStyle("ace_dragging");d.renderer.setCursorStyle(a.isWin?"default":"move");this.setState("dragReady")};this.onMouseDrag=function(d){d=this.editor.container;if(a.isIE&&"dragReady"==this.state){var g=m(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);3<g&&d.dragDrop()}"dragWait"===this.state&&(g=m(this.mousedownEvent.x,
this.mousedownEvent.y,this.x,this.y),0<g&&(d.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition())))};this.onMouseDown=function(d){if(this.$dragEnabled){this.mousedownEvent=d;var g=this.editor,b=d.inSelection(),c=d.getButton();1!==(d.domEvent.detail||1)||0!==c||!b||d.editor.inMultiSelectMode&&(d.getAccelKey()||d.getShiftKey())||(this.mousedownEvent.time=Date.now(),b=d.domEvent.target||d.domEvent.srcElement,"unselectable"in b&&(b.unselectable="on"),g.getDragDelay()?(a.isWebKit&&
(this.cancelDrag=!0,g.container.draggable=!0),this.setState("dragWait")):this.startDrag(),this.captureMouse(d,this.onMouseDrag.bind(this)),d.defaultPrevented=!0)}}}).call(e.prototype);k.DragdropHandler=e});
define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(f,k,r){var e=f("./dom");k.get=function(e,b){var c=new XMLHttpRequest;c.open("GET",e,!0);c.onreadystatechange=function(){4===c.readyState&&b(c.responseText)};c.send(null)};k.loadScript=function(m,b){var c=e.getDocumentHead(),a=document.createElement("script");a.src=m;c.appendChild(a);a.onload=a.onreadystatechange=function(d,g){if(g||!a.readyState||"loaded"==a.readyState||"complete"==a.readyState)a=a.onload=a.onreadystatechange=
null,g||b()}};k.qualifyURL=function(e){var b=document.createElement("a");b.href=e;return b.href}});
define("ace/lib/event_emitter",["require","exports","module"],function(f,k,r){f={};var e=function(){this.propagationStopped=!0},m=function(){this.defaultPrevented=!0};f._emit=f._dispatchEvent=function(b,c){this._eventRegistry||(this._eventRegistry={});this._defaultHandlers||(this._defaultHandlers={});var a=this._eventRegistry[b]||[],d=this._defaultHandlers[b];if(a.length||d){"object"==typeof c&&c||(c={});c.type||(c.type=b);c.stopPropagation||(c.stopPropagation=e);c.preventDefault||(c.preventDefault=
m);for(var a=a.slice(),g=0;g<a.length&&(a[g](c,this),!c.propagationStopped);g++);if(d&&!c.defaultPrevented)return d(c,this)}};f._signal=function(b,c){var a=(this._eventRegistry||{})[b];if(a)for(var a=a.slice(),d=0;d<a.length;d++)a[d](c,this)};f.once=function(b,c){var a=this;c&&this.addEventListener(b,function g(){a.removeEventListener(b,g);c.apply(null,arguments)})};f.setDefaultHandler=function(b,c){var a=this._defaultHandlers;a||(a=this._defaultHandlers={_disabled_:{}});if(a[b]){var d=a[b],g=a._disabled_[b];
g||(a._disabled_[b]=g=[]);g.push(d);d=g.indexOf(c);-1!=d&&g.splice(d,1)}a[b]=c};f.removeDefaultHandler=function(b,c){var a=this._defaultHandlers;if(a){var d=a._disabled_[b];a[b]==c?d&&this.setDefaultHandler(b,d.pop()):d&&(a=d.indexOf(c),-1!=a&&d.splice(a,1))}};f.on=f.addEventListener=function(b,c,a){this._eventRegistry=this._eventRegistry||{};var d=this._eventRegistry[b];d||(d=this._eventRegistry[b]=[]);if(-1==d.indexOf(c))d[a?"unshift":"push"](c);return c};f.off=f.removeListener=f.removeEventListener=
function(b,c){this._eventRegistry=this._eventRegistry||{};var a=this._eventRegistry[b];if(a){var d=a.indexOf(c);-1!==d&&a.splice(d,1)}};f.removeAllListeners=function(b){this._eventRegistry&&(this._eventRegistry[b]=[])};k.EventEmitter=f});
define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(f,k,r){function e(a){"undefined"!=typeof console&&console.warn&&console.warn.apply(console,arguments)}function m(a,g){var b=Error(a);b.data=g;"object"==typeof console&&console.error&&console.error(b);setTimeout(function(){throw b;})}"no use strict";var b=f("./oop"),c=f("./event_emitter").EventEmitter,a={setOptions:function(a){Object.keys(a).forEach(function(g){this.setOption(g,a[g])},this)},getOptions:function(a){var g=
{};a?Array.isArray(a)||(g=a,a=Object.keys(g)):a=Object.keys(this.$options);a.forEach(function(a){g[a]=this.getOption(a)},this);return g},setOption:function(a,g){if(this["$"+a]!==g){var b=this.$options[a];if(!b)return e('misspelled option "'+a+'"');if(b.forwardTo)return this[b.forwardTo]&&this[b.forwardTo].setOption(a,g);b.handlesSet||(this["$"+a]=g);b&&b.set&&b.set.call(this,g)}},getOption:function(a){var g=this.$options[a];return g?g.forwardTo?this[g.forwardTo]&&this[g.forwardTo].getOption(a):g&&
g.get?g.get.call(this):this["$"+a]:e('misspelled option "'+a+'"')}};f=function(){this.$defaultOptions={}};(function(){b.implement(this,c);this.defineOptions=function(d,g,c){d.$options||(this.$defaultOptions[g]=d.$options={});Object.keys(c).forEach(function(a){var g=c[a];"string"==typeof g&&(g={forwardTo:g});g.name||(g.name=a);d.$options[g.name]=g;"initialValue"in g&&(d["$"+g.name]=g.initialValue)});b.implement(d,a);return this};this.resetOptions=function(a){Object.keys(a.$options).forEach(function(g){var b=
a.$options[g];"value"in b&&a.setOption(g,b.value)})};this.setDefaultValue=function(a,g,b){a=this.$defaultOptions[a]||(this.$defaultOptions[a]={});a[g]&&(a.forwardTo?this.setDefaultValue(a.forwardTo,g,b):a[g].value=b)};this.setDefaultValues=function(a,g){Object.keys(g).forEach(function(b){this.setDefaultValue(a,b,g[b])},this)};this.warn=e;this.reportError=m}).call(f.prototype);k.AppConfig=f});
define("ace/config","require exports module ace/lib/lang ace/lib/oop ace/lib/net ace/lib/app_config".split(" "),function(f,k,r){function e(a){g.packaged=a||f.packaged||r.packaged||d.define&&define.packaged;if(!d.document)return"";a={};for(var b="",c=document.currentScript||document._currentScript,c=(c&&c.ownerDocument||document).getElementsByTagName("script"),l=0;l<c.length;l++){var p=c[l],e=p.src||p.getAttribute("src");if(e){for(var p=p.attributes,s=0,q=p.length;s<q;s++){var v=p[s];0===v.name.indexOf("data-ace-")&&
(a[m(v.name.replace(/^data-ace-/,""))]=v.value)}(e=e.match(/^(.*)\/ace(\-\w+)?\.js(\?|$)/))&&(b=e[1])}}b&&(a.base=a.base||b,a.packaged=!0);a.basePath=a.base;a.workerPath=a.workerPath||a.base;a.modePath=a.modePath||a.base;a.themePath=a.themePath||a.base;delete a.base;for(var u in a)"undefined"!==typeof a[u]&&k.set(u,a[u])}function m(a){return a.replace(/-(.)/g,function(a,d){return d.toUpperCase()})}"no use strict";var b=f("./lib/lang");f("./lib/oop");var c=f("./lib/net"),a=f("./lib/app_config").AppConfig;
r.exports=k=new a;var d=function(){return this||"undefined"!=typeof window&&window}(),g={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{}};k.get=function(a){if(!g.hasOwnProperty(a))throw Error("Unknown config key: "+a);return g[a]};k.set=function(a,d){if(!g.hasOwnProperty(a))throw Error("Unknown config key: "+a);g[a]=d};k.all=function(){return b.copyObject(g)};k.moduleUrl=function(a,d){if(g.$moduleUrls[a])return g.$moduleUrls[a];var b=a.split("/");d=
d||b[b.length-2]||"";var c="snippets"==d?"/":"-",e=b[b.length-1];"worker"==d&&"-"==c&&(e=e.replace(new RegExp("^"+d+"[\\-_]|[\\-_]"+d+"$","g"),""));(!e||e==d)&&1<b.length&&(e=b[b.length-2]);b=g[d+"Path"];null==b?b=g.basePath:"/"==c&&(d=c="");b&&"/"!=b.slice(-1)&&(b+="/");return b+d+c+e+this.get("suffix")};k.setModuleUrl=function(a,d){return g.$moduleUrls[a]=d};k.$loading={};k.loadModule=function(a,d){var g,b;Array.isArray(a)&&(b=a[0],a=a[1]);try{g=f(a)}catch(e){}if(g&&!k.$loading[a])return d&&d(g);
k.$loading[a]||(k.$loading[a]=[]);k.$loading[a].push(d);if(!(1<k.$loading[a].length)){g=function(){f([a],function(d){k._emit("load.module",{name:a,module:d});var g=k.$loading[a];k.$loading[a]=null;g.forEach(function(a){a&&a(d)})})};if(!k.get("packaged"))return g();c.loadScript(k.moduleUrl(a,b),g)}};e(!0);k.init=e});
define("ace/mouse/mouse_handler","require exports module ace/lib/event ace/lib/useragent ace/mouse/default_handlers ace/mouse/default_gutter_handler ace/mouse/mouse_event ace/mouse/dragdrop_handler ace/config".split(" "),function(f,k,r){var e=f("../lib/event"),m=f("../lib/useragent"),b=f("./default_handlers").DefaultHandlers,c=f("./default_gutter_handler").GutterHandler,a=f("./mouse_event").MouseEvent,d=f("./dragdrop_handler").DragdropHandler;f=f("../config");r=function(a){var n=this;this.editor=
a;new b(this);new c(this);new d(this);var h=function(d){document.hasFocus&&document.hasFocus()||window.focus();a.focus()},t=a.renderer.getMouseEventTarget();e.addListener(t,"click",this.onMouseEvent.bind(this,"click"));e.addListener(t,"mousemove",this.onMouseMove.bind(this,"mousemove"));e.addMultiMouseDownListener(t,[400,300,250],this,"onMouseEvent");a.renderer.scrollBarV&&(e.addMultiMouseDownListener(a.renderer.scrollBarV.inner,[400,300,250],this,"onMouseEvent"),e.addMultiMouseDownListener(a.renderer.scrollBarH.inner,
[400,300,250],this,"onMouseEvent"),m.isIE&&(e.addListener(a.renderer.scrollBarV.element,"mousedown",h),e.addListener(a.renderer.scrollBarH.element,"mousedown",h)));e.addMouseWheelListener(a.container,this.onMouseWheel.bind(this,"mousewheel"));var l=a.renderer.$gutter;e.addListener(l,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"));e.addListener(l,"click",this.onMouseEvent.bind(this,"gutterclick"));e.addListener(l,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"));e.addListener(l,
"mousemove",this.onMouseEvent.bind(this,"guttermousemove"));e.addListener(t,"mousedown",h);e.addListener(l,"mousedown",function(d){a.focus();return e.preventDefault(d)});a.on("mousemove",function(d){if(!n.state&&!n.$dragDelay&&n.$dragEnabled){d=a.renderer.screenToTextCoordinates(d.x,d.y);var b=a.session.selection.getRange(),c=a.renderer;!b.isEmpty()&&b.insideStart(d.row,d.column)?c.setCursorStyle("default"):c.setCursorStyle("")}})};(function(){this.onMouseEvent=function(d,b){this.editor._emit(d,new a(b,
this.editor))};this.onMouseMove=function(d,b){var c=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;c&&c.length&&this.editor._emit(d,new a(b,this.editor))};this.onMouseWheel=function(d,b){var c=new a(b,this.editor);c.speed=2*this.$scrollSpeed;c.wheelX=b.wheelX;c.wheelY=b.wheelY;this.editor._emit(d,c)};this.setState=function(a){this.state=a};this.captureMouse=function(d,b){this.x=d.x;this.y=d.y;this.isMousePressed=!0;var c=this.editor.renderer;c.$keepTextAreaAtCursor&&(c.$keepTextAreaAtCursor=
null);var t=this,l=function(d){if(d){if(m.isWebKit&&!d.which&&t.releaseMouse)return t.releaseMouse();t.x=d.clientX;t.y=d.clientY;b&&b(d);t.mouseEvent=new a(d,t.editor);t.$mouseMoved=!0}},p=function(a){clearInterval(s);f();t[t.state+"End"]&&t[t.state+"End"](a);t.state="";null==c.$keepTextAreaAtCursor&&(c.$keepTextAreaAtCursor=!0,c.$moveTextAreaToCursor());t.isMousePressed=!1;t.$onCaptureMouseMove=t.releaseMouse=null;a&&t.onMouseEvent("mouseup",a)},f=function(){t[t.state]&&t[t.state]();t.$mouseMoved=
!1};if(m.isOldIE&&"dblclick"==d.domEvent.type)return setTimeout(function(){p(d)});t.$onCaptureMouseMove=l;t.releaseMouse=e.capture(this.editor.container,l,p);var s=setInterval(f,20)};this.releaseMouse=null;this.cancelContextMenu=function(){var a=function(d){d&&d.domEvent&&"contextmenu"!=d.domEvent.type||(this.editor.off("nativecontextmenu",a),d&&d.domEvent&&e.stopEvent(d.domEvent))}.bind(this);setTimeout(a,10);this.editor.on("nativecontextmenu",a)}}).call(r.prototype);f.defineOptions(r.prototype,
"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:m.isMac?150:0},dragEnabled:{initialValue:!0},focusTimout:{initialValue:0},tooltipFollowsMouse:{initialValue:!0}});k.MouseHandler=r});
define("ace/mouse/fold_handler",["require","exports","module"],function(f,k,r){k.FoldHandler=function(e){e.on("click",function(m){var b=m.getDocumentPosition(),c=e.session;if(b=c.getFoldAt(b.row,b.column,1))m.getAccelKey()?c.removeFold(b):c.expandFold(b),m.stop()});e.on("gutterclick",function(m){if("foldWidgets"==e.renderer.$gutterLayer.getRegion(m)){var b=m.getDocumentPosition().row,c=e.session;if(c.foldWidgets&&c.foldWidgets[b])e.session.onFoldWidgetClick(b,m);e.isFocused()||e.focus();m.stop()}});
e.on("gutterdblclick",function(m){if("foldWidgets"==e.renderer.$gutterLayer.getRegion(m)){var b=m.getDocumentPosition().row,c=e.session,a=c.getParentFoldRangeData(b,!0);if(a=a.range||a.firstRange)b=a.start.row,(b=c.getFoldAt(b,c.getLine(b).length,1))?c.removeFold(b):(c.addFold("...",a),e.renderer.scrollCursorIntoView({row:a.start.row,column:0}));m.stop()}})}});
define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(f,k,r){var e=f("../lib/keys"),m=f("../lib/event");f=function(b){this.$editor=b;this.$data={editor:b};this.$handlers=[];this.setDefaultHandler(b.commands)};(function(){this.setDefaultHandler=function(b){this.removeKeyboardHandler(this.$defaultHandler);this.$defaultHandler=b;this.addKeyboardHandler(b,0)};this.setKeyboardHandler=function(b){var c=this.$handlers;if(c[c.length-1]!=b){for(;c[c.length-
1]&&c[c.length-1]!=this.$defaultHandler;)this.removeKeyboardHandler(c[c.length-1]);this.addKeyboardHandler(b,1)}};this.addKeyboardHandler=function(b,c){if(b){"function"!=typeof b||b.handleKeyboard||(b.handleKeyboard=b);var a=this.$handlers.indexOf(b);-1!=a&&this.$handlers.splice(a,1);void 0==c?this.$handlers.push(b):this.$handlers.splice(c,0,b);-1==a&&b.attach&&b.attach(this.$editor)}};this.removeKeyboardHandler=function(b){var c=this.$handlers.indexOf(b);if(-1==c)return!1;this.$handlers.splice(c,
1);b.detach&&b.detach(this.$editor);return!0};this.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]};this.getStatusText=function(){var b=this.$data,c=b.editor;return this.$handlers.map(function(a){return a.getStatusText&&a.getStatusText(c,b)||""}).filter(Boolean).join(" ")};this.$callKeyboardHandlers=function(b,c,a,d){for(var g,n=!1,h=this.$editor.commands,e=this.$handlers.length;e--&&!((g=this.$handlers[e].handleKeyboard(this.$data,b,c,a,d))&&g.command&&((n="null"==g.command?
!0:h.exec(g.command,this.$editor,g.args,d))&&d&&-1!=b&&!0!=g.passEvent&&!0!=g.command.passEvent&&m.stopEvent(d),n)););return n};this.onCommandKey=function(b,c,a){var d=e.keyCodeToString(a);this.$callKeyboardHandlers(c,d,a,b)};this.onTextInput=function(b){this.$callKeyboardHandlers(-1,b)||this.$editor.commands.exec("insertstring",this.$editor,b)}}).call(f.prototype);k.KeyBinding=f});
define("ace/range",["require","exports","module"],function(f,k,r){var e=function(e,b,c,a){this.start={row:e,column:b};this.end={row:c,column:a}};(function(){this.isEqual=function(e){return this.start.row===e.start.row&&this.end.row===e.end.row&&this.start.column===e.start.column&&this.end.column===e.end.column};this.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"};this.contains=function(e,b){return 0==this.compare(e,b)};this.compareRange=
function(e){var b;b=e.end;e=e.start;b=this.compare(b.row,b.column);if(1==b)return b=this.compare(e.row,e.column),1==b?2:0==b?1:0;if(-1==b)return-2;b=this.compare(e.row,e.column);return-1==b?-1:1==b?42:0};this.comparePoint=function(e){return this.compare(e.row,e.column)};this.containsRange=function(e){return 0==this.comparePoint(e.start)&&0==this.comparePoint(e.end)};this.intersects=function(e){e=this.compareRange(e);return-1==e||0==e||1==e};this.isEnd=function(e,b){return this.end.row==e&&this.end.column==
b};this.isStart=function(e,b){return this.start.row==e&&this.start.column==b};this.setStart=function(e,b){"object"==typeof e?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=b)};this.setEnd=function(e,b){"object"==typeof e?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=b)};this.inside=function(e,b){return 0!=this.compare(e,b)||this.isEnd(e,b)||this.isStart(e,b)?!1:!0};this.insideStart=function(e,b){return 0!=this.compare(e,b)||this.isEnd(e,
b)?!1:!0};this.insideEnd=function(e,b){return 0!=this.compare(e,b)||this.isStart(e,b)?!1:!0};this.compare=function(e,b){return this.isMultiLine()||e!==this.start.row?e<this.start.row?-1:e>this.end.row?1:this.start.row===e?b>=this.start.column?0:-1:this.end.row===e?b<=this.end.column?0:1:0:b<this.start.column?-1:b>this.end.column?1:0};this.compareStart=function(e,b){return this.start.row==e&&this.start.column==b?-1:this.compare(e,b)};this.compareEnd=function(e,b){return this.end.row==e&&this.end.column==
b?1:this.compare(e,b)};this.compareInside=function(e,b){return this.end.row==e&&this.end.column==b?1:this.start.row==e&&this.start.column==b?-1:this.compare(e,b)};this.clipRows=function(f,b){if(this.end.row>b)var c={row:b+1,column:0};else this.end.row<f&&(c={row:f,column:0});if(this.start.row>b)var a={row:b+1,column:0};else this.start.row<f&&(a={row:f,column:0});return e.fromPoints(a||this.start,c||this.end)};this.extend=function(f,b){var c=this.compare(f,b);if(0==c)return this;if(-1==c)var a={row:f,
column:b};else var d={row:f,column:b};return e.fromPoints(a||this.start,d||this.end)};this.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column};this.isMultiLine=function(){return this.start.row!==this.end.row};this.clone=function(){return e.fromPoints(this.start,this.end)};this.collapseRows=function(){return 0==this.end.column?new e(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new e(this.start.row,0,this.end.row,0)};this.toScreenRange=function(f){var b=
f.documentToScreenPosition(this.start);f=f.documentToScreenPosition(this.end);return new e(b.row,b.column,f.row,f.column)};this.moveBy=function(e,b){this.start.row+=e;this.start.column+=b;this.end.row+=e;this.end.column+=b}}).call(e.prototype);e.fromPoints=function(f,b){return new e(f.row,f.column,b.row,b.column)};e.comparePoints=function(e,b){return e.row-b.row||e.column-b.column};e.comparePoints=function(e,b){return e.row-b.row||e.column-b.column};k.Range=e});
define("ace/selection","require exports module ace/lib/oop ace/lib/lang ace/lib/event_emitter ace/range".split(" "),function(f,k,r){var e=f("./lib/oop"),m=f("./lib/lang"),b=f("./lib/event_emitter").EventEmitter,c=f("./range").Range;f=function(a){this.session=a;this.doc=a.getDocument();this.clearSelection();this.lead=this.selectionLead=this.doc.createAnchor(0,0);this.anchor=this.selectionAnchor=this.doc.createAnchor(0,0);var d=this;this.lead.on("change",function(a){d._emit("changeCursor");d.$isEmpty||
d._emit("changeSelection");d.$keepDesiredColumnOnChange||a.old.column==a.value.column||(d.$desiredColumn=null)});this.selectionAnchor.on("change",function(){d.$isEmpty||d._emit("changeSelection")})};(function(){e.implement(this,b);this.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column};this.isMultiLine=function(){return this.isEmpty()?!1:this.getRange().isMultiLine()};this.getCursor=function(){return this.lead.getPosition()};this.setSelectionAnchor=
function(a,d){this.anchor.setPosition(a,d);this.$isEmpty&&(this.$isEmpty=!1,this._emit("changeSelection"))};this.getSelectionAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()};this.getSelectionLead=function(){return this.lead.getPosition()};this.shiftSelection=function(a){if(this.$isEmpty)this.moveCursorTo(this.lead.row,this.lead.column+a);else{var d=this.getSelectionAnchor(),b=this.getSelectionLead(),c=this.isBackwards();c&&0===d.column||this.setSelectionAnchor(d.row,
d.column+a);(c||0!==b.column)&&this.$moveSelection(function(){this.moveCursorTo(b.row,b.column+a)})}};this.isBackwards=function(){var a=this.anchor,d=this.lead;return a.row>d.row||a.row==d.row&&a.column>d.column};this.getRange=function(){var a=this.anchor,d=this.lead;return this.isEmpty()?c.fromPoints(d,d):this.isBackwards()?c.fromPoints(d,a):c.fromPoints(a,d)};this.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))};this.selectAll=function(){var a=this.doc.getLength()-
1;this.setSelectionAnchor(0,0);this.moveCursorTo(a,this.doc.getLine(a).length)};this.setRange=this.setSelectionRange=function(a,d){d?(this.setSelectionAnchor(a.end.row,a.end.column),this.selectTo(a.start.row,a.start.column)):(this.setSelectionAnchor(a.start.row,a.start.column),this.selectTo(a.end.row,a.end.column));this.getRange().isEmpty()&&(this.$isEmpty=!0);this.$desiredColumn=null};this.$moveSelection=function(a){var d=this.lead;this.$isEmpty&&this.setSelectionAnchor(d.row,d.column);a.call(this)};
this.selectTo=function(a,d){this.$moveSelection(function(){this.moveCursorTo(a,d)})};this.selectToPosition=function(a){this.$moveSelection(function(){this.moveCursorToPosition(a)})};this.moveTo=function(a,d){this.clearSelection();this.moveCursorTo(a,d)};this.moveToPosition=function(a){this.clearSelection();this.moveCursorToPosition(a)};this.selectUp=function(){this.$moveSelection(this.moveCursorUp)};this.selectDown=function(){this.$moveSelection(this.moveCursorDown)};this.selectRight=function(){this.$moveSelection(this.moveCursorRight)};
this.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)};this.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)};this.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)};this.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)};this.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)};this.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)};this.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)};
this.getWordRange=function(a,d){if("undefined"==typeof d){var b=a||this.lead;a=b.row;d=b.column}return this.session.getWordRange(a,d)};this.selectWord=function(){this.setSelectionRange(this.getWordRange())};this.selectAWord=function(){var a=this.getCursor(),a=this.session.getAWordRange(a.row,a.column);this.setSelectionRange(a)};this.getLineRange=function(a,d){var b="number"==typeof a?a:this.lead.row,n;(n=this.session.getFoldLine(b))?(b=n.start.row,n=n.end.row):n=b;return!0===d?new c(b,0,n,this.session.getLine(n).length):
new c(b,0,n+1,0)};this.selectLine=function(){this.setSelectionRange(this.getLineRange())};this.moveCursorUp=function(){this.moveCursorBy(-1,0)};this.moveCursorDown=function(){this.moveCursorBy(1,0)};this.moveCursorLeft=function(){var a=this.lead.getPosition(),d;(d=this.session.getFoldAt(a.row,a.column,-1))?this.moveCursorTo(d.start.row,d.start.column):0===a.column?0<a.row&&this.moveCursorTo(a.row-1,this.doc.getLine(a.row-1).length):(d=this.session.getTabSize(),this.session.isTabStop(a)&&this.doc.getLine(a.row).slice(a.column-
d,a.column).split(" ").length-1==d?this.moveCursorBy(0,-d):this.moveCursorBy(0,-1))};this.moveCursorRight=function(){var a=this.lead.getPosition();if(a=this.session.getFoldAt(a.row,a.column,1))this.moveCursorTo(a.end.row,a.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row<this.doc.getLength()-1&&this.moveCursorTo(this.lead.row+1,0);else{var d=this.session.getTabSize(),a=this.lead;this.session.isTabStop(a)&&this.doc.getLine(a.row).slice(a.column,a.column+d).split(" ").length-
1==d?this.moveCursorBy(0,d):this.moveCursorBy(0,1)}};this.moveCursorLineStart=function(){var a=this.lead.row,d=this.lead.column,b=this.session.documentToScreenRow(a,d),b=this.session.screenToDocumentPosition(b,0),a=this.session.getDisplayLine(a,null,b.row,b.column).match(/^\s*/);a[0].length==d||this.session.$useEmacsStyleLineStart||(b.column+=a[0].length);this.moveCursorToPosition(b)};this.moveCursorLineEnd=function(){var a=this.lead,a=this.session.getDocumentLastRowColumnPosition(a.row,a.column);
if(this.lead.column==a.column){var d=this.session.getLine(a.row);a.column==d.length&&(d=d.search(/\s+$/),0<d&&(a.column=d))}this.moveCursorTo(a.row,a.column)};this.moveCursorFileEnd=function(){var a=this.doc.getLength()-1,d=this.doc.getLine(a).length;this.moveCursorTo(a,d)};this.moveCursorFileStart=function(){this.moveCursorTo(0,0)};this.moveCursorLongWordRight=function(){var a=this.lead.row,d=this.lead.column,b=this.doc.getLine(a),c=b.substring(d);this.session.nonTokenRe.lastIndex=0;this.session.tokenRe.lastIndex=
0;var h=this.session.getFoldAt(a,d,1);h?this.moveCursorTo(h.end.row,h.end.column):(this.session.nonTokenRe.exec(c)&&(d+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,c=b.substring(d)),d>=b.length?(this.moveCursorTo(a,b.length),this.moveCursorRight(),a<this.doc.getLength()-1&&this.moveCursorWordRight()):(this.session.tokenRe.exec(c)&&(d+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(a,d)))};this.moveCursorLongWordLeft=function(){var a=this.lead.row,
d=this.lead.column,b;(b=this.session.getFoldAt(a,d,-1))?this.moveCursorTo(b.start.row,b.start.column):(b=this.session.getFoldStringAt(a,d,-1),null==b&&(b=this.doc.getLine(a).substring(0,d)),b=m.stringReverse(b),this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(b)&&(d-=this.session.nonTokenRe.lastIndex,b=b.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0),0>=d?(this.moveCursorTo(a,0),this.moveCursorLeft(),0<a&&this.moveCursorWordLeft()):
(this.session.tokenRe.exec(b)&&(d-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(a,d)))};this.$shortWordEndIndex=function(a){var d=0,b,c=/\s/,h=this.session.tokenRe;h.lastIndex=0;if(this.session.tokenRe.exec(a))d=this.session.tokenRe.lastIndex;else{for(;(b=a[d])&&c.test(b);)d++;if(1>d)for(h.lastIndex=0;(b=a[d])&&!h.test(b);)if(h.lastIndex=0,d++,c.test(b))if(2<d){d--;break}else{for(;(b=a[d])&&c.test(b);)d++;if(2<d)break}}h.lastIndex=0;return d};this.moveCursorShortWordRight=
function(){var a=this.lead.row,d=this.lead.column,b=this.doc.getLine(a),c=b.substring(d),h=this.session.getFoldAt(a,d,1);if(h)return this.moveCursorTo(h.end.row,h.end.column);if(d==b.length){d=this.doc.getLength();do a++,c=this.doc.getLine(a);while(a<d&&/^\s*$/.test(c));/^\s+/.test(c)||(c="");d=0}c=this.$shortWordEndIndex(c);this.moveCursorTo(a,d+c)};this.moveCursorShortWordLeft=function(){var a=this.lead.row,d=this.lead.column,b;if(b=this.session.getFoldAt(a,d,-1))return this.moveCursorTo(b.start.row,
b.start.column);b=this.session.getLine(a).substring(0,d);if(0===d){do a--,b=this.doc.getLine(a);while(0<a&&/^\s*$/.test(b));d=b.length;/\s+$/.test(b)||(b="")}b=m.stringReverse(b);b=this.$shortWordEndIndex(b);return this.moveCursorTo(a,d-b)};this.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()};this.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()};this.moveCursorBy=
function(a,d){var b=this.session.documentToScreenPosition(this.lead.row,this.lead.column);0===d&&(this.$desiredColumn?b.column=this.$desiredColumn:this.$desiredColumn=b.column);b=this.session.screenToDocumentPosition(b.row+a,b.column);0!==a&&0===d&&b.row===this.lead.row&&b.column===this.lead.column&&this.session.lineWidgets&&this.session.lineWidgets[b.row]&&b.row++;this.moveCursorTo(b.row,b.column+d,0===d)};this.moveCursorToPosition=function(a){this.moveCursorTo(a.row,a.column)};this.moveCursorTo=
function(a,d,b){var c=this.session.getFoldAt(a,d,1);c&&(a=c.start.row,d=c.start.column);this.$keepDesiredColumnOnChange=!0;this.lead.setPosition(a,d);this.$keepDesiredColumnOnChange=!1;b||(this.$desiredColumn=null)};this.moveCursorToScreen=function(a,d,b){a=this.session.screenToDocumentPosition(a,d);this.moveCursorTo(a.row,a.column,b)};this.detach=function(){this.lead.detach();this.anchor.detach();this.session=this.doc=null};this.fromOrientedRange=function(a){this.setSelectionRange(a,a.cursor==a.start);
this.$desiredColumn=a.desiredColumn||this.$desiredColumn};this.toOrientedRange=function(a){var d=this.getRange();a?(a.start.column=d.start.column,a.start.row=d.start.row,a.end.column=d.end.column,a.end.row=d.end.row):a=d;a.cursor=this.isBackwards()?a.start:a.end;a.desiredColumn=this.$desiredColumn;return a};this.getRangeOfMovements=function(a){var d=this.getCursor();try{a.call(null,this);var b=this.getCursor();return c.fromPoints(d,b)}catch(n){return c.fromPoints(d,d)}finally{this.moveCursorToPosition(d)}};
this.toJSON=function(){if(this.rangeCount)var a=this.ranges.map(function(a){var b=a.clone();b.isBackwards=a.cursor==a.start;return b});else a=this.getRange(),a.isBackwards=this.isBackwards();return a};this.fromJSON=function(a){if(void 0==a.start){if(this.rangeList){this.toSingleRange(a[0]);for(var d=a.length;d--;){var b=c.fromPoints(a[d].start,a[d].end);a[d].isBackwards&&(b.cursor=b.start);this.addRange(b,!0)}return}a=a[0]}this.rangeList&&this.toSingleRange(a);this.setSelectionRange(a,a.isBackwards)};
this.isEqual=function(a){if((a.length||this.rangeCount)&&a.length!=this.rangeCount)return!1;if(!a.length||!this.ranges)return this.getRange().isEqual(a);for(var d=this.ranges.length;d--;)if(!this.ranges[d].isEqual(a[d]))return!1;return!0}}).call(f.prototype);k.Selection=f});
define("ace/tokenizer",["require","exports","module","ace/config"],function(f,k,r){var e=f("./config"),m=2E3;f=function(b){this.states=b;this.regExps={};this.matchMappings={};for(var c in this.states){b=this.states[c];for(var a=[],d=0,g=this.matchMappings[c]={defaultToken:"text"},n="g",h=[],e=0;e<b.length;e++){var l=b[e];l.defaultToken&&(g.defaultToken=l.defaultToken);l.caseInsensitive&&(n="gi");if(null!=l.regex){l.regex instanceof RegExp&&(l.regex=l.regex.toString().slice(1,-1));var p=l.regex,f=
(new RegExp("(?:("+p+")|(.))")).exec("a").length-2;Array.isArray(l.token)?1==l.token.length||1==f?l.token=l.token[0]:f-1!=l.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:l,groupCount:f-1}),l.token=l.token[0]):(l.tokenArray=l.token,l.token=null,l.onMatch=this.$arrayTokens):"function"!=typeof l.token||l.onMatch||(l.onMatch=1<f?this.$applyToken:l.token);1<f&&(/\\\d/.test(l.regex)?p=l.regex.replace(/\\([0-9]+)/g,function(a,b){return"\\"+(parseInt(b,10)+d+1)}):
(f=1,p=this.removeCapturingGroups(l.regex)),l.splitRegex||"string"==typeof l.token||h.push(l));g[d]=e;d+=f;a.push(p);l.onMatch||(l.onMatch=null)}}a.length||(g[0]=0,a.push("$"));h.forEach(function(a){a.splitRegex=this.createSplitterRegexp(a.regex,n)},this);this.regExps[c]=new RegExp("("+a.join(")|(")+")|($)",n)}};(function(){this.$setMaxTokenCount=function(b){m=b|0};this.$applyToken=function(b){var c=this.splitRegex.exec(b).slice(1),a=this.token.apply(this,c);if("string"===typeof a)return[{type:a,
value:b}];b=[];for(var d=0,g=a.length;d<g;d++)c[d]&&(b[b.length]={type:a[d],value:c[d]});return b};this.$arrayTokens=function(b){if(!b)return[];b=this.splitRegex.exec(b);if(!b)return"text";for(var c=[],a=this.tokenArray,d=0,g=a.length;d<g;d++)b[d+1]&&(c[c.length]={type:a[d],value:b[d+1]});return c};this.removeCapturingGroups=function(b){return b.replace(/\[(?:\\.|[^\]])*?\]|\\.|\(\?[:=!]|(\()/g,function(b,a){return a?"(?:":b})};this.createSplitterRegexp=function(b,c){if(-1!=b.indexOf("(?=")){var a=
0,d=!1,g={};b.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(b,c,e,l,p,f){d?d="]"!=p:p?d=!0:l?(a==g.stack&&(g.end=f+1,g.stack=-1),a--):e&&(a++,1!=e.length&&(g.stack=a,g.start=f));return b});null!=g.end&&/^\)*$/.test(b.substr(g.end))&&(b=b.substring(0,g.start)+b.substr(g.end))}return new RegExp(b,(c||"").replace("g",""))};this.getLineTokens=function(b,c){if(c&&"string"!=typeof c){var a=c.slice(0);c=a[0];"#tmp"===c&&(a.shift(),c=a.shift())}else a=[];var d=c||"start",g=this.states[d];g||(d=
"start",g=this.states[d]);var n=this.matchMappings[d],h=this.regExps[d];h.lastIndex=0;for(var e,l=[],p=0,f=0,s={type:null,value:""};e=h.exec(b);){var q=n.defaultToken,v=null,u=e[0],x=h.lastIndex;if(x-u.length>p){var B=b.substring(p,x-u.length);s.type==q?s.value+=B:(s.type&&l.push(s),s={type:q,value:B})}for(B=0;B<e.length-2;B++)if(void 0!==e[B+1]){v=g[n[B]];q=v.onMatch?v.onMatch(u,d,a):v.token;v.next&&(d="string"==typeof v.next?v.next:v.next(d,a),g=this.states[d],g||(this.reportError("state doesn't exist",
d),d="start",g=this.states[d]),n=this.matchMappings[d],p=x,h=this.regExps[d],h.lastIndex=x);break}if(u)if("string"===typeof q)v&&!1===v.merge||s.type!==q?(s.type&&l.push(s),s={type:q,value:u}):s.value+=u;else if(q)for(s.type&&l.push(s),s={type:null,value:""},B=0;B<q.length;B++)l.push(q[B]);if(p==b.length)break;p=x;if(f++>m){for(f>2*b.length&&this.reportError("infinite loop with in ace tokenizer",{startState:c,line:b});p<b.length;)s.type&&l.push(s),s={value:b.substring(p,p+=2E3),type:"overflow"};d=
"start";a=[];break}}s.type&&l.push(s);1<a.length&&a[0]!==d&&a.unshift("#tmp",d);return{tokens:l,state:a.length?a:d}};this.reportError=e.reportError}).call(f.prototype);k.Tokenizer=f});
define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/lang"],function(f,k,r){var e=f("../lib/lang");f=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}};(function(){this.addRules=function(b,a){if(a)for(h in b){for(var d=b[h],g=0;g<d.length;g++){var n=d[g];if(n.next||n.onMatch)"string"!=typeof n.next?n.nextState&&0!==n.nextState.indexOf(a)&&(n.nextState=a+n.nextState):0!==n.next.indexOf(a)&&(n.next=a+n.next)}this.$rules[a+h]=d}else for(var h in b)this.$rules[h]=
b[h]};this.getRules=function(){return this.$rules};this.embedRules=function(b,a,d,g,n){b="function"==typeof b?(new b).getRules():b;if(g)for(var h=0;h<g.length;h++)g[h]=a+g[h];else for(h in g=[],b)g.push(a+h);this.addRules(b,a);if(d)for(n=Array.prototype[n?"push":"unshift"],h=0;h<g.length;h++)n.apply(this.$rules[g[h]],e.deepCopy(d));this.$embeds||(this.$embeds=[]);this.$embeds.push(a)};this.getEmbeds=function(){return this.$embeds};var f=function(b,a){("start"!=b||a.length)&&a.unshift(this.nextState,
b);return this.nextState},b=function(b,a){a.shift();return a.shift()||"start"};this.normalizeRules=function(){function c(g){g=d[g];g.processed=!0;for(var n=0;n<g.length;n++){var h=g[n];!h.regex&&h.start&&(h.regex=h.start,h.next||(h.next=[]),h.next.push({defaultToken:h.token},{token:h.token+".end",regex:h.end||h.start,next:"pop"}),h.token+=".start",h.push=!0);var e=h.next||h.push;if(e&&Array.isArray(e)){var l=h.stateName;l||(l=h.token,"string"!=typeof l&&(l=l[0]||""),d[l]&&(l+=a++));d[l]=e;h.next=
l;c(l)}else"pop"==e&&(h.next=b);h.push&&(h.nextState=h.next||h.push,h.next=f,delete h.push);if(h.rules)for(var p in h.rules)d[p]?d[p].push&&d[p].push.apply(d[p],h.rules[p]):d[p]=h.rules[p];if(h.include||"string"==typeof h)var D=d[h.include||h];else Array.isArray(h)&&(D=h);D&&(D=[n,1].concat(D),h.noEscape&&(D=D.filter(function(a){return!a.next})),g.splice.apply(g,D),n--,D=null);h.keywordMap&&(h.token=this.createKeywordMapper(h.keywordMap,h.defaultToken||"text",h.caseInsensitive),delete h.defaultToken)}}
var a=0,d=this.$rules;Object.keys(d).forEach(c,this)};this.createKeywordMapper=function(b,a,d,g){var n=Object.create(null);Object.keys(b).forEach(function(a){var e=b[a];d&&(e=e.toLowerCase());for(var e=e.split(g||"|"),l=e.length;l--;)n[e[l]]=a});Object.getPrototypeOf(n)&&(n.__proto__=null);this.$keywordList=Object.keys(n);b=null;return d?function(d){return n[d.toLowerCase()]||a}:function(d){return n[d]||a}};this.getKeywords=function(){return this.$keywords}}).call(f.prototype);k.TextHighlightRules=
f});
define("ace/mode/behaviour",["require","exports","module"],function(f,k,r){f=function(){this.$behaviours={}};(function(){this.add=function(e,f,b){switch(void 0){case this.$behaviours:this.$behaviours={};case this.$behaviours[e]:this.$behaviours[e]={}}this.$behaviours[e][f]=b};this.addBehaviours=function(e){for(var f in e)for(var b in e[f])this.add(f,b,e[f][b])};this.remove=function(e){this.$behaviours&&this.$behaviours[e]&&delete this.$behaviours[e]};this.inherit=function(e,f){var b="function"===typeof e?
(new e).getBehaviours(f):e.getBehaviours(f);this.addBehaviours(b)};this.getBehaviours=function(e){if(e){for(var f={},b=0;b<e.length;b++)this.$behaviours[e[b]]&&(f[e[b]]=this.$behaviours[e[b]]);return f}return this.$behaviours}}).call(f.prototype);k.Behaviour=f});
define("ace/unicode",["require","exports","module"],function(f,k,r){k.packages={};f={L:"0041-005A0061-007A00AA00B500BA00C0-00D600D8-00F600F8-02C102C6-02D102E0-02E402EC02EE0370-037403760377037A-037D03860388-038A038C038E-03A103A3-03F503F7-0481048A-05250531-055605590561-058705D0-05EA05F0-05F20621-064A066E066F0671-06D306D506E506E606EE06EF06FA-06FC06FF07100712-072F074D-07A507B107CA-07EA07F407F507FA0800-0815081A082408280904-0939093D09500958-0961097109720979-097F0985-098C098F09900993-09A809AA-09B009B209B6-09B909BD09CE09DC09DD09DF-09E109F009F10A05-0A0A0A0F0A100A13-0A280A2A-0A300A320A330A350A360A380A390A59-0A5C0A5E0A72-0A740A85-0A8D0A8F-0A910A93-0AA80AAA-0AB00AB20AB30AB5-0AB90ABD0AD00AE00AE10B05-0B0C0B0F0B100B13-0B280B2A-0B300B320B330B35-0B390B3D0B5C0B5D0B5F-0B610B710B830B85-0B8A0B8E-0B900B92-0B950B990B9A0B9C0B9E0B9F0BA30BA40BA8-0BAA0BAE-0BB90BD00C05-0C0C0C0E-0C100C12-0C280C2A-0C330C35-0C390C3D0C580C590C600C610C85-0C8C0C8E-0C900C92-0CA80CAA-0CB30CB5-0CB90CBD0CDE0CE00CE10D05-0D0C0D0E-0D100D12-0D280D2A-0D390D3D0D600D610D7A-0D7F0D85-0D960D9A-0DB10DB3-0DBB0DBD0DC0-0DC60E01-0E300E320E330E40-0E460E810E820E840E870E880E8A0E8D0E94-0E970E99-0E9F0EA1-0EA30EA50EA70EAA0EAB0EAD-0EB00EB20EB30EBD0EC0-0EC40EC60EDC0EDD0F000F40-0F470F49-0F6C0F88-0F8B1000-102A103F1050-1055105A-105D106110651066106E-10701075-1081108E10A0-10C510D0-10FA10FC1100-1248124A-124D1250-12561258125A-125D1260-1288128A-128D1290-12B012B2-12B512B8-12BE12C012C2-12C512C8-12D612D8-13101312-13151318-135A1380-138F13A0-13F41401-166C166F-167F1681-169A16A0-16EA1700-170C170E-17111720-17311740-17511760-176C176E-17701780-17B317D717DC1820-18771880-18A818AA18B0-18F51900-191C1950-196D1970-19741980-19AB19C1-19C71A00-1A161A20-1A541AA71B05-1B331B45-1B4B1B83-1BA01BAE1BAF1C00-1C231C4D-1C4F1C5A-1C7D1CE9-1CEC1CEE-1CF11D00-1DBF1E00-1F151F18-1F1D1F20-1F451F48-1F4D1F50-1F571F591F5B1F5D1F5F-1F7D1F80-1FB41FB6-1FBC1FBE1FC2-1FC41FC6-1FCC1FD0-1FD31FD6-1FDB1FE0-1FEC1FF2-1FF41FF6-1FFC2071207F2090-209421022107210A-211321152119-211D212421262128212A-212D212F-2139213C-213F2145-2149214E218321842C00-2C2E2C30-2C5E2C60-2CE42CEB-2CEE2D00-2D252D30-2D652D6F2D80-2D962DA0-2DA62DA8-2DAE2DB0-2DB62DB8-2DBE2DC0-2DC62DC8-2DCE2DD0-2DD62DD8-2DDE2E2F300530063031-3035303B303C3041-3096309D-309F30A1-30FA30FC-30FF3105-312D3131-318E31A0-31B731F0-31FF3400-4DB54E00-9FCBA000-A48CA4D0-A4FDA500-A60CA610-A61FA62AA62BA640-A65FA662-A66EA67F-A697A6A0-A6E5A717-A71FA722-A788A78BA78CA7FB-A801A803-A805A807-A80AA80C-A822A840-A873A882-A8B3A8F2-A8F7A8FBA90A-A925A930-A946A960-A97CA984-A9B2A9CFAA00-AA28AA40-AA42AA44-AA4BAA60-AA76AA7AAA80-AAAFAAB1AAB5AAB6AAB9-AABDAAC0AAC2AADB-AADDABC0-ABE2AC00-D7A3D7B0-D7C6D7CB-D7FBF900-FA2DFA30-FA6DFA70-FAD9FB00-FB06FB13-FB17FB1DFB1F-FB28FB2A-FB36FB38-FB3CFB3EFB40FB41FB43FB44FB46-FBB1FBD3-FD3DFD50-FD8FFD92-FDC7FDF0-FDFBFE70-FE74FE76-FEFCFF21-FF3AFF41-FF5AFF66-FFBEFFC2-FFC7FFCA-FFCFFFD2-FFD7FFDA-FFDC",Ll:"0061-007A00AA00B500BA00DF-00F600F8-00FF01010103010501070109010B010D010F01110113011501170119011B011D011F01210123012501270129012B012D012F01310133013501370138013A013C013E014001420144014601480149014B014D014F01510153015501570159015B015D015F01610163016501670169016B016D016F0171017301750177017A017C017E-0180018301850188018C018D019201950199-019B019E01A101A301A501A801AA01AB01AD01B001B401B601B901BA01BD-01BF01C601C901CC01CE01D001D201D401D601D801DA01DC01DD01DF01E101E301E501E701E901EB01ED01EF01F001F301F501F901FB01FD01FF02010203020502070209020B020D020F02110213021502170219021B021D021F02210223022502270229022B022D022F02310233-0239023C023F0240024202470249024B024D024F-02930295-02AF037103730377037B-037D039003AC-03CE03D003D103D5-03D703D903DB03DD03DF03E103E303E503E703E903EB03ED03EF-03F303F503F803FB03FC0430-045F04610463046504670469046B046D046F04710473047504770479047B047D047F0481048B048D048F04910493049504970499049B049D049F04A104A304A504A704A904AB04AD04AF04B104B304B504B704B904BB04BD04BF04C204C404C604C804CA04CC04CE04CF04D104D304D504D704D904DB04DD04DF04E104E304E504E704E904EB04ED04EF04F104F304F504F704F904FB04FD04FF05010503050505070509050B050D050F05110513051505170519051B051D051F0521052305250561-05871D00-1D2B1D62-1D771D79-1D9A1E011E031E051E071E091E0B1E0D1E0F1E111E131E151E171E191E1B1E1D1E1F1E211E231E251E271E291E2B1E2D1E2F1E311E331E351E371E391E3B1E3D1E3F1E411E431E451E471E491E4B1E4D1E4F1E511E531E551E571E591E5B1E5D1E5F1E611E631E651E671E691E6B1E6D1E6F1E711E731E751E771E791E7B1E7D1E7F1E811E831E851E871E891E8B1E8D1E8F1E911E931E95-1E9D1E9F1EA11EA31EA51EA71EA91EAB1EAD1EAF1EB11EB31EB51EB71EB91EBB1EBD1EBF1EC11EC31EC51EC71EC91ECB1ECD1ECF1ED11ED31ED51ED71ED91EDB1EDD1EDF1EE11EE31EE51EE71EE91EEB1EED1EEF1EF11EF31EF51EF71EF91EFB1EFD1EFF-1F071F10-1F151F20-1F271F30-1F371F40-1F451F50-1F571F60-1F671F70-1F7D1F80-1F871F90-1F971FA0-1FA71FB0-1FB41FB61FB71FBE1FC2-1FC41FC61FC71FD0-1FD31FD61FD71FE0-1FE71FF2-1FF41FF61FF7210A210E210F2113212F21342139213C213D2146-2149214E21842C30-2C5E2C612C652C662C682C6A2C6C2C712C732C742C76-2C7C2C812C832C852C872C892C8B2C8D2C8F2C912C932C952C972C992C9B2C9D2C9F2CA12CA32CA52CA72CA92CAB2CAD2CAF2CB12CB32CB52CB72CB92CBB2CBD2CBF2CC12CC32CC52CC72CC92CCB2CCD2CCF2CD12CD32CD52CD72CD92CDB2CDD2CDF2CE12CE32CE42CEC2CEE2D00-2D25A641A643A645A647A649A64BA64DA64FA651A653A655A657A659A65BA65DA65FA663A665A667A669A66BA66DA681A683A685A687A689A68BA68DA68FA691A693A695A697A723A725A727A729A72BA72DA72F-A731A733A735A737A739A73BA73DA73FA741A743A745A747A749A74BA74DA74FA751A753A755A757A759A75BA75DA75FA761A763A765A767A769A76BA76DA76FA771-A778A77AA77CA77FA781A783A785A787A78CFB00-FB06FB13-FB17FF41-FF5A",
Lu:"0041-005A00C0-00D600D8-00DE01000102010401060108010A010C010E01100112011401160118011A011C011E01200122012401260128012A012C012E01300132013401360139013B013D013F0141014301450147014A014C014E01500152015401560158015A015C015E01600162016401660168016A016C016E017001720174017601780179017B017D018101820184018601870189-018B018E-0191019301940196-0198019C019D019F01A001A201A401A601A701A901AC01AE01AF01B1-01B301B501B701B801BC01C401C701CA01CD01CF01D101D301D501D701D901DB01DE01E001E201E401E601E801EA01EC01EE01F101F401F6-01F801FA01FC01FE02000202020402060208020A020C020E02100212021402160218021A021C021E02200222022402260228022A022C022E02300232023A023B023D023E02410243-02460248024A024C024E03700372037603860388-038A038C038E038F0391-03A103A3-03AB03CF03D2-03D403D803DA03DC03DE03E003E203E403E603E803EA03EC03EE03F403F703F903FA03FD-042F04600462046404660468046A046C046E04700472047404760478047A047C047E0480048A048C048E04900492049404960498049A049C049E04A004A204A404A604A804AA04AC04AE04B004B204B404B604B804BA04BC04BE04C004C104C304C504C704C904CB04CD04D004D204D404D604D804DA04DC04DE04E004E204E404E604E804EA04EC04EE04F004F204F404F604F804FA04FC04FE05000502050405060508050A050C050E05100512051405160518051A051C051E0520052205240531-055610A0-10C51E001E021E041E061E081E0A1E0C1E0E1E101E121E141E161E181E1A1E1C1E1E1E201E221E241E261E281E2A1E2C1E2E1E301E321E341E361E381E3A1E3C1E3E1E401E421E441E461E481E4A1E4C1E4E1E501E521E541E561E581E5A1E5C1E5E1E601E621E641E661E681E6A1E6C1E6E1E701E721E741E761E781E7A1E7C1E7E1E801E821E841E861E881E8A1E8C1E8E1E901E921E941E9E1EA01EA21EA41EA61EA81EAA1EAC1EAE1EB01EB21EB41EB61EB81EBA1EBC1EBE1EC01EC21EC41EC61EC81ECA1ECC1ECE1ED01ED21ED41ED61ED81EDA1EDC1EDE1EE01EE21EE41EE61EE81EEA1EEC1EEE1EF01EF21EF41EF61EF81EFA1EFC1EFE1F08-1F0F1F18-1F1D1F28-1F2F1F38-1F3F1F48-1F4D1F591F5B1F5D1F5F1F68-1F6F1FB8-1FBB1FC8-1FCB1FD8-1FDB1FE8-1FEC1FF8-1FFB21022107210B-210D2110-211221152119-211D212421262128212A-212D2130-2133213E213F214521832C00-2C2E2C602C62-2C642C672C692C6B2C6D-2C702C722C752C7E-2C802C822C842C862C882C8A2C8C2C8E2C902C922C942C962C982C9A2C9C2C9E2CA02CA22CA42CA62CA82CAA2CAC2CAE2CB02CB22CB42CB62CB82CBA2CBC2CBE2CC02CC22CC42CC62CC82CCA2CCC2CCE2CD02CD22CD42CD62CD82CDA2CDC2CDE2CE02CE22CEB2CEDA640A642A644A646A648A64AA64CA64EA650A652A654A656A658A65AA65CA65EA662A664A666A668A66AA66CA680A682A684A686A688A68AA68CA68EA690A692A694A696A722A724A726A728A72AA72CA72EA732A734A736A738A73AA73CA73EA740A742A744A746A748A74AA74CA74EA750A752A754A756A758A75AA75CA75EA760A762A764A766A768A76AA76CA76EA779A77BA77DA77EA780A782A784A786A78BFF21-FF3A",
Lt:"01C501C801CB01F21F88-1F8F1F98-1F9F1FA8-1FAF1FBC1FCC1FFC",Lm:"02B0-02C102C6-02D102E0-02E402EC02EE0374037A0559064006E506E607F407F507FA081A0824082809710E460EC610FC17D718431AA71C78-1C7D1D2C-1D611D781D9B-1DBF2071207F2090-20942C7D2D6F2E2F30053031-3035303B309D309E30FC-30FEA015A4F8-A4FDA60CA67FA717-A71FA770A788A9CFAA70AADDFF70FF9EFF9F",Lo:"01BB01C0-01C3029405D0-05EA05F0-05F20621-063F0641-064A066E066F0671-06D306D506EE06EF06FA-06FC06FF07100712-072F074D-07A507B107CA-07EA0800-08150904-0939093D09500958-096109720979-097F0985-098C098F09900993-09A809AA-09B009B209B6-09B909BD09CE09DC09DD09DF-09E109F009F10A05-0A0A0A0F0A100A13-0A280A2A-0A300A320A330A350A360A380A390A59-0A5C0A5E0A72-0A740A85-0A8D0A8F-0A910A93-0AA80AAA-0AB00AB20AB30AB5-0AB90ABD0AD00AE00AE10B05-0B0C0B0F0B100B13-0B280B2A-0B300B320B330B35-0B390B3D0B5C0B5D0B5F-0B610B710B830B85-0B8A0B8E-0B900B92-0B950B990B9A0B9C0B9E0B9F0BA30BA40BA8-0BAA0BAE-0BB90BD00C05-0C0C0C0E-0C100C12-0C280C2A-0C330C35-0C390C3D0C580C590C600C610C85-0C8C0C8E-0C900C92-0CA80CAA-0CB30CB5-0CB90CBD0CDE0CE00CE10D05-0D0C0D0E-0D100D12-0D280D2A-0D390D3D0D600D610D7A-0D7F0D85-0D960D9A-0DB10DB3-0DBB0DBD0DC0-0DC60E01-0E300E320E330E40-0E450E810E820E840E870E880E8A0E8D0E94-0E970E99-0E9F0EA1-0EA30EA50EA70EAA0EAB0EAD-0EB00EB20EB30EBD0EC0-0EC40EDC0EDD0F000F40-0F470F49-0F6C0F88-0F8B1000-102A103F1050-1055105A-105D106110651066106E-10701075-1081108E10D0-10FA1100-1248124A-124D1250-12561258125A-125D1260-1288128A-128D1290-12B012B2-12B512B8-12BE12C012C2-12C512C8-12D612D8-13101312-13151318-135A1380-138F13A0-13F41401-166C166F-167F1681-169A16A0-16EA1700-170C170E-17111720-17311740-17511760-176C176E-17701780-17B317DC1820-18421844-18771880-18A818AA18B0-18F51900-191C1950-196D1970-19741980-19AB19C1-19C71A00-1A161A20-1A541B05-1B331B45-1B4B1B83-1BA01BAE1BAF1C00-1C231C4D-1C4F1C5A-1C771CE9-1CEC1CEE-1CF12135-21382D30-2D652D80-2D962DA0-2DA62DA8-2DAE2DB0-2DB62DB8-2DBE2DC0-2DC62DC8-2DCE2DD0-2DD62DD8-2DDE3006303C3041-3096309F30A1-30FA30FF3105-312D3131-318E31A0-31B731F0-31FF3400-4DB54E00-9FCBA000-A014A016-A48CA4D0-A4F7A500-A60BA610-A61FA62AA62BA66EA6A0-A6E5A7FB-A801A803-A805A807-A80AA80C-A822A840-A873A882-A8B3A8F2-A8F7A8FBA90A-A925A930-A946A960-A97CA984-A9B2AA00-AA28AA40-AA42AA44-AA4BAA60-AA6FAA71-AA76AA7AAA80-AAAFAAB1AAB5AAB6AAB9-AABDAAC0AAC2AADBAADCABC0-ABE2AC00-D7A3D7B0-D7C6D7CB-D7FBF900-FA2DFA30-FA6DFA70-FAD9FB1DFB1F-FB28FB2A-FB36FB38-FB3CFB3EFB40FB41FB43FB44FB46-FBB1FBD3-FD3DFD50-FD8FFD92-FDC7FDF0-FDFBFE70-FE74FE76-FEFCFF66-FF6FFF71-FF9DFFA0-FFBEFFC2-FFC7FFCA-FFCFFFD2-FFD7FFDA-FFDC",
M:"0300-036F0483-04890591-05BD05BF05C105C205C405C505C70610-061A064B-065E067006D6-06DC06DE-06E406E706E806EA-06ED07110730-074A07A6-07B007EB-07F30816-0819081B-08230825-08270829-082D0900-0903093C093E-094E0951-0955096209630981-098309BC09BE-09C409C709C809CB-09CD09D709E209E30A01-0A030A3C0A3E-0A420A470A480A4B-0A4D0A510A700A710A750A81-0A830ABC0ABE-0AC50AC7-0AC90ACB-0ACD0AE20AE30B01-0B030B3C0B3E-0B440B470B480B4B-0B4D0B560B570B620B630B820BBE-0BC20BC6-0BC80BCA-0BCD0BD70C01-0C030C3E-0C440C46-0C480C4A-0C4D0C550C560C620C630C820C830CBC0CBE-0CC40CC6-0CC80CCA-0CCD0CD50CD60CE20CE30D020D030D3E-0D440D46-0D480D4A-0D4D0D570D620D630D820D830DCA0DCF-0DD40DD60DD8-0DDF0DF20DF30E310E34-0E3A0E47-0E4E0EB10EB4-0EB90EBB0EBC0EC8-0ECD0F180F190F350F370F390F3E0F3F0F71-0F840F860F870F90-0F970F99-0FBC0FC6102B-103E1056-1059105E-10601062-10641067-106D1071-10741082-108D108F109A-109D135F1712-17141732-1734175217531772177317B6-17D317DD180B-180D18A91920-192B1930-193B19B0-19C019C819C91A17-1A1B1A55-1A5E1A60-1A7C1A7F1B00-1B041B34-1B441B6B-1B731B80-1B821BA1-1BAA1C24-1C371CD0-1CD21CD4-1CE81CED1CF21DC0-1DE61DFD-1DFF20D0-20F02CEF-2CF12DE0-2DFF302A-302F3099309AA66F-A672A67CA67DA6F0A6F1A802A806A80BA823-A827A880A881A8B4-A8C4A8E0-A8F1A926-A92DA947-A953A980-A983A9B3-A9C0AA29-AA36AA43AA4CAA4DAA7BAAB0AAB2-AAB4AAB7AAB8AABEAABFAAC1ABE3-ABEAABECABEDFB1EFE00-FE0FFE20-FE26",
Mn:"0300-036F0483-04870591-05BD05BF05C105C205C405C505C70610-061A064B-065E067006D6-06DC06DF-06E406E706E806EA-06ED07110730-074A07A6-07B007EB-07F30816-0819081B-08230825-08270829-082D0900-0902093C0941-0948094D0951-095509620963098109BC09C1-09C409CD09E209E30A010A020A3C0A410A420A470A480A4B-0A4D0A510A700A710A750A810A820ABC0AC1-0AC50AC70AC80ACD0AE20AE30B010B3C0B3F0B41-0B440B4D0B560B620B630B820BC00BCD0C3E-0C400C46-0C480C4A-0C4D0C550C560C620C630CBC0CBF0CC60CCC0CCD0CE20CE30D41-0D440D4D0D620D630DCA0DD2-0DD40DD60E310E34-0E3A0E47-0E4E0EB10EB4-0EB90EBB0EBC0EC8-0ECD0F180F190F350F370F390F71-0F7E0F80-0F840F860F870F90-0F970F99-0FBC0FC6102D-10301032-10371039103A103D103E10581059105E-10601071-1074108210851086108D109D135F1712-17141732-1734175217531772177317B7-17BD17C617C9-17D317DD180B-180D18A91920-19221927192819321939-193B1A171A181A561A58-1A5E1A601A621A65-1A6C1A73-1A7C1A7F1B00-1B031B341B36-1B3A1B3C1B421B6B-1B731B801B811BA2-1BA51BA81BA91C2C-1C331C361C371CD0-1CD21CD4-1CE01CE2-1CE81CED1DC0-1DE61DFD-1DFF20D0-20DC20E120E5-20F02CEF-2CF12DE0-2DFF302A-302F3099309AA66FA67CA67DA6F0A6F1A802A806A80BA825A826A8C4A8E0-A8F1A926-A92DA947-A951A980-A982A9B3A9B6-A9B9A9BCAA29-AA2EAA31AA32AA35AA36AA43AA4CAAB0AAB2-AAB4AAB7AAB8AABEAABFAAC1ABE5ABE8ABEDFB1EFE00-FE0FFE20-FE26",
Mc:"0903093E-09400949-094C094E0982098309BE-09C009C709C809CB09CC09D70A030A3E-0A400A830ABE-0AC00AC90ACB0ACC0B020B030B3E0B400B470B480B4B0B4C0B570BBE0BBF0BC10BC20BC6-0BC80BCA-0BCC0BD70C01-0C030C41-0C440C820C830CBE0CC0-0CC40CC70CC80CCA0CCB0CD50CD60D020D030D3E-0D400D46-0D480D4A-0D4C0D570D820D830DCF-0DD10DD8-0DDF0DF20DF30F3E0F3F0F7F102B102C10311038103B103C105610571062-10641067-106D108310841087-108C108F109A-109C17B617BE-17C517C717C81923-19261929-192B193019311933-193819B0-19C019C819C91A19-1A1B1A551A571A611A631A641A6D-1A721B041B351B3B1B3D-1B411B431B441B821BA11BA61BA71BAA1C24-1C2B1C341C351CE11CF2A823A824A827A880A881A8B4-A8C3A952A953A983A9B4A9B5A9BAA9BBA9BD-A9C0AA2FAA30AA33AA34AA4DAA7BABE3ABE4ABE6ABE7ABE9ABEAABEC",
Me:"0488048906DE20DD-20E020E2-20E4A670-A672",N:"0030-003900B200B300B900BC-00BE0660-066906F0-06F907C0-07C90966-096F09E6-09EF09F4-09F90A66-0A6F0AE6-0AEF0B66-0B6F0BE6-0BF20C66-0C6F0C78-0C7E0CE6-0CEF0D66-0D750E50-0E590ED0-0ED90F20-0F331040-10491090-10991369-137C16EE-16F017E0-17E917F0-17F91810-18191946-194F19D0-19DA1A80-1A891A90-1A991B50-1B591BB0-1BB91C40-1C491C50-1C5920702074-20792080-20892150-21822185-21892460-249B24EA-24FF2776-27932CFD30073021-30293038-303A3192-31953220-32293251-325F3280-328932B1-32BFA620-A629A6E6-A6EFA830-A835A8D0-A8D9A900-A909A9D0-A9D9AA50-AA59ABF0-ABF9FF10-FF19",
Nd:"0030-00390660-066906F0-06F907C0-07C90966-096F09E6-09EF0A66-0A6F0AE6-0AEF0B66-0B6F0BE6-0BEF0C66-0C6F0CE6-0CEF0D66-0D6F0E50-0E590ED0-0ED90F20-0F291040-10491090-109917E0-17E91810-18191946-194F19D0-19DA1A80-1A891A90-1A991B50-1B591BB0-1BB91C40-1C491C50-1C59A620-A629A8D0-A8D9A900-A909A9D0-A9D9AA50-AA59ABF0-ABF9FF10-FF19",Nl:"16EE-16F02160-21822185-218830073021-30293038-303AA6E6-A6EF",No:"00B200B300B900BC-00BE09F4-09F90BF0-0BF20C78-0C7E0D70-0D750F2A-0F331369-137C17F0-17F920702074-20792080-20892150-215F21892460-249B24EA-24FF2776-27932CFD3192-31953220-32293251-325F3280-328932B1-32BFA830-A835",
P:"0021-00230025-002A002C-002F003A003B003F0040005B-005D005F007B007D00A100AB00B700BB00BF037E0387055A-055F0589058A05BE05C005C305C605F305F40609060A060C060D061B061E061F066A-066D06D40700-070D07F7-07F90830-083E0964096509700DF40E4F0E5A0E5B0F04-0F120F3A-0F3D0F850FD0-0FD4104A-104F10FB1361-13681400166D166E169B169C16EB-16ED1735173617D4-17D617D8-17DA1800-180A1944194519DE19DF1A1E1A1F1AA0-1AA61AA8-1AAD1B5A-1B601C3B-1C3F1C7E1C7F1CD32010-20272030-20432045-20512053-205E207D207E208D208E2329232A2768-277527C527C627E6-27EF2983-299829D8-29DB29FC29FD2CF9-2CFC2CFE2CFF2E00-2E2E2E302E313001-30033008-30113014-301F3030303D30A030FBA4FEA4FFA60D-A60FA673A67EA6F2-A6F7A874-A877A8CEA8CFA8F8-A8FAA92EA92FA95FA9C1-A9CDA9DEA9DFAA5C-AA5FAADEAADFABEBFD3EFD3FFE10-FE19FE30-FE52FE54-FE61FE63FE68FE6AFE6BFF01-FF03FF05-FF0AFF0C-FF0FFF1AFF1BFF1FFF20FF3B-FF3DFF3FFF5BFF5DFF5F-FF65",
Pd:"002D058A05BE140018062010-20152E172E1A301C303030A0FE31FE32FE58FE63FF0D",Ps:"0028005B007B0F3A0F3C169B201A201E2045207D208D23292768276A276C276E27702772277427C527E627E827EA27EC27EE2983298529872989298B298D298F299129932995299729D829DA29FC2E222E242E262E283008300A300C300E3010301430163018301A301DFD3EFE17FE35FE37FE39FE3BFE3DFE3FFE41FE43FE47FE59FE5BFE5DFF08FF3BFF5BFF5FFF62",Pe:"0029005D007D0F3B0F3D169C2046207E208E232A2769276B276D276F27712773277527C627E727E927EB27ED27EF298429862988298A298C298E2990299229942996299829D929DB29FD2E232E252E272E293009300B300D300F3011301530173019301B301E301FFD3FFE18FE36FE38FE3AFE3CFE3EFE40FE42FE44FE48FE5AFE5CFE5EFF09FF3DFF5DFF60FF63",
Pi:"00AB2018201B201C201F20392E022E042E092E0C2E1C2E20",Pf:"00BB2019201D203A2E032E052E0A2E0D2E1D2E21",Pc:"005F203F20402054FE33FE34FE4D-FE4FFF3F",Po:"0021-00230025-0027002A002C002E002F003A003B003F0040005C00A100B700BF037E0387055A-055F058905C005C305C605F305F40609060A060C060D061B061E061F066A-066D06D40700-070D07F7-07F90830-083E0964096509700DF40E4F0E5A0E5B0F04-0F120F850FD0-0FD4104A-104F10FB1361-1368166D166E16EB-16ED1735173617D4-17D617D8-17DA1800-18051807-180A1944194519DE19DF1A1E1A1F1AA0-1AA61AA8-1AAD1B5A-1B601C3B-1C3F1C7E1C7F1CD3201620172020-20272030-2038203B-203E2041-20432047-205120532055-205E2CF9-2CFC2CFE2CFF2E002E012E06-2E082E0B2E0E-2E162E182E192E1B2E1E2E1F2E2A-2E2E2E302E313001-3003303D30FBA4FEA4FFA60D-A60FA673A67EA6F2-A6F7A874-A877A8CEA8CFA8F8-A8FAA92EA92FA95FA9C1-A9CDA9DEA9DFAA5C-AA5FAADEAADFABEBFE10-FE16FE19FE30FE45FE46FE49-FE4CFE50-FE52FE54-FE57FE5F-FE61FE68FE6AFE6BFF01-FF03FF05-FF07FF0AFF0CFF0EFF0FFF1AFF1BFF1FFF20FF3CFF61FF64FF65",
S:"0024002B003C-003E005E0060007C007E00A2-00A900AC00AE-00B100B400B600B800D700F702C2-02C502D2-02DF02E5-02EB02ED02EF-02FF03750384038503F604820606-0608060B060E060F06E906FD06FE07F609F209F309FA09FB0AF10B700BF3-0BFA0C7F0CF10CF20D790E3F0F01-0F030F13-0F170F1A-0F1F0F340F360F380FBE-0FC50FC7-0FCC0FCE0FCF0FD5-0FD8109E109F13601390-139917DB194019E0-19FF1B61-1B6A1B74-1B7C1FBD1FBF-1FC11FCD-1FCF1FDD-1FDF1FED-1FEF1FFD1FFE20442052207A-207C208A-208C20A0-20B8210021012103-21062108210921142116-2118211E-2123212521272129212E213A213B2140-2144214A-214D214F2190-2328232B-23E82400-24262440-244A249C-24E92500-26CD26CF-26E126E326E8-26FF2701-27042706-2709270C-27272729-274B274D274F-27522756-275E2761-276727942798-27AF27B1-27BE27C0-27C427C7-27CA27CC27D0-27E527F0-29822999-29D729DC-29FB29FE-2B4C2B50-2B592CE5-2CEA2E80-2E992E9B-2EF32F00-2FD52FF0-2FFB300430123013302030363037303E303F309B309C319031913196-319F31C0-31E33200-321E322A-32503260-327F328A-32B032C0-32FE3300-33FF4DC0-4DFFA490-A4C6A700-A716A720A721A789A78AA828-A82BA836-A839AA77-AA79FB29FDFCFDFDFE62FE64-FE66FE69FF04FF0BFF1C-FF1EFF3EFF40FF5CFF5EFFE0-FFE6FFE8-FFEEFFFCFFFD",
Sm:"002B003C-003E007C007E00AC00B100D700F703F60606-060820442052207A-207C208A-208C2140-2144214B2190-2194219A219B21A021A321A621AE21CE21CF21D221D421F4-22FF2308-230B23202321237C239B-23B323DC-23E125B725C125F8-25FF266F27C0-27C427C7-27CA27CC27D0-27E527F0-27FF2900-29822999-29D729DC-29FB29FE-2AFF2B30-2B442B47-2B4CFB29FE62FE64-FE66FF0BFF1C-FF1EFF5CFF5EFFE2FFE9-FFEC",Sc:"002400A2-00A5060B09F209F309FB0AF10BF90E3F17DB20A0-20B8A838FDFCFE69FF04FFE0FFE1FFE5FFE6",Sk:"005E006000A800AF00B400B802C2-02C502D2-02DF02E5-02EB02ED02EF-02FF0375038403851FBD1FBF-1FC11FCD-1FCF1FDD-1FDF1FED-1FEF1FFD1FFE309B309CA700-A716A720A721A789A78AFF3EFF40FFE3",
So:"00A600A700A900AE00B000B60482060E060F06E906FD06FE07F609FA0B700BF3-0BF80BFA0C7F0CF10CF20D790F01-0F030F13-0F170F1A-0F1F0F340F360F380FBE-0FC50FC7-0FCC0FCE0FCF0FD5-0FD8109E109F13601390-1399194019E0-19FF1B61-1B6A1B74-1B7C210021012103-21062108210921142116-2118211E-2123212521272129212E213A213B214A214C214D214F2195-2199219C-219F21A121A221A421A521A7-21AD21AF-21CD21D021D121D321D5-21F32300-2307230C-231F2322-2328232B-237B237D-239A23B4-23DB23E2-23E82400-24262440-244A249C-24E92500-25B625B8-25C025C2-25F72600-266E2670-26CD26CF-26E126E326E8-26FF2701-27042706-2709270C-27272729-274B274D274F-27522756-275E2761-276727942798-27AF27B1-27BE2800-28FF2B00-2B2F2B452B462B50-2B592CE5-2CEA2E80-2E992E9B-2EF32F00-2FD52FF0-2FFB300430123013302030363037303E303F319031913196-319F31C0-31E33200-321E322A-32503260-327F328A-32B032C0-32FE3300-33FF4DC0-4DFFA490-A4C6A828-A82BA836A837A839AA77-AA79FDFDFFE4FFE8FFEDFFEEFFFCFFFD",
Z:"002000A01680180E2000-200A20282029202F205F3000",Zs:"002000A01680180E2000-200A202F205F3000",Zl:"2028",Zp:"2029",C:"0000-001F007F-009F00AD03780379037F-0383038B038D03A20526-05300557055805600588058B-059005C8-05CF05EB-05EF05F5-0605061C061D0620065F06DD070E070F074B074C07B2-07BF07FB-07FF082E082F083F-08FF093A093B094F095609570973-097809800984098D098E0991099209A909B109B3-09B509BA09BB09C509C609C909CA09CF-09D609D8-09DB09DE09E409E509FC-0A000A040A0B-0A0E0A110A120A290A310A340A370A3A0A3B0A3D0A43-0A460A490A4A0A4E-0A500A52-0A580A5D0A5F-0A650A76-0A800A840A8E0A920AA90AB10AB40ABA0ABB0AC60ACA0ACE0ACF0AD1-0ADF0AE40AE50AF00AF2-0B000B040B0D0B0E0B110B120B290B310B340B3A0B3B0B450B460B490B4A0B4E-0B550B58-0B5B0B5E0B640B650B72-0B810B840B8B-0B8D0B910B96-0B980B9B0B9D0BA0-0BA20BA5-0BA70BAB-0BAD0BBA-0BBD0BC3-0BC50BC90BCE0BCF0BD1-0BD60BD8-0BE50BFB-0C000C040C0D0C110C290C340C3A-0C3C0C450C490C4E-0C540C570C5A-0C5F0C640C650C70-0C770C800C810C840C8D0C910CA90CB40CBA0CBB0CC50CC90CCE-0CD40CD7-0CDD0CDF0CE40CE50CF00CF3-0D010D040D0D0D110D290D3A-0D3C0D450D490D4E-0D560D58-0D5F0D640D650D76-0D780D800D810D840D97-0D990DB20DBC0DBE0DBF0DC7-0DC90DCB-0DCE0DD50DD70DE0-0DF10DF5-0E000E3B-0E3E0E5C-0E800E830E850E860E890E8B0E8C0E8E-0E930E980EA00EA40EA60EA80EA90EAC0EBA0EBE0EBF0EC50EC70ECE0ECF0EDA0EDB0EDE-0EFF0F480F6D-0F700F8C-0F8F0F980FBD0FCD0FD9-0FFF10C6-10CF10FD-10FF1249124E124F12571259125E125F1289128E128F12B112B612B712BF12C112C612C712D7131113161317135B-135E137D-137F139A-139F13F5-13FF169D-169F16F1-16FF170D1715-171F1737-173F1754-175F176D17711774-177F17B417B517DE17DF17EA-17EF17FA-17FF180F181A-181F1878-187F18AB-18AF18F6-18FF191D-191F192C-192F193C-193F1941-1943196E196F1975-197F19AC-19AF19CA-19CF19DB-19DD1A1C1A1D1A5F1A7D1A7E1A8A-1A8F1A9A-1A9F1AAE-1AFF1B4C-1B4F1B7D-1B7F1BAB-1BAD1BBA-1BFF1C38-1C3A1C4A-1C4C1C80-1CCF1CF3-1CFF1DE7-1DFC1F161F171F1E1F1F1F461F471F4E1F4F1F581F5A1F5C1F5E1F7E1F7F1FB51FC51FD41FD51FDC1FF01FF11FF51FFF200B-200F202A-202E2060-206F20722073208F2095-209F20B9-20CF20F1-20FF218A-218F23E9-23FF2427-243F244B-245F26CE26E226E4-26E727002705270A270B2728274C274E2753-2755275F27602795-279727B027BF27CB27CD-27CF2B4D-2B4F2B5A-2BFF2C2F2C5F2CF2-2CF82D26-2D2F2D66-2D6E2D70-2D7F2D97-2D9F2DA72DAF2DB72DBF2DC72DCF2DD72DDF2E32-2E7F2E9A2EF4-2EFF2FD6-2FEF2FFC-2FFF3040309730983100-3104312E-3130318F31B8-31BF31E4-31EF321F32FF4DB6-4DBF9FCC-9FFFA48D-A48FA4C7-A4CFA62C-A63FA660A661A674-A67BA698-A69FA6F8-A6FFA78D-A7FAA82C-A82FA83A-A83FA878-A87FA8C5-A8CDA8DA-A8DFA8FC-A8FFA954-A95EA97D-A97FA9CEA9DA-A9DDA9E0-A9FFAA37-AA3FAA4EAA4FAA5AAA5BAA7C-AA7FAAC3-AADAAAE0-ABBFABEEABEFABFA-ABFFD7A4-D7AFD7C7-D7CAD7FC-F8FFFA2EFA2FFA6EFA6FFADA-FAFFFB07-FB12FB18-FB1CFB37FB3DFB3FFB42FB45FBB2-FBD2FD40-FD4FFD90FD91FDC8-FDEFFDFEFDFFFE1A-FE1FFE27-FE2FFE53FE67FE6C-FE6FFE75FEFD-FF00FFBF-FFC1FFC8FFC9FFD0FFD1FFD8FFD9FFDD-FFDFFFE7FFEF-FFFBFFFEFFFF",
Cc:"0000-001F007F-009F",Cf:"00AD0600-060306DD070F17B417B5200B-200F202A-202E2060-2064206A-206FFEFFFFF9-FFFB",Co:"E000-F8FF",Cs:"D800-DFFF",Cn:"03780379037F-0383038B038D03A20526-05300557055805600588058B-059005C8-05CF05EB-05EF05F5-05FF06040605061C061D0620065F070E074B074C07B2-07BF07FB-07FF082E082F083F-08FF093A093B094F095609570973-097809800984098D098E0991099209A909B109B3-09B509BA09BB09C509C609C909CA09CF-09D609D8-09DB09DE09E409E509FC-0A000A040A0B-0A0E0A110A120A290A310A340A370A3A0A3B0A3D0A43-0A460A490A4A0A4E-0A500A52-0A580A5D0A5F-0A650A76-0A800A840A8E0A920AA90AB10AB40ABA0ABB0AC60ACA0ACE0ACF0AD1-0ADF0AE40AE50AF00AF2-0B000B040B0D0B0E0B110B120B290B310B340B3A0B3B0B450B460B490B4A0B4E-0B550B58-0B5B0B5E0B640B650B72-0B810B840B8B-0B8D0B910B96-0B980B9B0B9D0BA0-0BA20BA5-0BA70BAB-0BAD0BBA-0BBD0BC3-0BC50BC90BCE0BCF0BD1-0BD60BD8-0BE50BFB-0C000C040C0D0C110C290C340C3A-0C3C0C450C490C4E-0C540C570C5A-0C5F0C640C650C70-0C770C800C810C840C8D0C910CA90CB40CBA0CBB0CC50CC90CCE-0CD40CD7-0CDD0CDF0CE40CE50CF00CF3-0D010D040D0D0D110D290D3A-0D3C0D450D490D4E-0D560D58-0D5F0D640D650D76-0D780D800D810D840D97-0D990DB20DBC0DBE0DBF0DC7-0DC90DCB-0DCE0DD50DD70DE0-0DF10DF5-0E000E3B-0E3E0E5C-0E800E830E850E860E890E8B0E8C0E8E-0E930E980EA00EA40EA60EA80EA90EAC0EBA0EBE0EBF0EC50EC70ECE0ECF0EDA0EDB0EDE-0EFF0F480F6D-0F700F8C-0F8F0F980FBD0FCD0FD9-0FFF10C6-10CF10FD-10FF1249124E124F12571259125E125F1289128E128F12B112B612B712BF12C112C612C712D7131113161317135B-135E137D-137F139A-139F13F5-13FF169D-169F16F1-16FF170D1715-171F1737-173F1754-175F176D17711774-177F17DE17DF17EA-17EF17FA-17FF180F181A-181F1878-187F18AB-18AF18F6-18FF191D-191F192C-192F193C-193F1941-1943196E196F1975-197F19AC-19AF19CA-19CF19DB-19DD1A1C1A1D1A5F1A7D1A7E1A8A-1A8F1A9A-1A9F1AAE-1AFF1B4C-1B4F1B7D-1B7F1BAB-1BAD1BBA-1BFF1C38-1C3A1C4A-1C4C1C80-1CCF1CF3-1CFF1DE7-1DFC1F161F171F1E1F1F1F461F471F4E1F4F1F581F5A1F5C1F5E1F7E1F7F1FB51FC51FD41FD51FDC1FF01FF11FF51FFF2065-206920722073208F2095-209F20B9-20CF20F1-20FF218A-218F23E9-23FF2427-243F244B-245F26CE26E226E4-26E727002705270A270B2728274C274E2753-2755275F27602795-279727B027BF27CB27CD-27CF2B4D-2B4F2B5A-2BFF2C2F2C5F2CF2-2CF82D26-2D2F2D66-2D6E2D70-2D7F2D97-2D9F2DA72DAF2DB72DBF2DC72DCF2DD72DDF2E32-2E7F2E9A2EF4-2EFF2FD6-2FEF2FFC-2FFF3040309730983100-3104312E-3130318F31B8-31BF31E4-31EF321F32FF4DB6-4DBF9FCC-9FFFA48D-A48FA4C7-A4CFA62C-A63FA660A661A674-A67BA698-A69FA6F8-A6FFA78D-A7FAA82C-A82FA83A-A83FA878-A87FA8C5-A8CDA8DA-A8DFA8FC-A8FFA954-A95EA97D-A97FA9CEA9DA-A9DDA9E0-A9FFAA37-AA3FAA4EAA4FAA5AAA5BAA7C-AA7FAAC3-AADAAAE0-ABBFABEEABEFABFA-ABFFD7A4-D7AFD7C7-D7CAD7FC-D7FFFA2EFA2FFA6EFA6FFADA-FAFFFB07-FB12FB18-FB1CFB37FB3DFB3FFB42FB45FBB2-FBD2FD40-FD4FFD90FD91FDC8-FDEFFDFEFDFFFE1A-FE1FFE27-FE2FFE53FE67FE6C-FE6FFE75FEFDFEFEFF00FFBF-FFC1FFC8FFC9FFD0FFD1FFD8FFD9FFDD-FFDFFFE7FFEF-FFF8FFFEFFFF"};
r=/\w{4}/g;for(var e in f)k.packages[e]=f[e].replace(r,"\\u$&")});
define("ace/token_iterator",["require","exports","module"],function(f,k,r){f=function(e,f,b){this.$session=e;this.$row=f;this.$rowTokens=e.getTokens(f);this.$tokenIndex=(e=e.getTokenAt(f,b))?e.index:-1};(function(){this.stepBackward=function(){for(this.$tokenIndex-=1;0>this.$tokenIndex;){this.$row-=1;if(0>this.$row)return this.$row=0,null;this.$rowTokens=this.$session.getTokens(this.$row);this.$tokenIndex=this.$rowTokens.length-1}return this.$rowTokens[this.$tokenIndex]};this.stepForward=function(){this.$tokenIndex+=
1;for(var e;this.$tokenIndex>=this.$rowTokens.length;){this.$row+=1;e||(e=this.$session.getLength());if(this.$row>=e)return this.$row=e-1,null;this.$rowTokens=this.$session.getTokens(this.$row);this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]};this.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]};this.getCurrentTokenRow=function(){return this.$row};this.getCurrentTokenColumn=function(){var e=this.$rowTokens,f=this.$tokenIndex,b=e[f].start;if(void 0!==b)return b;for(b=
0;0<f;)f-=1,b+=e[f].value.length;return b};this.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}}}).call(f.prototype);k.TokenIterator=f});
define("ace/mode/text","require exports module ace/tokenizer ace/mode/text_highlight_rules ace/mode/behaviour ace/unicode ace/lib/lang ace/token_iterator ace/range".split(" "),function(f,k,r){var e=f("../tokenizer").Tokenizer,m=f("./text_highlight_rules").TextHighlightRules,b=f("./behaviour").Behaviour,c=f("../unicode"),a=f("../lib/lang"),d=f("../token_iterator").TokenIterator,g=f("../range").Range;f=function(){this.HighlightRules=m;this.$behaviour=new b};(function(){this.tokenRe=new RegExp("^["+
c.packages.L+c.packages.Mn+c.packages.Mc+c.packages.Nd+c.packages.Pc+"\\$_]+","g");this.nonTokenRe=new RegExp("^(?:[^"+c.packages.L+c.packages.Mn+c.packages.Mc+c.packages.Nd+c.packages.Pc+"\\$_]|\\s])+","g");this.getTokenizer=function(){this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules,this.$tokenizer=new e(this.$highlightRules.getRules()));return this.$tokenizer};this.blockComment=this.lineCommentStart="";this.toggleCommentLines=function(d,b,c,g){function e(a){for(var d=
c;d<=g;d++)a(f.getLine(d),d)}var f=b.doc,s=!0,q=!0,v=Infinity,u=b.getTabSize();d=!1;if(this.lineCommentStart){Array.isArray(this.lineCommentStart)?(z=this.lineCommentStart.map(a.escapeRegExp).join("|"),A=this.lineCommentStart[0]):(z=a.escapeRegExp(this.lineCommentStart),A=this.lineCommentStart);z=new RegExp("^(\\s*)(?:"+z+") ?");d=b.getUseSoftTabs();var x=function(a,d){var b=a.match(z);if(b){var c=b[1].length,g=b[0].length;y(a,c,g)||" "!=b[0][g-1]||g--;f.removeInLine(d,c,g)}},B=A+" ",m=function(a,
d){if(!s||/\S/.test(a))y(a,v,v)?f.insertInLine({row:d,column:v},B):f.insertInLine({row:d,column:v},A)},k=function(a,d){return z.test(a)},y=function(a,d,b){for(var c=0;d--&&" "==a.charAt(d);)c++;if(0!=c%u)return!1;for(c=0;" "==a.charAt(b++);)c++;return 2<u?c%u!=u-1:0==c%u}}else{if(!this.blockComment)return!1;var A=this.blockComment.start,r=this.blockComment.end,z=new RegExp("^(\\s*)(?:"+a.escapeRegExp(A)+")"),F=new RegExp("(?:"+a.escapeRegExp(r)+")\\s*$"),m=function(a,d){k(a,d)||s&&!/\S/.test(a)||
(f.insertInLine({row:d,column:a.length},r),f.insertInLine({row:d,column:v},A))},x=function(a,d){var b;(b=a.match(F))&&f.removeInLine(d,a.length-b[0].length,a.length);(b=a.match(z))&&f.removeInLine(d,b[1].length,b[0].length)},k=function(a,d){if(z.test(a))return!0;for(var c=b.getTokens(d),g=0;g<c.length;g++)if("comment"===c[g].type)return!0}}var w=Infinity;e(function(a,d){var b=a.search(/\S/);-1!==b?(b<v&&(v=b),q&&!k(a,d)&&(q=!1)):w>a.length&&(w=a.length)});Infinity==v&&(v=w,q=s=!1);d&&0!=v%u&&(v=Math.floor(v/
u)*u);e(q?x:m)};this.toggleBlockComment=function(a,b,c,l){if(a=this.blockComment){!a.start&&a[0]&&(a=a[0]);var e=new d(b,l.row,l.column),f=e.getCurrentToken(),s=b.selection.toOrientedRange(),q,v;if(f&&/comment/.test(f.type)){for(var u,x;f&&/comment/.test(f.type);){f=f.value.indexOf(a.start);if(-1!=f){c=e.getCurrentTokenRow();e=e.getCurrentTokenColumn()+f;u=new g(c,e,c,e+a.start.length);break}f=e.stepBackward()}e=new d(b,l.row,l.column);for(f=e.getCurrentToken();f&&/comment/.test(f.type);){f=f.value.indexOf(a.end);
if(-1!=f){c=e.getCurrentTokenRow();e=e.getCurrentTokenColumn()+f;x=new g(c,e,c,e+a.end.length);break}f=e.stepForward()}x&&b.remove(x);u&&(b.remove(u),q=u.start.row,v=-a.start.length)}else v=a.start.length,q=c.start.row,b.insert(c.end,a.end),b.insert(c.start,a.start);s.start.row==q&&(s.start.column+=v);s.end.row==q&&(s.end.column+=v);b.selection.fromOrientedRange(s)}};this.getNextLineIndent=function(a,d,b){return this.$getIndent(d)};this.checkOutdent=function(a,d,b){return!1};this.autoOutdent=function(a,
d,b){};this.$getIndent=function(a){return a.match(/^\s*/)[0]};this.createWorker=function(a){return null};this.createModeDelegates=function(a){this.$embeds=[];this.$modes={};for(var d in a)a[d]&&(this.$embeds.push(d),this.$modes[d]=new a[d]);var b="toggleBlockComment toggleCommentLines getNextLineIndent checkOutdent autoOutdent transformAction getCompletions".split(" ");for(d=0;d<b.length;d++)(function(a){var c=b[d],g=a[c];a[b[d]]=function(){return this.$delegator(c,arguments,g)}})(this)};this.$delegator=
function(a,d,b){var c=d[0];"string"!=typeof c&&(c=c[0]);for(var g=0;g<this.$embeds.length;g++)if(this.$modes[this.$embeds[g]]){var e=c.split(this.$embeds[g]);if(!e[0]&&e[1])return d[0]=e[1],b=this.$modes[this.$embeds[g]],b[a].apply(b,d)}a=b.apply(this,d);return b?a:void 0};this.transformAction=function(a,d,b,c,g){if(this.$behaviour){var e=this.$behaviour.getBehaviours(),s;for(s in e)if(e[s][d]){var q=e[s][d].apply(this,arguments);if(q)return q}}};this.getKeywords=function(a){if(!this.completionKeywords){var d=
this.$tokenizer.rules,b=[],c;for(c in d)for(var g=d[c],e=0,s=g.length;e<s;e++)if("string"===typeof g[e].token)/keyword|support|storage/.test(g[e].token)&&b.push(g[e].regex);else if("object"===typeof g[e].token)for(var q=0,f=g[e].token.length;q<f;q++)/keyword|support|storage/.test(g[e].token[q])&&(c=g[e].regex.match(/\(.+?\)/g)[q],b.push(c.substr(1,c.length-2)));this.completionKeywords=b}return a?b.concat(this.$keywordList||[]):this.$keywordList};this.$createKeywordList=function(){this.$highlightRules||
this.getTokenizer();return this.$keywordList=this.$highlightRules.$keywordList||[]};this.getCompletions=function(a,d,b,c){return(this.$keywordList||this.$createKeywordList()).map(function(a){return{name:a,value:a,score:0,meta:"keyword"}})};this.$id="ace/mode/text"}).call(f.prototype);k.Mode=f});
define("ace/apply_delta",["require","exports","module"],function(f,k,r){k.applyDelta=function(e,f,b){b=f.start.row;var c=f.start.column,a=e[b]||"";switch(f.action){case "insert":if(1===f.lines.length)e[b]=a.substring(0,c)+f.lines[0]+a.substring(c);else{var d=[b,1].concat(f.lines);e.splice.apply(e,d);e[b]=a.substring(0,c)+e[b];e[b+f.lines.length-1]+=a.substring(c)}break;case "remove":d=f.end.column,f=f.end.row,b===f?e[b]=a.substring(0,c)+a.substring(d):e.splice(b,f-b+1,a.substring(0,c)+e[f].substring(d))}}});
define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(f,k,r){var e=f("./lib/oop"),m=f("./lib/event_emitter").EventEmitter;f=k.Anchor=function(b,c,a){this.$onChange=this.onChange.bind(this);this.attach(b);"undefined"==typeof a?this.setPosition(c.row,c.column):this.setPosition(c,a)};(function(){function b(b,a,d){d=d?b.column<=a.column:b.column<a.column;return b.row<a.row||b.row==a.row&&d}e.implement(this,m);this.getPosition=function(){return this.$clipPositionToDocument(this.row,
this.column)};this.getDocument=function(){return this.document};this.$insertRight=!1;this.onChange=function(c){var a,d;if(!(c.start.row==c.end.row&&c.start.row!=this.row||c.start.row>this.row)){d={row:this.row,column:this.column};a=this.$insertRight;var g="insert"==c.action,n=(g?1:-1)*(c.end.row-c.start.row),h=(g?1:-1)*(c.end.column-c.start.column),e=c.start;c=g?e:c.end;b(d,e,a)?(a=d.row,d=d.column):b(c,d,!a)?(a=d.row+n,d=d.column+(d.row==c.row?h:0)):(a=e.row,d=e.column);this.setPosition(a,d,!0)}};
this.setPosition=function(b,a,d){b=d?{row:b,column:a}:this.$clipPositionToDocument(b,a);if(this.row!=b.row||this.column!=b.column)a={row:this.row,column:this.column},this.row=b.row,this.column=b.column,this._signal("change",{old:a,value:b})};this.detach=function(){this.document.removeEventListener("change",this.$onChange)};this.attach=function(b){this.document=b||this.document;this.document.on("change",this.$onChange)};this.$clipPositionToDocument=function(b,a){var d={};b>=this.document.getLength()?
(d.row=Math.max(0,this.document.getLength()-1),d.column=this.document.getLine(d.row).length):0>b?(d.row=0,d.column=0):(d.row=b,d.column=Math.min(this.document.getLine(d.row).length,Math.max(0,a)));0>a&&(d.column=0);return d}}).call(f.prototype)});
define("ace/document","require exports module ace/lib/oop ace/apply_delta ace/lib/event_emitter ace/range ace/anchor".split(" "),function(f,k,r){var e=f("./lib/oop"),m=f("./apply_delta").applyDelta,b=f("./lib/event_emitter").EventEmitter,c=f("./range").Range,a=f("./anchor").Anchor;f=function(a){this.$lines=[""];0===a.length?this.$lines=[""]:Array.isArray(a)?this.insertMergedLines({row:0,column:0},a):this.insert({row:0,column:0},a)};(function(){e.implement(this,b);this.setValue=function(a){var b=this.getLength()-
1;this.remove(new c(0,0,b,this.getLine(b).length));this.insert({row:0,column:0},a)};this.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())};this.createAnchor=function(d,b){return new a(this,d,b)};0==="aaa".split(/a/).length?this.$split=function(a){return a.replace(/\r\n|\r/g,"\n").split("\n")}:this.$split=function(a){return a.split(/\r\n|\r|\n/)};this.$detectNewLine=function(a){this.$autoNewLine=(a=a.match(/^.*?(\r\n|\r|\n)/m))?a[1]:"\n";this._signal("changeNewLineMode")};
this.getNewLineCharacter=function(){switch(this.$newLineMode){case "windows":return"\r\n";case "unix":return"\n";default:return this.$autoNewLine||"\n"}};this.$autoNewLine="";this.$newLineMode="auto";this.setNewLineMode=function(a){this.$newLineMode!==a&&(this.$newLineMode=a,this._signal("changeNewLineMode"))};this.getNewLineMode=function(){return this.$newLineMode};this.isNewLine=function(a){return"\r\n"==a||"\r"==a||"\n"==a};this.getLine=function(a){return this.$lines[a]||""};this.getLines=function(a,
b){return this.$lines.slice(a,b+1)};this.getAllLines=function(){return this.getLines(0,this.getLength())};this.getLength=function(){return this.$lines.length};this.getTextRange=function(a){return this.getLinesForRange(a).join(this.getNewLineCharacter())};this.getLinesForRange=function(a){var b;if(a.start.row===a.end.row)b=[this.getLine(a.start.row).substring(a.start.column,a.end.column)];else{b=this.getLines(a.start.row,a.end.row);b[0]=(b[0]||"").substring(a.start.column);var c=b.length-1;a.end.row-
a.start.row==c&&(b[c]=b[c].substring(0,a.end.column))}return b};this.insertLines=function(a,b){console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");return this.insertFullLines(a,b)};this.removeLines=function(a,b){console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");return this.removeFullLines(a,b)};this.insertNewLine=function(a){console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
return this.insertMergedLines(a,["",""])};this.insert=function(a,b){1>=this.getLength()&&this.$detectNewLine(b);return this.insertMergedLines(a,this.$split(b))};this.insertInLine=function(a,b){var c=this.clippedPos(a.row,a.column),h=this.pos(a.row,a.column+b.length);this.applyDelta({start:c,end:h,action:"insert",lines:[b]},!0);return this.clonePos(h)};this.clippedPos=function(a,b){var c=this.getLength();void 0===a?a=c:0>a?a=0:a>=c&&(a=c-1,b=void 0);c=this.getLine(a);void 0==b&&(b=c.length);b=Math.min(Math.max(b,
0),c.length);return{row:a,column:b}};this.clonePos=function(a){return{row:a.row,column:a.column}};this.pos=function(a,b){return{row:a,column:b}};this.$clipPosition=function(a){var b=this.getLength();a.row>=b?(a.row=Math.max(0,b-1),a.column=this.getLine(b-1).length):(a.row=Math.max(0,a.row),a.column=Math.min(Math.max(a.column,0),this.getLine(a.row).length));return a};this.insertFullLines=function(a,b){a=Math.min(Math.max(a,0),this.getLength());var c=0;a<this.getLength()?(b=b.concat([""]),c=0):(b=[""].concat(b),
a--,c=this.$lines[a].length);this.insertMergedLines({row:a,column:c},b)};this.insertMergedLines=function(a,b){var c=this.clippedPos(a.row,a.column),h={row:c.row+b.length-1,column:(1==b.length?c.column:0)+b[b.length-1].length};this.applyDelta({start:c,end:h,action:"insert",lines:b});return this.clonePos(h)};this.remove=function(a){var b=this.clippedPos(a.start.row,a.start.column);a=this.clippedPos(a.end.row,a.end.column);this.applyDelta({start:b,end:a,action:"remove",lines:this.getLinesForRange({start:b,
end:a})});return this.clonePos(b)};this.removeInLine=function(a,b,c){b=this.clippedPos(a,b);a=this.clippedPos(a,c);this.applyDelta({start:b,end:a,action:"remove",lines:this.getLinesForRange({start:b,end:a})},!0);return this.clonePos(b)};this.removeFullLines=function(a,b){a=Math.min(Math.max(0,a),this.getLength()-1);b=Math.min(Math.max(0,b),this.getLength()-1);var n=b==this.getLength()-1&&0<a,h=b<this.getLength()-1,e=n?a-1:a,n=n?this.getLine(e).length:0,l=h?b+1:b,h=h?0:this.getLine(l).length,e=new c(e,
n,l,h),h=this.$lines.slice(a,b+1);this.applyDelta({start:e.start,end:e.end,action:"remove",lines:this.getLinesForRange(e)});return h};this.removeNewLine=function(a){a<this.getLength()-1&&0<=a&&this.applyDelta({start:this.pos(a,this.getLine(a).length),end:this.pos(a+1,0),action:"remove",lines:["",""]})};this.replace=function(a,b){!a instanceof c&&(a=c.fromPoints(a.start,a.end));if(0===b.length&&a.isEmpty())return a.start;if(b==this.getTextRange(a))return a.end;this.remove(a);return b?this.insert(a.start,
b):a.start};this.applyDeltas=function(a){for(var b=0;b<a.length;b++)this.applyDelta(a[b])};this.revertDeltas=function(a){for(var b=a.length-1;0<=b;b--)this.revertDelta(a[b])};this.applyDelta=function(a,b){var n="insert"==a.action;(n?1>=a.lines.length&&!a.lines[0]:!c.comparePoints(a.start,a.end))||(n&&2E4<a.lines.length&&this.$splitAndapplyLargeDelta(a,2E4),m(this.$lines,a,b),this._signal("change",a))};this.$splitAndapplyLargeDelta=function(a,b){var c=a.lines,h=c.length,e=a.start.row,l=a.start.column,
f=0,m=0;do{var f=m,m=m+(b-1),s=c.slice(f,m);if(m>h){a.lines=s;a.start.row=e+f;a.start.column=l;break}s.push("");this.applyDelta({start:this.pos(e+f,l),end:this.pos(e+m,l=0),action:a.action,lines:s},!0)}while(1)};this.revertDelta=function(a){this.applyDelta({start:this.clonePos(a.start),end:this.clonePos(a.end),action:"insert"==a.action?"remove":"insert",lines:a.lines.slice()})};this.indexToPosition=function(a,b){for(var c=this.$lines||this.getAllLines(),h=this.getNewLineCharacter().length,e=b||0,
l=c.length;e<l;e++)if(a-=c[e].length+h,0>a)return{row:e,column:a+c[e].length+h};return{row:l-1,column:c[l-1].length}};this.positionToIndex=function(a,b){for(var c=this.$lines||this.getAllLines(),h=this.getNewLineCharacter().length,e=0,l=Math.min(a.row,c.length),f=b||0;f<l;++f)e+=c[f].length+h;return e+a.column}}).call(f.prototype);k.Document=f});
define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(f,k,r){var e=f("./lib/oop"),m=f("./lib/event_emitter").EventEmitter;f=function(b,c){this.running=!1;this.lines=[];this.states=[];this.currentLine=0;this.tokenizer=b;var a=this;this.$worker=function(){if(a.running){for(var b=new Date,c=a.currentLine,n=-1,h=a.doc,e=c;a.lines[c];)c++;var h=h.getLength(),l=0;for(a.running=!1;c<h;){a.$tokenizeRow(c);n=c;do c++;while(a.lines[c]);l++;if(0===l%
5&&20<new Date-b){a.running=setTimeout(a.$worker,20);break}}a.currentLine=c;e<=n&&a.fireUpdateEvent(e,n)}}};(function(){e.implement(this,m);this.setTokenizer=function(b){this.tokenizer=b;this.lines=[];this.states=[];this.start(0)};this.setDocument=function(b){this.doc=b;this.lines=[];this.states=[];this.stop()};this.fireUpdateEvent=function(b,c){this._signal("update",{data:{first:b,last:c}})};this.start=function(b){this.currentLine=Math.min(b||0,this.currentLine,this.doc.getLength());this.lines.splice(this.currentLine,
this.lines.length);this.states.splice(this.currentLine,this.states.length);this.stop();this.running=setTimeout(this.$worker,700)};this.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))};this.$updateOnChange=function(b){var c=b.start.row,a=b.end.row-c;0===a?this.lines[c]=null:"remove"==b.action?(this.lines.splice(c,a+1,null),this.states.splice(c,a+1,null)):(b=Array(a+1),b.unshift(c,1),this.lines.splice.apply(this.lines,b),this.states.splice.apply(this.states,b));this.currentLine=
Math.min(c,this.currentLine,this.doc.getLength());this.stop()};this.stop=function(){this.running&&clearTimeout(this.running);this.running=!1};this.getTokens=function(b){return this.lines[b]||this.$tokenizeRow(b)};this.getState=function(b){this.currentLine==b&&this.$tokenizeRow(b);return this.states[b]||"start"};this.$tokenizeRow=function(b){var c=this.doc.getLine(b),c=this.tokenizer.getLineTokens(c,this.states[b-1],b);this.states[b]+""!==c.state+""?(this.states[b]=c.state,this.lines[b+1]=null,this.currentLine>
b+1&&(this.currentLine=b+1)):this.currentLine==b&&(this.currentLine=b+1);return this.lines[b]=c.tokens}}).call(f.prototype);k.BackgroundTokenizer=f});
define("ace/search_highlight","require exports module ace/lib/lang ace/lib/oop ace/range".split(" "),function(f,k,r){var e=f("./lib/lang");f("./lib/oop");var m=f("./range").Range;f=function(b,c,a){this.setRegexp(b);this.clazz=c;this.type=a||"text"};(function(){this.MAX_RANGES=500;this.setRegexp=function(b){this.regExp+""!=b+""&&(this.regExp=b,this.cache=[])};this.update=function(b,c,a,d){if(this.regExp)for(var g=d.lastRow,n=d.firstRow;n<=g;n++){var h=this.cache[n];null==h&&(h=e.getMatchOffsets(a.getLine(n),
this.regExp),h.length>this.MAX_RANGES&&(h=h.slice(0,this.MAX_RANGES)),h=h.map(function(a){return new m(n,a.offset,n,a.offset+a.length)}),this.cache[n]=h.length?h:"");for(var f=h.length;f--;)c.drawSingleLineMarker(b,h[f].toScreenRange(a),this.clazz,d)}}}).call(f.prototype);k.SearchHighlight=f});
define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(f,k,r){function e(b,c){this.foldData=b;Array.isArray(c)?this.folds=c:c=this.folds=[c];var a=c[c.length-1];this.range=new m(c[0].start.row,c[0].start.column,a.end.row,a.end.column);this.start=this.range.start;this.end=this.range.end;this.folds.forEach(function(a){a.setFoldLine(this)},this)}var m=f("../range").Range;(function(){this.shiftRow=function(b){this.start.row+=b;this.end.row+=b;this.folds.forEach(function(c){c.start.row+=
b;c.end.row+=b})};this.addFold=function(b){if(b.sameRow){if(b.start.row<this.startRow||b.endRow>this.endRow)throw Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(b);this.folds.sort(function(b,a){return-b.range.compareEnd(a.start.row,a.start.column)});0<this.range.compareEnd(b.start.row,b.start.column)?(this.end.row=b.end.row,this.end.column=b.end.column):0>this.range.compareStart(b.end.row,b.end.column)&&(this.start.row=b.start.row,this.start.column=b.start.column)}else if(b.start.row==
this.end.row)this.folds.push(b),this.end.row=b.end.row,this.end.column=b.end.column;else if(b.end.row==this.start.row)this.folds.unshift(b),this.start.row=b.start.row,this.start.column=b.start.column;else throw Error("Trying to add fold to FoldRow that doesn't have a matching row");b.foldLine=this};this.containsRow=function(b){return b>=this.start.row&&b<=this.end.row};this.walk=function(b,c,a){var d=0,g=this.folds,n,h,e;e=!0;null==c&&(c=this.end.row,a=this.end.column);for(var l=0;l<g.length;l++){n=
g[l];h=n.range.compareStart(c,a);if(-1==h){b(null,c,a,d,e);return}e=b(null,n.start.row,n.start.column,d,e);if((e=!e&&b(n.placeholder,n.start.row,n.start.column,d))||0===h)return;e=!n.sameRow;d=n.end.column}b(null,c,a,d,e)};this.getNextFoldTo=function(b,c){for(var a,d,g=0;g<this.folds.length;g++){a=this.folds[g];d=a.range.compareEnd(b,c);if(-1==d)return{fold:a,kind:"after"};if(0===d)return{fold:a,kind:"inside"}}return null};this.addRemoveChars=function(b,c,a){var d=this.getNextFoldTo(b,c),g;if(d)if(g=
d.fold,"inside"==d.kind&&g.start.column!=c&&g.start.row!=b)window.console&&window.console.log(b,c,g);else if(g.start.row==b){b=this.folds;c=b.indexOf(g);0===c&&(this.start.column+=a);for(c;c<b.length;c++){g=b[c];g.start.column+=a;if(!g.sameRow)return;g.end.column+=a}this.end.column+=a}};this.split=function(b,c){var a=this.getNextFoldTo(b,c);if(!a||"inside"==a.kind)return null;var d=this.folds,g=this.foldData,a=d.indexOf(a.fold),n=d[a-1];this.end.row=n.end.row;this.end.column=n.end.column;d=d.splice(a,
d.length-a);d=new e(g,d);g.splice(g.indexOf(this)+1,0,d);return d};this.merge=function(b){for(var c=b.folds,a=0;a<c.length;a++)this.addFold(c[a]);c=this.foldData;c.splice(c.indexOf(b),1)};this.toString=function(){var b=[this.range.toString()+": ["];this.folds.forEach(function(c){b.push("  "+c.toString())});b.push("]");return b.join("\n")};this.idxToPosition=function(b){for(var c=0,a=0;a<this.folds.length;a++){var d=this.folds[a];b-=d.start.column-c;if(0>b)return{row:d.start.row,column:d.start.column+
b};b-=d.placeholder.length;if(0>b)return d.start;c=d.end.column}return{row:this.end.row,column:this.end.column+b}}}).call(e.prototype);k.FoldLine=e});
define("ace/range_list",["require","exports","module","ace/range"],function(f,k,r){var e=f("./range").Range.comparePoints;f=function(){this.ranges=[]};(function(){this.comparePoints=e;this.pointIndex=function(f,b,c){var a=this.ranges;for(c=c||0;c<a.length;c++){var d=a[c],g=e(f,d.end);if(!(0<g)){f=e(f,d.start);if(0===g)return b&&0!==f?-c-2:c;if(0<f||0===f&&!b)return c;break}}return-c-1};this.add=function(e){var b=!e.isEmpty(),c=this.pointIndex(e.start,b);0>c&&(c=-c-1);b=this.pointIndex(e.end,b,c);
0>b?b=-b-1:b++;return this.ranges.splice(c,b-c,e)};this.addList=function(e){for(var b=[],c=e.length;c--;)b.push.call(b,this.add(e[c]));return b};this.substractPoint=function(e){e=this.pointIndex(e);if(0<=e)return this.ranges.splice(e,1)};this.merge=function(){for(var f=[],b=this.ranges,b=b.sort(function(a,b){return e(a.start,b.start)}),c=b[0],a,d=1;d<b.length;d++){a=c;var c=b[d],g=e(a.end,c.start);0>g||0==g&&!a.isEmpty()&&!c.isEmpty()||(0>e(a.end,c.end)&&(a.end.row=c.end.row,a.end.column=c.end.column),
b.splice(d,1),f.push(c),c=a,d--)}this.ranges=b;return f};this.contains=function(e,b){return 0<=this.pointIndex({row:e,column:b})};this.containsPoint=function(e){return 0<=this.pointIndex(e)};this.rangeAtPoint=function(e){e=this.pointIndex(e);if(0<=e)return this.ranges[e]};this.clipRows=function(e,b){var c=this.ranges;if(c[0].start.row>b||c[c.length-1].start.row<e)return[];var a=this.pointIndex({row:e,column:0});0>a&&(a=-a-1);var d=this.pointIndex({row:b,column:0},a);0>d&&(d=-d-1);for(var g=[];a<d;a++)g.push(c[a]);
return g};this.removeAll=function(){return this.ranges.splice(0,this.ranges.length)};this.attach=function(e){this.session&&this.detach();this.session=e;this.onChange=this.$onChange.bind(this);this.session.on("change",this.onChange)};this.detach=function(){this.session&&(this.session.removeListener("change",this.onChange),this.session=null)};this.$onChange=function(e){if("insert"==e.action)var b=e.start,c=e.end;else c=e.start,b=e.end;e=b.row;for(var a=c.row-e,c=-b.column+c.column,d=this.ranges,g=0,
n=d.length;g<n;g++){var h=d[g];if(!(h.end.row<e)){if(h.start.row>e)break;h.start.row==e&&h.start.column>=b.column&&(h.start.column!=b.column||!this.$insertRight)&&(h.start.column+=c,h.start.row+=a);h.end.row==e&&h.end.column>=b.column&&(h.end.column!=b.column||!this.$insertRight)&&(h.end.column==b.column&&0<c&&g<n-1&&h.end.column>h.start.column&&h.end.column==d[g+1].start.column&&(h.end.column-=c),h.end.column+=c,h.end.row+=a)}}if(0!=a&&g<n)for(;g<n;g++)h=d[g],h.start.row+=a,h.end.row+=a}}).call(f.prototype);
k.RangeList=f});
define("ace/edit_session/fold","require exports module ace/range ace/range_list ace/lib/oop".split(" "),function(f,k,r){function e(b,a){b.row-=a.row;0==b.row&&(b.column-=a.column)}function m(b,a){0==b.row&&(b.column+=a.column);b.row+=a.row}f("../range");r=f("../range_list").RangeList;f=f("../lib/oop");var b=k.Fold=function(b,a){this.foldLine=null;this.placeholder=a;this.range=b;this.start=b.start;this.end=b.end;this.sameRow=b.start.row==b.end.row;this.subFolds=this.ranges=[]};f.inherits(b,r);(function(){this.toString=
function(){return'"'+this.placeholder+'" '+this.range.toString()};this.setFoldLine=function(b){this.foldLine=b;this.subFolds.forEach(function(a){a.setFoldLine(b)})};this.clone=function(){var c=this.range.clone(),a=new b(c,this.placeholder);this.subFolds.forEach(function(b){a.subFolds.push(b.clone())});a.collapseChildren=this.collapseChildren;return a};this.addSubFold=function(b){if(!this.range.isEqual(b)){if(!this.range.containsRange(b))throw Error("A fold can't intersect already existing fold"+b.range+
this.range);var a=this.start;e(b.start,a);e(b.end,a);for(var d=b.start.row,g=b.start.column,a=0,n=-1;a<this.subFolds.length&&(n=this.subFolds[a].range.compare(d,g),1==n);a++);d=this.subFolds[a];if(0==n)return d.addSubFold(b);for(var d=b.range.end.row,g=b.range.end.column,h=a,n=-1;h<this.subFolds.length&&(n=this.subFolds[h].range.compare(d,g),1==n);h++);if(0==n)throw Error("A fold can't intersect already existing fold"+b.range+this.range);this.subFolds.splice(a,h-a,b);b.setFoldLine(this.foldLine);
return b}};this.restoreRange=function(b){var a=this.start;m(b.start,a);m(b.end,a)}}).call(b.prototype)});
define("ace/edit_session/folding","require exports module ace/range ace/edit_session/fold_line ace/edit_session/fold ace/token_iterator".split(" "),function(f,k,r){var e=f("../range").Range,m=f("./fold_line").FoldLine,b=f("./fold").Fold,c=f("../token_iterator").TokenIterator;k.Folding=function(){this.getFoldAt=function(a,b,c){var e=this.getFoldLine(a);if(!e)return null;for(var e=e.folds,h=0;h<e.length;h++){var f=e[h];if(!(!f.range.contains(a,b)||1==c&&f.range.isEnd(a,b)||-1==c&&f.range.isStart(a,
b)))return f}};this.getFoldsInRange=function(a){var b=a.start,c=a.end,e=this.$foldData,h=[];b.column+=1;c.column-=1;for(var f=0;f<e.length;f++){var l=e[f].range.compareRange(a);if(2!=l){if(-2==l)break;for(var p=e[f].folds,k=0;k<p.length;k++){var s=p[k],l=s.range.compareRange(a);if(-2==l)break;else if(2==l)continue;else if(42==l)break;h.push(s)}}}b.column-=1;c.column+=1;return h};this.getFoldsInRangeList=function(a){if(Array.isArray(a)){var b=[];a.forEach(function(a){b=b.concat(this.getFoldsInRange(a))},
this)}else b=this.getFoldsInRange(a);return b};this.getAllFolds=function(){for(var a=[],b=this.$foldData,c=0;c<b.length;c++)for(var e=0;e<b[c].folds.length;e++)a.push(b[c].folds[e]);return a};this.getFoldStringAt=function(a,b,c,e){e=e||this.getFoldLine(a);if(!e)return null;for(var h={end:{column:0}},f,l,p=0;p<e.folds.length;p++){l=e.folds[p];var k=l.range.compareEnd(a,b);if(-1==k){f=this.getLine(l.start.row).substring(h.end.column,l.start.column);break}else if(0===k)return null;h=l}f||(f=this.getLine(l.start.row).substring(h.end.column));
return-1==c?f.substring(0,b-h.end.column):1==c?f.substring(b-h.end.column):f};this.getFoldLine=function(a,b){var c=this.$foldData,e=0;b&&(e=c.indexOf(b));-1==e&&(e=0);for(e;e<c.length;e++){var h=c[e];if(h.start.row<=a&&h.end.row>=a)return h;if(h.end.row>a)break}return null};this.getNextFoldLine=function(a,b){var c=this.$foldData,e=0;b&&(e=c.indexOf(b));-1==e&&(e=0);for(e;e<c.length;e++){var h=c[e];if(h.end.row>=a)return h}return null};this.getFoldedRowCount=function(a,b){for(var c=this.$foldData,
e=b-a+1,h=0;h<c.length;h++){var f=c[h],l=f.end.row,f=f.start.row;if(l>=b){f<b&&(e=f>=a?e-(b-f):0);break}else l>=a&&(e=f>=a?e-(l-f):e-(l-a+1))}return e};this.$addFoldLine=function(a){this.$foldData.push(a);this.$foldData.sort(function(a,b){return a.start.row-b.start.row});return a};this.addFold=function(a,d){var c=this.$foldData,e=!1,h;a instanceof b?h=a:(h=new b(d,a),h.collapseChildren=d.collapseChildren);this.$clipRangeToDocument(h.range);var f=h.start.row,l=h.start.column,p=h.end.row,k=h.end.column;
if(!(f<p||f==p&&l<=k-2))throw Error("The range has to be at least 2 characters width");var s=this.getFoldAt(f,l,1),q=this.getFoldAt(p,k,-1);if(s&&q==s)return s.addSubFold(h);s&&!s.range.isStart(f,l)&&this.removeFold(s);q&&!q.range.isEnd(p,k)&&this.removeFold(q);l=this.getFoldsInRange(h.range);0<l.length&&(this.removeFolds(l),l.forEach(function(a){h.addSubFold(a)}));for(l=0;l<c.length;l++){var v=c[l];if(p==v.start.row){v.addFold(h);e=!0;break}else if(f==v.end.row){v.addFold(h);e=!0;if(!h.sameRow&&
(c=c[l+1])&&c.start.row==p){v.merge(c);break}break}else if(p<=v.start.row)break}e||(v=this.$addFoldLine(new m(this.$foldData,h)));this.$useWrapMode?this.$updateWrapData(v.start.row,v.start.row):this.$updateRowLengthCache(v.start.row,v.start.row);this.$modified=!0;this._emit("changeFold",{data:h,action:"add"});return h};this.addFolds=function(a){a.forEach(function(a){this.addFold(a)},this)};this.removeFold=function(a){var b=a.foldLine,c=b.start.row,e=b.end.row,h=this.$foldData,f=b.folds;1==f.length?
h.splice(h.indexOf(b),1):b.range.isEnd(a.end.row,a.end.column)?(f.pop(),b.end.row=f[f.length-1].end.row,b.end.column=f[f.length-1].end.column):b.range.isStart(a.start.row,a.start.column)?(f.shift(),b.start.row=f[0].start.row,b.start.column=f[0].start.column):a.sameRow?f.splice(f.indexOf(a),1):(b=b.split(a.start.row,a.start.column),f=b.folds,f.shift(),b.start.row=f[0].start.row,b.start.column=f[0].start.column);this.$updating||(this.$useWrapMode?this.$updateWrapData(c,e):this.$updateRowLengthCache(c,
e));this.$modified=!0;this._emit("changeFold",{data:a,action:"remove"})};this.removeFolds=function(a){for(var b=[],c=0;c<a.length;c++)b.push(a[c]);b.forEach(function(a){this.removeFold(a)},this);this.$modified=!0};this.expandFold=function(a){this.removeFold(a);a.subFolds.forEach(function(b){a.restoreRange(b);this.addFold(b)},this);0<a.collapseChildren&&this.foldAll(a.start.row+1,a.end.row,a.collapseChildren-1);a.subFolds=[]};this.expandFolds=function(a){a.forEach(function(a){this.expandFold(a)},this)};
this.unfold=function(a,b){var c,n;null==a?(c=new e(0,0,this.getLength(),0),b=!0):c="number"==typeof a?new e(a,0,a,this.getLine(a).length):"row"in a?e.fromPoints(a,a):a;n=this.getFoldsInRangeList(c);if(b)this.removeFolds(n);else for(var h=n;h.length;)this.expandFolds(h),h=this.getFoldsInRangeList(c);if(n.length)return n};this.isRowFolded=function(a,b){return!!this.getFoldLine(a,b)};this.getRowFoldEnd=function(a,b){var c=this.getFoldLine(a,b);return c?c.end.row:a};this.getRowFoldStart=function(a,b){var c=
this.getFoldLine(a,b);return c?c.start.row:a};this.getFoldDisplayLine=function(a,b,c,e,h){null==e&&(e=a.start.row);null==h&&(h=0);null==b&&(b=a.end.row);null==c&&(c=this.getLine(b).length);var f=this.doc,l="";a.walk(function(a,b,d,c){if(!(b<e)){if(b==e){if(d<h)return;c=Math.max(h,c)}l=null!=a?l+a:l+f.getLine(b).substring(c,d)}},b,c);return l};this.getDisplayLine=function(a,b,c,e){var h=this.getFoldLine(a);if(h)return this.getFoldDisplayLine(h,a,b,c,e);a=this.doc.getLine(a);return a.substring(e||0,
b||a.length)};this.$cloneFoldData=function(){var a=[];return a=this.$foldData.map(function(b){b=b.folds.map(function(a){return a.clone()});return new m(a,b)})};this.toggleFold=function(a){var b=this.selection.getRange(),c;if(b.isEmpty()){var e=b.start;if(c=this.getFoldAt(e.row,e.column)){this.expandFold(c);return}(a=this.findMatchingBracket(e))?1==b.comparePoint(a)?b.end=a:(b.start=a,b.start.column++,b.end.column--):(a=this.findMatchingBracket({row:e.row,column:e.column+1}))?(1==b.comparePoint(a)?
b.end=a:b.start=a,b.start.column++):b=this.getCommentFoldRange(e.row,e.column)||b}else{e=this.getFoldsInRange(b);if(a&&e.length){this.expandFolds(e);return}1==e.length&&(c=e[0])}c||(c=this.getFoldAt(b.start.row,b.start.column));if(c&&c.range.toString()==b.toString())this.expandFold(c);else{c="...";if(!b.isMultiLine()){c=this.getTextRange(b);if(4>c.length)return;c=c.trim().substring(0,2)+".."}this.addFold(c,b)}};this.getCommentFoldRange=function(a,b,g){var n=new c(this,a,b),h=n.getCurrentToken();if(h&&
/^comment|string/.test(h.type)){var f=new e,l=new RegExp(h.type.replace(/\..*/,"\\."));if(1!=g){do h=n.stepBackward();while(h&&l.test(h.type));n.stepForward()}f.start.row=n.getCurrentTokenRow();f.start.column=n.getCurrentTokenColumn()+2;n=new c(this,a,b);if(-1!=g){do h=n.stepForward();while(h&&l.test(h.type));h=n.stepBackward()}else h=n.getCurrentToken();f.end.row=n.getCurrentTokenRow();f.end.column=n.getCurrentTokenColumn()+h.value.length-2;return f}};this.foldAll=function(a,b,c){void 0==c&&(c=1E5);
var e=this.foldWidgets;if(e){b=b||this.getLength();for(var h=a=a||0;h<b;h++)if(null==e[h]&&(e[h]=this.getFoldWidget(h)),"start"==e[h]){var f=this.getFoldWidgetRange(h);if(f&&f.isMultiLine()&&f.end.row<=b&&f.start.row>=a){h=f.end.row;try{var l=this.addFold("...",f);l&&(l.collapseChildren=c)}catch(p){}}}}};this.$foldStyles={manual:1,markbegin:1,markbeginend:1};this.$foldStyle="markbegin";this.setFoldStyle=function(a){if(!this.$foldStyles[a])throw Error("invalid fold style: "+a+"["+Object.keys(this.$foldStyles).join(", ")+
"]");this.$foldStyle!=a&&(this.$foldStyle=a,"manual"==a&&this.unfold(),a=this.$foldMode,this.$setFolding(null),this.$setFolding(a))};this.$setFolding=function(a){this.$foldMode!=a&&(this.$foldMode=a,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._emit("changeAnnotation"),a&&"manual"!=this.$foldStyle?(this.foldWidgets=[],this.getFoldWidget=a.getFoldWidget.bind(a,this,this.$foldStyle),this.getFoldWidgetRange=a.getFoldWidgetRange.bind(a,this,
this.$foldStyle),this.$updateFoldWidgets=this.updateFoldWidgets.bind(this),this.$tokenizerUpdateFoldWidgets=this.tokenizerUpdateFoldWidgets.bind(this),this.on("change",this.$updateFoldWidgets),this.on("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets)):this.foldWidgets=null)};this.getParentFoldRangeData=function(a,b){var c=this.foldWidgets;if(!c||b&&c[a])return{};for(var e=a-1,h;0<=e;){var f=c[e];null==f&&(f=c[e]=this.getFoldWidget(e));if("start"==f){var l=this.getFoldWidgetRange(e);h||(h=l);if(l&&
l.end.row>=a)break}e--}return{range:-1!==e&&l,firstRange:h}};this.onFoldWidgetClick=function(a,b){b=b.domEvent;if(!this.$toggleFoldWidget(a,{children:b.shiftKey,all:b.ctrlKey||b.metaKey,siblings:b.altKey})){var c=b.target||b.srcElement;c&&/ace_fold-widget/.test(c.className)&&(c.className+=" ace_invalid")}};this.$toggleFoldWidget=function(a,b){if(this.getFoldWidget){var c=this.getFoldWidget(a),e=this.getLine(a),c="end"===c?-1:1;if(c=this.getFoldAt(a,-1===c?0:e.length,c))b.children||b.all?this.removeFold(c):
this.expandFold(c);else{if((e=this.getFoldWidgetRange(a,!0))&&!e.isMultiLine()&&(c=this.getFoldAt(e.start.row,e.start.column,1))&&e.isEqual(c.range)){this.removeFold(c);return}if(b.siblings){c=this.getParentFoldRangeData(a);if(c.range)var h=c.range.start.row+1,f=c.range.end.row;this.foldAll(h,f,b.all?1E4:0)}else b.children?(f=e?e.end.row:this.getLength(),this.foldAll(a+1,f,b.all?1E4:0)):e&&(b.all&&(e.collapseChildren=1E4),this.addFold("...",e));return e}}};this.toggleFoldWidget=function(a){var b=
this.selection.getCursor().row,b=this.getRowFoldStart(b);a=this.$toggleFoldWidget(b,{});!a&&(a=this.getParentFoldRangeData(b,!0),a=a.range||a.firstRange)&&(b=a.start.row,(b=this.getFoldAt(b,this.getLine(b).length,1))?this.removeFold(b):this.addFold("...",a))};this.updateFoldWidgets=function(a){var b=a.start.row,c=a.end.row-b;0===c?this.foldWidgets[b]=null:"remove"==a.action?this.foldWidgets.splice(b,c+1,null):(a=Array(c+1),a.unshift(b,1),this.foldWidgets.splice.apply(this.foldWidgets,a))};this.tokenizerUpdateFoldWidgets=
function(a){a=a.data;a.first!=a.last&&this.foldWidgets.length>a.first&&this.foldWidgets.splice(a.first,this.foldWidgets.length)}}});
define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(f,k,r){var e=f("../token_iterator").TokenIterator,m=f("../range").Range;k.BracketMatch=function(){this.findMatchingBracket=function(b,c){if(0==b.column)return null;var a=c||this.getLine(b.row).charAt(b.column-1);return""==a?null:(a=a.match(/([\(\[\{])|([\)\]\}])/))?a[1]?this.$findClosingBracket(a[1],b):this.$findOpeningBracket(a[2],b):null};this.getBracketRange=function(b){var c=this.getLine(b.row),
a=!0,d=c.charAt(b.column-1),d=d&&d.match(/([\(\[\{])|([\)\]\}])/);d||(d=c.charAt(b.column),b={row:b.row,column:b.column+1},d=d&&d.match(/([\(\[\{])|([\)\]\}])/),a=!1);if(!d)return null;if(d[1]){c=this.$findClosingBracket(d[1],b);if(!c)return null;b=m.fromPoints(b,c);a||(b.end.column++,b.start.column--);b.cursor=b.end}else{c=this.$findOpeningBracket(d[2],b);if(!c)return null;b=m.fromPoints(c,b);a||(b.start.column++,b.end.column--);b.cursor=b.start}return b};this.$brackets={")":"(","(":")","]":"[",
"[":"]","{":"}","}":"{"};this.$findOpeningBracket=function(b,c,a){var d=this.$brackets[b],g=1,f=new e(this,c.row,c.column),h=f.getCurrentToken();h||(h=f.stepForward());if(h){a||(a=new RegExp("(\\.?"+h.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)")+")+"));c=c.column-f.getCurrentTokenColumn()-2;for(h=h.value;;){for(;0<=c;){var k=h.charAt(c);if(k==d){if(g-=1,0==g)return{row:f.getCurrentTokenRow(),column:c+f.getCurrentTokenColumn()}}else k==b&&(g+=1);c-=
1}do h=f.stepBackward();while(h&&!a.test(h.type));if(null==h)break;h=h.value;c=h.length-1}return null}};this.$findClosingBracket=function(b,c,a){var d=this.$brackets[b],g=1,f=new e(this,c.row,c.column),h=f.getCurrentToken();h||(h=f.stepForward());if(h){a||(a=new RegExp("(\\.?"+h.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)")+")+"));for(c=c.column-f.getCurrentTokenColumn();;){for(var h=h.value,k=h.length;c<k;){var l=h.charAt(c);if(l==d){if(g-=
1,0==g)return{row:f.getCurrentTokenRow(),column:c+f.getCurrentTokenColumn()}}else l==b&&(g+=1);c+=1}do h=f.stepForward();while(h&&!a.test(h.type));if(null==h)break;c=0}return null}}}});
define("ace/edit_session","require exports module ace/lib/oop ace/lib/lang ace/config ace/lib/event_emitter ace/selection ace/mode/text ace/range ace/document ace/background_tokenizer ace/search_highlight ace/edit_session/folding ace/edit_session/bracket_match".split(" "),function(f,k,r){var e=f("./lib/oop"),m=f("./lib/lang"),b=f("./config"),c=f("./lib/event_emitter").EventEmitter,a=f("./selection").Selection,d=f("./mode/text").Mode,g=f("./range").Range,n=f("./document").Document,h=f("./background_tokenizer").BackgroundTokenizer,
t=f("./search_highlight").SearchHighlight;r=function(d,c){this.$breakpoints=[];this.$decorations=[];this.$frontMarkers={};this.$backMarkers={};this.$markerId=1;this.$undoSelect=!0;this.$foldData=[];this.$foldData.toString=function(){return this.join("\n")};this.on("changeFold",this.onChangeFold.bind(this));this.$onChange=this.onChange.bind(this);"object"==typeof d&&d.getLine||(d=new n(d));this.setDocument(d);this.selection=new a(this);b.resetOptions(this);this.setMode(c);b._signal("session",this)};
(function(){function a(b){return 4352>b?!1:4352<=b&&4447>=b||4515<=b&&4519>=b||4602<=b&&4607>=b||9001<=b&&9002>=b||11904<=b&&11929>=b||11931<=b&&12019>=b||12032<=b&&12245>=b||12272<=b&&12283>=b||12288<=b&&12350>=b||12353<=b&&12438>=b||12441<=b&&12543>=b||12549<=b&&12589>=b||12593<=b&&12686>=b||12688<=b&&12730>=b||12736<=b&&12771>=b||12784<=b&&12830>=b||12832<=b&&12871>=b||12880<=b&&13054>=b||13056<=b&&19903>=b||19968<=b&&42124>=b||42128<=b&&42182>=b||43360<=b&&43388>=b||44032<=b&&55203>=b||55216<=
b&&55238>=b||55243<=b&&55291>=b||63744<=b&&64255>=b||65040<=b&&65049>=b||65072<=b&&65106>=b||65108<=b&&65126>=b||65128<=b&&65131>=b||65281<=b&&65376>=b||65504<=b&&65510>=b}e.implement(this,c);this.setDocument=function(a){this.doc&&this.doc.removeListener("change",this.$onChange);this.doc=a;a.on("change",this.$onChange);this.bgTokenizer&&this.bgTokenizer.setDocument(this.getDocument());this.resetCaches()};this.getDocument=function(){return this.doc};this.$resetRowCache=function(a){if(a){var b=this.$docRowCache.length;
a=this.$getRowCacheIndex(this.$docRowCache,a)+1;b>a&&(this.$docRowCache.splice(a,b),this.$screenRowCache.splice(a,b))}else this.$docRowCache=[],this.$screenRowCache=[]};this.$getRowCacheIndex=function(a,b){for(var d=0,c=a.length-1;d<=c;){var g=d+c>>1,e=a[g];if(b>e)d=g+1;else if(b<e)c=g-1;else return g}return d-1};this.resetCaches=function(){this.$modified=!0;this.$wrapData=[];this.$rowLengthCache=[];this.$resetRowCache(0);this.bgTokenizer&&this.bgTokenizer.start(0)};this.onChangeFold=function(a){this.$resetRowCache(a.data.start.row)};
this.onChange=function(a){this.$modified=!0;this.$resetRowCache(a.start.row);var b=this.$updateInternalDataOnChange(a);this.$fromUndo||!this.$undoManager||a.ignore||(this.$deltasDoc.push(a),b&&0!=b.length&&this.$deltasFold.push({action:"removeFolds",folds:b}),this.$informUndoManager.schedule());this.bgTokenizer&&this.bgTokenizer.$updateOnChange(a);this._signal("change",a)};this.setValue=function(a){this.doc.setValue(a);this.selection.moveTo(0,0);this.$resetRowCache(0);this.$deltas=[];this.$deltasDoc=
[];this.$deltasFold=[];this.setUndoManager(this.$undoManager);this.getUndoManager().reset()};this.getValue=this.toString=function(){return this.doc.getValue()};this.getSelection=function(){return this.selection};this.getState=function(a){return this.bgTokenizer.getState(a)};this.getTokens=function(a){return this.bgTokenizer.getTokens(a)};this.getTokenAt=function(a,b){var d=this.bgTokenizer.getTokens(a),c=0;if(null==b)g=d.length-1,c=this.getLine(a).length;else for(var g=0;g<d.length&&!(c+=d[g].value.length,
c>=b);g++);d=d[g];if(!d)return null;d.index=g;d.start=c-d.value.length;return d};this.setUndoManager=function(a){this.$undoManager=a;this.$deltas=[];this.$deltasDoc=[];this.$deltasFold=[];this.$informUndoManager&&this.$informUndoManager.cancel();if(a){var b=this;this.$syncInformUndoManager=function(){b.$informUndoManager.cancel();b.$deltasFold.length&&(b.$deltas.push({group:"fold",deltas:b.$deltasFold}),b.$deltasFold=[]);b.$deltasDoc.length&&(b.$deltas.push({group:"doc",deltas:b.$deltasDoc}),b.$deltasDoc=
[]);0<b.$deltas.length&&a.execute({action:"aceupdate",args:[b.$deltas,b],merge:b.mergeUndoDeltas});b.mergeUndoDeltas=!1;b.$deltas=[]};this.$informUndoManager=m.delayedCall(this.$syncInformUndoManager)}};this.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()};this.$defaultUndoManager={undo:function(){},redo:function(){},reset:function(){}};this.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager};this.getTabString=function(){return this.getUseSoftTabs()?
m.stringRepeat(" ",this.getTabSize()):"\t"};this.setUseSoftTabs=function(a){this.setOption("useSoftTabs",a)};this.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs};this.setTabSize=function(a){this.setOption("tabSize",a)};this.getTabSize=function(){return this.$tabSize};this.isTabStop=function(a){return this.$useSoftTabs&&0===a.column%this.$tabSize};this.$overwrite=!1;this.setOverwrite=function(a){this.setOption("overwrite",a)};this.getOverwrite=function(){return this.$overwrite};
this.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)};this.addGutterDecoration=function(a,b){this.$decorations[a]||(this.$decorations[a]="");this.$decorations[a]+=" "+b;this._signal("changeBreakpoint",{})};this.removeGutterDecoration=function(a,b){this.$decorations[a]=(this.$decorations[a]||"").replace(" "+b,"");this._signal("changeBreakpoint",{})};this.getBreakpoints=function(){return this.$breakpoints};this.setBreakpoints=function(a){this.$breakpoints=[];for(var b=0;b<a.length;b++)this.$breakpoints[a[b]]=
"ace_breakpoint";this._signal("changeBreakpoint",{})};this.clearBreakpoints=function(){this.$breakpoints=[];this._signal("changeBreakpoint",{})};this.setBreakpoint=function(a,b){void 0===b&&(b="ace_breakpoint");b?this.$breakpoints[a]=b:delete this.$breakpoints[a];this._signal("changeBreakpoint",{})};this.clearBreakpoint=function(a){delete this.$breakpoints[a];this._signal("changeBreakpoint",{})};this.addMarker=function(a,b,d,c){var g=this.$markerId++;a={range:a,type:d||"line",renderer:"function"==
typeof d?d:null,clazz:b,inFront:!!c,id:g};c?(this.$frontMarkers[g]=a,this._signal("changeFrontMarker")):(this.$backMarkers[g]=a,this._signal("changeBackMarker"));return g};this.addDynamicMarker=function(a,b){if(a.update){var d=this.$markerId++;a.id=d;a.inFront=!!b;b?(this.$frontMarkers[d]=a,this._signal("changeFrontMarker")):(this.$backMarkers[d]=a,this._signal("changeBackMarker"));return a}};this.removeMarker=function(a){var b=this.$frontMarkers[a]||this.$backMarkers[a];if(b){var d=b.inFront?this.$frontMarkers:
this.$backMarkers;b&&(delete d[a],this._signal(b.inFront?"changeFrontMarker":"changeBackMarker"))}};this.getMarkers=function(a){return a?this.$frontMarkers:this.$backMarkers};this.highlight=function(a){if(!this.$searchHighlight){var b=new t(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(b)}this.$searchHighlight.setRegexp(a)};this.highlightLines=function(a,b,d,c){"number"!=typeof b&&(d=b,b=a);d||(d="ace_step");a=new g(a,0,b,Infinity);a.id=this.addMarker(a,d,"fullLine",
c);return a};this.setAnnotations=function(a){this.$annotations=a;this._signal("changeAnnotation",{})};this.getAnnotations=function(){return this.$annotations||[]};this.clearAnnotations=function(){this.setAnnotations([])};this.$detectNewLine=function(a){this.$autoNewLine=(a=a.match(/^.*?(\r?\n)/m))?a[1]:"\n"};this.getWordRange=function(a,b){var d=this.getLine(a),c=!1;0<b&&(c=!!d.charAt(b-1).match(this.tokenRe));c||(c=!!d.charAt(b).match(this.tokenRe));var c=c?this.tokenRe:/^\s+$/.test(d.slice(b-1,
b+1))?/\s/:this.nonTokenRe,e=b;if(0<e){do e--;while(0<=e&&d.charAt(e).match(c));e++}for(var h=b;h<d.length&&d.charAt(h).match(c);)h++;return new g(a,e,a,h)};this.getAWordRange=function(a,b){for(var d=this.getWordRange(a,b),c=this.getLine(d.end.row);c.charAt(d.end.column).match(/[ \t]/);)d.end.column+=1;return d};this.setNewLineMode=function(a){this.doc.setNewLineMode(a)};this.getNewLineMode=function(){return this.doc.getNewLineMode()};this.setUseWorker=function(a){this.setOption("useWorker",a)};this.getUseWorker=
function(){return this.$useWorker};this.onReloadTokenizer=function(a){this.bgTokenizer.start(a.data.first);this._signal("tokenizerUpdate",a)};this.$modes={};this.$modeId=this.$mode=null;this.setMode=function(a,c){if(a&&"object"===typeof a){if(a.getTokenizer)return this.$onChangeMode(a);var g=a,e=g.path}else e=a||"ace/mode/text";this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new d);this.$modes[e]&&!g?(this.$onChangeMode(this.$modes[e]),c&&c()):(this.$modeId=e,b.loadModule(["mode",e],function(a){if(this.$modeId!==
e)return c&&c();this.$modes[e]&&!g?this.$onChangeMode(this.$modes[e]):a&&a.Mode&&(a=new a.Mode(g),g||(this.$modes[e]=a,a.$id=e),this.$onChangeMode(a));c&&c()}.bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0))};this.$onChangeMode=function(a,b){b||(this.$modeId=a.$id);if(this.$mode!==a){this.$mode=a;this.$stopWorker();this.$useWorker&&this.$startWorker();var d=a.getTokenizer();if(void 0!==d.addEventListener){var c=this.onReloadTokenizer.bind(this);d.addEventListener("update",
c)}if(this.bgTokenizer)this.bgTokenizer.setTokenizer(d);else{this.bgTokenizer=new h(d);var g=this;this.bgTokenizer.addEventListener("update",function(a){g._signal("tokenizerUpdate",a)})}this.bgTokenizer.setDocument(this.getDocument());this.tokenRe=a.tokenRe;this.nonTokenRe=a.nonTokenRe;b||(a.attachToSession&&a.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(a.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode"))}};this.$stopWorker=function(){this.$worker&&
(this.$worker.terminate(),this.$worker=null)};this.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(a){b.warn("Could not load worker",a),this.$worker=null}};this.getMode=function(){return this.$mode};this.$scrollTop=0;this.setScrollTop=function(a){this.$scrollTop===a||isNaN(a)||(this.$scrollTop=a,this._signal("changeScrollTop",a))};this.getScrollTop=function(){return this.$scrollTop};this.$scrollLeft=0;this.setScrollLeft=function(a){this.$scrollLeft===a||isNaN(a)||(this.$scrollLeft=
a,this._signal("changeScrollLeft",a))};this.getScrollLeft=function(){return this.$scrollLeft};this.getScreenWidth=function(){this.$computeWidth();return this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth};this.getLineWidgetMaxWidth=function(){if(null!=this.lineWidgetsWidth)return this.lineWidgetsWidth;var a=0;this.lineWidgets.forEach(function(b){b&&b.screenWidth>a&&(a=b.screenWidth)});return this.lineWidgetWidth=a};this.$computeWidth=function(a){if(this.$modified||
a){this.$modified=!1;if(this.$useWrapMode)return this.screenWidth=this.$wrapLimit;a=this.doc.getAllLines();for(var b=this.$rowLengthCache,d=0,c=0,g=this.$foldData[c],e=g?g.start.row:Infinity,h=a.length,l=0;l<h;l++){if(l>e){l=g.end.row+1;if(l>=h)break;e=(g=this.$foldData[c++])?g.start.row:Infinity}null==b[l]&&(b[l]=this.$getStringScreenWidth(a[l])[0]);b[l]>d&&(d=b[l])}this.screenWidth=d}};this.getLine=function(a){return this.doc.getLine(a)};this.getLines=function(a,b){return this.doc.getLines(a,b)};
this.getLength=function(){return this.doc.getLength()};this.getTextRange=function(a){return this.doc.getTextRange(a||this.selection.getRange())};this.insert=function(a,b){return this.doc.insert(a,b)};this.remove=function(a){return this.doc.remove(a)};this.removeFullLines=function(a,b){return this.doc.removeFullLines(a,b)};this.undoChanges=function(a,b){if(a.length){this.$fromUndo=!0;for(var d=null,c=a.length-1;-1!=c;c--){var g=a[c];"doc"==g.group?(this.doc.revertDeltas(g.deltas),d=this.$getUndoSelection(g.deltas,
!0,d)):g.deltas.forEach(function(a){this.addFolds(a.folds)},this)}this.$fromUndo=!1;d&&this.$undoSelect&&!b&&this.selection.setSelectionRange(d);return d}};this.redoChanges=function(a,b){if(a.length){this.$fromUndo=!0;for(var d=null,c=0;c<a.length;c++){var g=a[c];"doc"==g.group&&(this.doc.applyDeltas(g.deltas),d=this.$getUndoSelection(g.deltas,!1,d))}this.$fromUndo=!1;d&&this.$undoSelect&&!b&&this.selection.setSelectionRange(d);return d}};this.setUndoSelect=function(a){this.$undoSelect=a};this.$getUndoSelection=
function(a,b,d){var c=a[0],e,l;e=(b?"insert"!==c.action:"insert"===c.action)?g.fromPoints(c.start,c.end):g.fromPoints(c.start,c.start);for(var h=1;h<a.length;h++)c=a[h],(b?"insert"!==c.action:"insert"===c.action)?(l=c.start,-1==e.compare(l.row,l.column)&&e.setStart(l),l=c.end,1==e.compare(l.row,l.column)&&e.setEnd(l)):(l=c.start,-1==e.compare(l.row,l.column)&&(e=g.fromPoints(c.start,c.start)));null!=d&&(0===g.comparePoints(d.start,e.start)&&(d.start.column+=e.end.column-e.start.column,d.end.column+=
e.end.column-e.start.column),a=d.compareRange(e),1==a?e.setStart(d.start):-1==a&&e.setEnd(d.end));return e};this.replace=function(a,b){return this.doc.replace(a,b)};this.moveText=function(a,b,d){var c=this.getTextRange(a),e=this.getFoldsInRange(a);b=g.fromPoints(b,b);if(!d){this.remove(a);var l=a.start.row-a.end.row,h=l?-a.end.column:a.start.column-a.end.column;h&&(b.start.row==a.end.row&&b.start.column>a.end.column&&(b.start.column+=h),b.end.row==a.end.row&&b.end.column>a.end.column&&(b.end.column+=
h));l&&b.start.row>=a.end.row&&(b.start.row+=l,b.end.row+=l)}b.end=this.insert(b.start,c);if(e.length){var f=a.start;a=b.start;l=a.row-f.row;h=a.column-f.column;this.addFolds(e.map(function(a){a=a.clone();a.start.row==f.row&&(a.start.column+=h);a.end.row==f.row&&(a.end.column+=h);a.start.row+=l;a.end.row+=l;return a}))}return b};this.indentRows=function(a,b,d){for(d=d.replace(/\t/g,this.getTabString());a<=b;a++)this.doc.insertInLine({row:a,column:0},d)};this.outdentRows=function(a){a=a.collapseRows();
for(var b=new g(0,0,0,0),d=this.getTabSize(),c=a.start.row;c<=a.end.row;++c){var e=this.getLine(c);b.start.row=c;b.end.row=c;for(var l=0;l<d&&" "==e.charAt(l);++l);l<d&&"\t"==e.charAt(l)?(b.start.column=l,b.end.column=l+1):(b.start.column=0,b.end.column=l);this.remove(b)}};this.$moveLines=function(a,b,d){a=this.getRowFoldStart(a);b=this.getRowFoldEnd(b);if(0>d){var c=this.getRowFoldStart(a+d);if(0>c)return 0;var e=c-a}else if(0<d){c=this.getRowFoldEnd(b+d);if(c>this.doc.getLength()-1)return 0;e=c-
b}else a=this.$clipRowToDocument(a),b=this.$clipRowToDocument(b),e=b-a+1;c=new g(a,0,b,Number.MAX_VALUE);c=this.getFoldsInRange(c).map(function(a){a=a.clone();a.start.row+=e;a.end.row+=e;return a});b=0==d?this.doc.getLines(a,b):this.doc.removeFullLines(a,b);this.doc.insertFullLines(a+e,b);c.length&&this.addFolds(c);return e};this.moveLinesUp=function(a,b){return this.$moveLines(a,b,-1)};this.moveLinesDown=function(a,b){return this.$moveLines(a,b,1)};this.duplicateLines=function(a,b){return this.$moveLines(a,
b,0)};this.$clipRowToDocument=function(a){return Math.max(0,Math.min(a,this.doc.getLength()-1))};this.$clipColumnToRow=function(a,b){return 0>b?0:Math.min(this.doc.getLine(a).length,b)};this.$clipPositionToDocument=function(a,b){b=Math.max(0,b);if(0>a)b=a=0;else{var d=this.doc.getLength();a>=d?(a=d-1,b=this.doc.getLine(d-1).length):b=Math.min(this.doc.getLine(a).length,b)}return{row:a,column:b}};this.$clipRangeToDocument=function(a){0>a.start.row?(a.start.row=0,a.start.column=0):a.start.column=this.$clipColumnToRow(a.start.row,
a.start.column);var b=this.doc.getLength()-1;a.end.row>b?(a.end.row=b,a.end.column=this.doc.getLine(b).length):a.end.column=this.$clipColumnToRow(a.end.row,a.end.column);return a};this.$wrapLimit=80;this.$useWrapMode=!1;this.$wrapLimitRange={min:null,max:null};this.setUseWrapMode=function(a){a!=this.$useWrapMode&&(this.$useWrapMode=a,this.$modified=!0,this.$resetRowCache(0),a&&(a=this.getLength(),this.$wrapData=Array(a),this.$updateWrapData(0,a-1)),this._signal("changeWrapMode"))};this.getUseWrapMode=
function(){return this.$useWrapMode};this.setWrapLimitRange=function(a,b){if(this.$wrapLimitRange.min!==a||this.$wrapLimitRange.max!==b)this.$wrapLimitRange={min:a,max:b},this.$modified=!0,this.$useWrapMode&&this._signal("changeWrapMode")};this.adjustWrapLimit=function(a,b){var d=this.$wrapLimitRange;0>d.max&&(d={min:b,max:b});d=this.$constrainWrapLimit(a,d.min,d.max);return d!=this.$wrapLimit&&1<d?(this.$wrapLimit=d,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),
this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1};this.$constrainWrapLimit=function(a,b,d){b&&(a=Math.max(b,a));d&&(a=Math.min(d,a));return a};this.getWrapLimit=function(){return this.$wrapLimit};this.setWrapLimit=function(a){this.setWrapLimitRange(a,a)};this.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}};this.$updateInternalDataOnChange=function(a){var b=this.$useWrapMode,d=a.action,c=a.start,g=a.end,e=c.row,l=g.row,h=l-e,f=null;this.$updating=
!0;if(0!=h)if("remove"===d){this[b?"$wrapData":"$rowLengthCache"].splice(e,h);d=this.$foldData;f=this.getFoldsInRange(a);this.removeFolds(f);a=this.getFoldLine(g.row);var n=0;a&&(a.addRemoveChars(g.row,g.column,c.column-g.column),a.shiftRow(-h),(c=this.getFoldLine(e))&&c!==a&&(c.merge(a),a=c),n=d.indexOf(a)+1);for(n;n<d.length;n++)a=d[n],a.start.row>=g.row&&a.shiftRow(-h);l=e}else{d=Array(h);d.unshift(e,0);a=b?this.$wrapData:this.$rowLengthCache;a.splice.apply(a,d);d=this.$foldData;a=this.getFoldLine(e);
n=0;if(a){n=a.range.compareInside(c.row,c.column);if(0==n){if(a=a.split(c.row,c.column))a.shiftRow(h),a.addRemoveChars(l,0,g.column-c.column)}else-1==n&&(a.addRemoveChars(e,0,g.column-c.column),a.shiftRow(h));n=d.indexOf(a)+1}for(n;n<d.length;n++)a=d[n],a.start.row>=e&&a.shiftRow(h)}else h=Math.abs(a.start.column-a.end.column),"remove"===d&&(f=this.getFoldsInRange(a),this.removeFolds(f),h=-h),(a=this.getFoldLine(e))&&a.addRemoveChars(e,c.column,h);b&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!");
this.$updating=!1;b?this.$updateWrapData(e,l):this.$updateRowLengthCache(e,l);return f};this.$updateRowLengthCache=function(a,b,d){this.$rowLengthCache[a]=null;this.$rowLengthCache[b]=null};this.$updateWrapData=function(a,b){var d=this.doc.getAllLines(),c=this.getTabSize(),g=this.$wrapData,e=this.$wrapLimit,l,h,k=a;for(b=Math.min(b,d.length-1);k<=b;)(h=this.getFoldLine(k,h))?(l=[],h.walk(function(a,b,c,g){if(null!=a)for(a=this.$getDisplayTokens(a,l.length),a[0]=f,b=1;b<a.length;b++)a[b]=n;else a=
this.$getDisplayTokens(d[b].substring(g,c),l.length);l=l.concat(a)}.bind(this),h.end.row,d[h.end.row].length+1),g[h.start.row]=this.$computeWrapSplits(l,e,c),k=h.end.row+1):(l=this.$getDisplayTokens(d[k]),g[k]=this.$computeWrapSplits(l,e,c),k++)};var f=3,n=4;this.$computeWrapSplits=function(a,b,d){function c(){var b=0;if(0===r)return b;if(m)for(var g=0;g<a.length;g++){var e=a[g];if(10==e)b+=1;else if(11==e)b+=d;else if(12!=e)break}t&&!1!==m&&(b+=d);return Math.min(b,r)}function g(b){var d=a.slice(h,
b),l=d.length;d.join("").replace(/12/g,function(){l-=1}).replace(/2/g,function(){l-=1});e.length||(F=c(),e.indent=F);k+=l;e.push(k);h=b}if(0==a.length)return[];for(var e=[],l=a.length,h=0,k=0,t=this.$wrapAsCode,m=this.$indentedSoftWrap,r=b<=Math.max(2*d,8)||!1===m?0:Math.floor(b/2),F=0;l-h>b-F;){var w=h+b-F;if(10<=a[w-1]&&10<=a[w])g(w);else if(a[w]==f||a[w]==n){for(w;w!=h-1&&a[w]!=f;w--);if(!(w>h)){w=h+b;for(w;w<a.length&&a[w]==n;w++);if(w==a.length)break}g(w)}else{for(var E=Math.max(w-(b-(b>>2)),
h-1);w>E&&a[w]<f;)w--;if(t){for(;w>E&&a[w]<f;)w--;for(;w>E&&9==a[w];)w--}else for(;w>E&&10>a[w];)w--;w>E?g(++w):(w=h+b,2==a[w]&&w--,g(w-F))}}return e};this.$getDisplayTokens=function(b,d){var c=[],g;d=d||0;for(var e=0;e<b.length;e++)if(g=b.charCodeAt(e),9==g){g=this.getScreenTabSize(c.length+d);c.push(11);for(var h=1;h<g;h++)c.push(12)}else 32==g?c.push(10):39<g&&48>g||57<g&&64>g?c.push(9):4352<=g&&a(g)?c.push(1,2):c.push(1);return c};this.$getStringScreenWidth=function(b,d,c){if(0==d)return[0,0];
null==d&&(d=Infinity);c=c||0;var g,e;for(e=0;e<b.length&&!(g=b.charCodeAt(e),c=9==g?c+this.getScreenTabSize(c):4352<=g&&a(g)?c+2:c+1,c>d);e++);return[c,e]};this.lineWidgets=null;this.getRowLength=function(a){var b=this.lineWidgets?this.lineWidgets[a]&&this.lineWidgets[a].rowCount||0:0;return this.$useWrapMode&&this.$wrapData[a]?this.$wrapData[a].length+1+b:1+b};this.getRowLineCount=function(a){return this.$useWrapMode&&this.$wrapData[a]?this.$wrapData[a].length+1:1};this.getRowWrapIndent=function(a){if(this.$useWrapMode){a=
this.screenToDocumentPosition(a,Number.MAX_VALUE);var b=this.$wrapData[a.row];return b.length&&b[0]<a.column?b.indent:0}return 0};this.getScreenLastRowColumn=function(a){a=this.screenToDocumentPosition(a,Number.MAX_VALUE);return this.documentToScreenColumn(a.row,a.column)};this.getDocumentLastRowColumn=function(a,b){var d=this.documentToScreenRow(a,b);return this.getScreenLastRowColumn(d)};this.getDocumentLastRowColumnPosition=function(a,b){var d=this.documentToScreenRow(a,b);return this.screenToDocumentPosition(d,
Number.MAX_VALUE/10)};this.getRowSplitData=function(a){if(this.$useWrapMode)return this.$wrapData[a]};this.getScreenTabSize=function(a){return this.$tabSize-a%this.$tabSize};this.screenToDocumentRow=function(a,b){return this.screenToDocumentPosition(a,b).row};this.screenToDocumentColumn=function(a,b){return this.screenToDocumentPosition(a,b).column};this.screenToDocumentPosition=function(a,b){if(0>a)return{row:0,column:0};var d,c=0,g=0,e,l=0;d=0;var h=this.$screenRowCache,f=this.$getRowCacheIndex(h,
a),n=h.length;n&&0<=f?(l=h[f],c=this.$docRowCache[f],f=a>h[n-1]):f=!n;for(var n=this.getLength()-1,p=(h=this.getNextFoldLine(c))?h.start.row:Infinity;l<=a;){d=this.getRowLength(c);if(l+d>a||c>=n)break;else l+=d,c++,c>p&&(c=h.end.row+1,p=(h=this.getNextFoldLine(c,h))?h.start.row:Infinity);f&&(this.$docRowCache.push(c),this.$screenRowCache.push(l))}if(h&&h.start.row<=c)d=this.getFoldDisplayLine(h),c=h.start.row;else{if(l+d<=a||c>n)return{row:n,column:this.getLine(n).length};d=this.getLine(c);h=null}f=
0;this.$useWrapMode&&(n=this.$wrapData[c])&&(l=Math.floor(a-l),e=n[l],0<l&&n.length&&(f=n.indent,g=n[l-1]||n[n.length-1],d=d.substring(g)));g+=this.$getStringScreenWidth(d,b-f)[1];this.$useWrapMode&&g>=e&&(g=e-1);return h?h.idxToPosition(g):{row:c,column:g}};this.documentToScreenPosition=function(a,b){var d="undefined"===typeof b?this.$clipPositionToDocument(a.row,a.column):this.$clipPositionToDocument(a,b);a=d.row;b=d.column;var d=0,c=null,g=null;if(g=this.getFoldAt(a,b,1))a=g.start.row,b=g.start.column;
var e,g=0;e=this.$docRowCache;var c=this.$getRowCacheIndex(e,a),l=e.length;if(l&&0<=c)var g=e[c],d=this.$screenRowCache[c],h=a>e[l-1];else h=!l;for(l=(c=this.getNextFoldLine(g))?c.start.row:Infinity;g<a;){if(g>=l){e=c.end.row+1;if(e>a)break;l=(c=this.getNextFoldLine(e,c))?c.start.row:Infinity}else e=g+1;d+=this.getRowLength(g);g=e;h&&(this.$docRowCache.push(g),this.$screenRowCache.push(d))}e="";c&&g>=l?(e=this.getFoldDisplayLine(c,a,b),c=c.start.row):(e=this.getLine(a).substring(0,b),c=a);g=0;if(this.$useWrapMode&&
(c=this.$wrapData[c])){for(g=0;e.length>=c[g];)d++,g++;e=e.substring(c[g-1]||0,e.length);g=0<g?c.indent:0}return{row:d,column:g+this.$getStringScreenWidth(e)[0]}};this.documentToScreenColumn=function(a,b){return this.documentToScreenPosition(a,b).column};this.documentToScreenRow=function(a,b){return this.documentToScreenPosition(a,b).row};this.getScreenLength=function(){var a=0,b=null;if(this.$useWrapMode)for(var d=this.$wrapData.length,c=0,g=0,e=(b=this.$foldData[g++])?b.start.row:Infinity;c<d;){var l=
this.$wrapData[c],a=a+(l?l.length+1:1);c++;c>e&&(c=b.end.row+1,e=(b=this.$foldData[g++])?b.start.row:Infinity)}else for(var a=this.getLength(),d=this.$foldData,g=0;g<d.length;g++)b=d[g],a-=b.end.row-b.start.row;this.lineWidgets&&(a+=this.$getWidgetScreenLength());return a};this.$setFontMetrics=function(a){};this.destroy=function(){this.bgTokenizer&&(this.bgTokenizer.setDocument(null),this.bgTokenizer=null);this.$stopWorker()}}).call(r.prototype);f("./edit_session/folding").Folding.call(r.prototype);
f("./edit_session/bracket_match").BracketMatch.call(r.prototype);b.defineOptions(r.prototype,"session",{wrap:{set:function(a){a&&"off"!=a?"free"==a?a=!0:"printMargin"==a?a=-1:"string"==typeof a&&(a=parseInt(a,10)||!1):a=!1;this.$wrap!=a&&((this.$wrap=a)?(a="number"==typeof a?a:null,this.setWrapLimitRange(a,a),this.setUseWrapMode(!0)):this.setUseWrapMode(!1))},get:function(){return this.getUseWrapMode()?-1==this.$wrap?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},
wrapMethod:{set:function(a){a="auto"==a?"text"!=this.$mode.type:"text"!=a;a!=this.$wrapAsCode&&(this.$wrapAsCode=a,this.$useWrapMode&&(this.$modified=!0,this.$resetRowCache(0),this.$updateWrapData(0,this.getLength()-1)))},initialValue:"auto"},indentedSoftWrap:{initialValue:!0},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(a){this.$useWorker=a;this.$stopWorker();a&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(a){isNaN(a)||
this.$tabSize===a||(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=a,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},overwrite:{set:function(a){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(a){this.doc.setNewLineMode(a)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(a){this.setMode(a)},get:function(){return this.$modeId}}});k.EditSession=r});
define("ace/search","require exports module ace/lib/lang ace/lib/oop ace/range".split(" "),function(f,k,r){var e=f("./lib/lang"),m=f("./lib/oop"),b=f("./range").Range;f=function(){this.$options={}};(function(){this.set=function(b){m.mixin(this.$options,b);return this};this.getOptions=function(){return e.copyObject(this.$options)};this.setOptions=function(b){this.$options=b};this.find=function(c){var a=this.$options;c=this.$matchIterator(c,a);if(!c)return!1;var d=null;c.forEach(function(c,e,h){if(c.start)d=
c;else if(h=c.offset+(h||0),d=new b(e,h,e,h+c.length),!c.length&&a.start&&a.start.start&&!1!=a.skipCurrent&&d.isEqual(a.start))return d=null,!1;return!0});return d};this.findAll=function(c){var a=this.$options;if(!a.needle)return[];this.$assembleRegExp(a);var d=a.range,g=d?c.getLines(d.start.row,d.end.row):c.doc.getAllLines();c=[];var f=a.re;if(a.$isMultiLine){var h=f.length,k=g.length-h,l,p=f.offset||0;a:for(;p<=k;p++){for(a=0;a<h;a++)if(-1==g[p+a].search(f[a]))continue a;var m=g[p],a=g[p+h-1],m=
m.length-m.match(f[0])[0].length,a=a.match(f[h-1])[0].length;l&&l.end.row===p&&l.end.column>m||(c.push(l=new b(p,m,p+h-1,a)),2<h&&(p=p+h-2))}}else for(l=0;l<g.length;l++)for(h=e.getMatchOffsets(g[l],f),a=0;a<h.length;a++)k=h[a],c.push(new b(l,k.offset,l,k.offset+k.length));if(d){f=g=d.start.column;l=0;for(a=c.length-1;l<a&&c[l].start.column<g&&c[l].start.row==d.start.row;)l++;for(;l<a&&c[a].end.column>f&&c[a].end.row==d.end.row;)a--;c=c.slice(l,a+1);l=0;for(a=c.length;l<a;l++)c[l].start.row+=d.start.row,
c[l].end.row+=d.start.row}return c};this.replace=function(b,a){var d=this.$options,g=this.$assembleRegExp(d);if(d.$isMultiLine)return a;if(g){var e=g.exec(b);if(!e||e[0].length!=b.length)return null;a=b.replace(g,a);if(d.preserveCase){a=a.split("");for(d=Math.min(b.length,b.length);d--;)(g=b[d])&&g.toLowerCase()!=g?a[d]=a[d].toUpperCase():a[d]=a[d].toLowerCase();a=a.join("")}return a}};this.$matchIterator=function(c,a){var d=this.$assembleRegExp(a);if(!d)return!1;var g;if(a.$isMultiLine)var f=d.length,
h=function(a,e,h){var s=a.search(d[0]);if(-1!=s){for(var q=1;q<f;q++)if(a=c.getLine(e+q),-1==a.search(d[q]))return;a=a.match(d[f-1])[0].length;e=new b(e,s,e+f-1,a);1==d.offset?(e.start.row--,e.start.column=Number.MAX_VALUE):h&&(e.start.column+=h);if(g(e))return!0}};else h=a.backwards?function(a,b,c){a=e.getMatchOffsets(a,d);for(var h=a.length-1;0<=h;h--)if(g(a[h],b,c))return!0}:function(a,b,c){a=e.getMatchOffsets(a,d);for(var h=0;h<a.length;h++)if(g(a[h],b,c))return!0};var k=this.$lineIterator(c,
a);return{forEach:function(a){g=a;k.forEach(h)}}};this.$assembleRegExp=function(b,a){if(b.needle instanceof RegExp)return b.re=b.needle;var d=b.needle;if(!b.needle)return b.re=!1;b.regExp||(d=e.escapeRegExp(d));b.wholeWord&&(d="\\b"+d+"\\b");var g=b.caseSensitive?"gm":"gmi";b.$isMultiLine=!a&&/[\n\r]/.test(d);if(b.$isMultiLine)return b.re=this.$assembleMultilineRegExp(d,g);try{var f=new RegExp(d,g)}catch(h){f=!1}return b.re=f};this.$assembleMultilineRegExp=function(b,a){for(var d=b.replace(/\r\n|\r|\n/g,
"$\n^").split("\n"),g=[],e=0;e<d.length;e++)try{g.push(new RegExp(d[e],a))}catch(h){return!1}""==d[0]?(g.shift(),g.offset=1):g.offset=0;return g};this.$lineIterator=function(b,a){var d=!0==a.backwards,g=!1!=a.skipCurrent,e=a.range,h=a.start;h||(h=e?e[d?"end":"start"]:b.selection.getRange());h.start&&(h=h[g!=d?"end":"start"]);var f=e?e.start.row:0,l=e?e.end.row:b.getLength()-1;return{forEach:d?function(d){var g=h.row,e=b.getLine(g).substring(0,h.column);if(!d(e,g)){for(g--;g>=f;g--)if(d(b.getLine(g),
g))return;if(!1!=a.wrap)for(g=l,f=h.row;g>=f&&!d(b.getLine(g),g);g--);}}:function(d){var g=h.row,e=b.getLine(g).substr(h.column);if(!d(e,g,h.column)){for(g+=1;g<=l;g++)if(d(b.getLine(g),g))return;if(!1!=a.wrap)for(g=f,l=h.row;g<=l&&!d(b.getLine(g),g);g++);}}}}}).call(f.prototype);k.Search=f});
define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(f,k,r){function e(a,b){this.platform=b||(c.isMac?"mac":"win");this.commands={};this.commandKeyBinding={};this.addCommands(a);this.$singleCommand=!0}function m(a,b){e.call(this,a,b);this.$singleCommand=!1}var b=f("../lib/keys"),c=f("../lib/useragent"),a=b.KEY_MODS;m.prototype=e.prototype;(function(){function d(a){return"object"==typeof a&&a.bindKey&&a.bindKey.position||0}this.addCommand=function(a){this.commands[a.name]&&
this.removeCommand(a);this.commands[a.name]=a;a.bindKey&&this._buildKeyHash(a)};this.removeCommand=function(a,b){var d=a&&("string"===typeof a?a:a.name);a=this.commands[d];b||delete this.commands[d];var d=this.commandKeyBinding,c;for(c in d){var e=d[c];if(e==a)delete d[c];else if(Array.isArray(e)){var f=e.indexOf(a);-1!=f&&(e.splice(f,1),1==e.length&&(d[c]=e[0]))}}};this.bindKey=function(b,d,c){"object"==typeof b&&(void 0==c&&(c=b.position),b=b[this.platform]);if(b){if("function"==typeof d)return this.addCommand({exec:d,
bindKey:b,name:d.name||b});b.split("|").forEach(function(b){var g="";if(-1!=b.indexOf(" ")){var e=b.split(/\s+/);b=e.pop();e.forEach(function(b){b=this.parseKeys(b);g+=(g?" ":"")+(a[b.hashId]+b.key);this._addCommandToBinding(g,"chainKeys")},this);g+=" "}b=this.parseKeys(b);this._addCommandToBinding(g+(a[b.hashId]+b.key),d,c)},this)}};this._addCommandToBinding=function(a,b,c){var e=this.commandKeyBinding,l;if(b)if(!e[a]||this.$singleCommand)e[a]=b;else{Array.isArray(e[a])?-1!=(l=e[a].indexOf(b))&&
e[a].splice(l,1):e[a]=[e[a]];"number"!=typeof c&&(c=c||b.isDefault?-100:d(b));a=e[a];for(l=0;l<a.length&&!(d(a[l])>c);l++);a.splice(l,0,b)}else delete e[a]};this.addCommands=function(a){a&&Object.keys(a).forEach(function(b){var d=a[b];if(d){if("string"===typeof d)return this.bindKey(d,b);"function"===typeof d&&(d={exec:d});"object"===typeof d&&(d.name||(d.name=b),this.addCommand(d))}},this)};this.removeCommands=function(a){Object.keys(a).forEach(function(b){this.removeCommand(a[b])},this)};this.bindKeys=
function(a){Object.keys(a).forEach(function(b){this.bindKey(b,a[b])},this)};this._buildKeyHash=function(a){this.bindKey(a.bindKey,a)};this.parseKeys=function(a){var d=a.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(a){return a}),c=d.pop(),e=b[c];if(b.FUNCTION_KEYS[e])c=b.FUNCTION_KEYS[e].toLowerCase();else{if(!d.length)return{key:c,hashId:-1};if(1==d.length&&"shift"==d[0])return{key:c.toUpperCase(),hashId:-1}}for(var e=0,l=d.length;l--;){var f=b.KEY_MODS[d[l]];if(null==f)return"undefined"!=
typeof console&&console.error("invalid modifier "+d[l]+" in "+a),!1;e|=f}return{key:c,hashId:e}};this.findKeyCommand=function(b,d){return this.commandKeyBinding[a[b]+d]};this.handleKeyboard=function(b,d,c,e){var l=a[d]+c,f=this.commandKeyBinding[l];b.$keyChain&&(b.$keyChain+=" "+l,f=this.commandKeyBinding[b.$keyChain]||f);if(f&&("chainKeys"==f||"chainKeys"==f[f.length-1]))return b.$keyChain=b.$keyChain||l,{command:"null"};if(b.$keyChain)if((!d||4==d)&&1==c.length)b.$keyChain=b.$keyChain.slice(0,-l.length-
1);else if(-1==d||0<e)b.$keyChain="";return{command:f}};this.getStatusText=function(a,b){return b.$keyChain||""}}).call(e.prototype);k.HashHandler=e;k.MultiHashHandler=m});
define("ace/commands/command_manager","require exports module ace/lib/oop ace/keyboard/hash_handler ace/lib/event_emitter".split(" "),function(f,k,r){var e=f("../lib/oop"),m=f("../keyboard/hash_handler").MultiHashHandler,b=f("../lib/event_emitter").EventEmitter;f=function(b,a){m.call(this,a,b);this.byName=this.commands;this.setDefaultHandler("exec",function(a){return a.command.exec(a.editor,a.args||{})})};e.inherits(f,m);(function(){e.implement(this,b);this.exec=function(b,a,d){if(Array.isArray(b)){for(var e=
b.length;e--;)if(this.exec(b[e],a,d))return!0;return!1}"string"===typeof b&&(b=this.commands[b]);if(!b||a&&a.$readOnly&&!b.readOnly)return!1;b={editor:a,command:b,args:d};b.returnValue=this._emit("exec",b);this._signal("afterExec",b);return!1===b.returnValue?!1:!0};this.toggleRecording=function(b){if(!this.$inReplay){b&&b._emit("changeStatus");if(this.recording)return this.macro.pop(),this.removeEventListener("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=
!1;this.$addCommandToMacro||(this.$addCommandToMacro=function(a){this.macro.push([a.command,a.args])}.bind(this));this.oldMacro=this.macro;this.macro=[];this.on("exec",this.$addCommandToMacro);return this.recording=!0}};this.replay=function(b){if(!this.$inReplay&&this.macro){if(this.recording)return this.toggleRecording(b);try{this.$inReplay=!0,this.macro.forEach(function(a){"string"==typeof a?this.exec(a,b):this.exec(a[0],b,a[1])},this)}finally{this.$inReplay=!1}}};this.trimMacro=function(b){return b.map(function(a){"string"!=
typeof a[0]&&(a[0]=a[0].name);a[1]||(a=a[0]);return a})}}).call(f.prototype);k.CommandManager=f});
define("ace/commands/default_commands","require exports module ace/lib/lang ace/config ace/range".split(" "),function(f,k,r){function e(a,b){return{win:a,mac:b}}var m=f("../lib/lang"),b=f("../config"),c=f("../range").Range;k.commands=[{name:"showSettingsMenu",bindKey:e("Ctrl-,","Command-,"),exec:function(a){b.loadModule("ace/ext/settings_menu",function(b){b.init(a);a.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",bindKey:e("Alt-E","Ctrl-E"),exec:function(a){b.loadModule("ace/ext/error_marker",
function(b){b.showErrorMarker(a,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",bindKey:e("Alt-Shift-E","Ctrl-Shift-E"),exec:function(a){b.loadModule("ace/ext/error_marker",function(b){b.showErrorMarker(a,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",bindKey:e("Ctrl-A","Command-A"),exec:function(a){a.selectAll()},readOnly:!0},{name:"centerselection",bindKey:e(null,"Ctrl-L"),exec:function(a){a.centerSelection()},readOnly:!0},{name:"gotoline",bindKey:e("Ctrl-L",
"Command-L"),exec:function(a){var b=parseInt(prompt("Enter line number:"),10);isNaN(b)||a.gotoLine(b)},readOnly:!0},{name:"fold",bindKey:e("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(a){a.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:e("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(a){a.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",
bindKey:e("F2","F2"),exec:function(a){a.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",bindKey:e("Alt-F2","Alt-F2"),exec:function(a){a.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",bindKey:e(null,"Ctrl-Command-Option-0"),exec:function(a){a.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",bindKey:e("Alt-0","Command-Option-0"),exec:function(a){a.session.foldAll();
a.session.unfold(a.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",bindKey:e("Alt-Shift-0","Command-Option-Shift-0"),exec:function(a){a.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",bindKey:e("Ctrl-K","Command-G"),exec:function(a){a.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",bindKey:e("Ctrl-Shift-K","Command-Shift-G"),exec:function(a){a.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",
readOnly:!0},{name:"selectOrFindNext",bindKey:e("Alt-K","Ctrl-G"),exec:function(a){a.selection.isEmpty()?a.selection.selectWord():a.findNext()},readOnly:!0},{name:"selectOrFindPrevious",bindKey:e("Alt-Shift-K","Ctrl-Shift-G"),exec:function(a){a.selection.isEmpty()?a.selection.selectWord():a.findPrevious()},readOnly:!0},{name:"find",bindKey:e("Ctrl-F","Command-F"),exec:function(a){b.loadModule("ace/ext/searchbox",function(b){b.Search(a)})},readOnly:!0},{name:"overwrite",bindKey:"Insert",exec:function(a){a.toggleOverwrite()},
readOnly:!0},{name:"selecttostart",bindKey:e("Ctrl-Shift-Home","Command-Shift-Up"),exec:function(a){a.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",bindKey:e("Ctrl-Home","Command-Home|Command-Up"),exec:function(a){a.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",bindKey:e("Shift-Up","Shift-Up"),exec:function(a){a.getSelection().selectUp()},
multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",bindKey:e("Up","Up|Ctrl-P"),exec:function(a,b){a.navigateUp(b.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",bindKey:e("Ctrl-Shift-End","Command-Shift-Down"),exec:function(a){a.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",bindKey:e("Ctrl-End","Command-End|Command-Down"),exec:function(a){a.navigateFileEnd()},
multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",bindKey:e("Shift-Down","Shift-Down"),exec:function(a){a.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",bindKey:e("Down","Down|Ctrl-N"),exec:function(a,b){a.navigateDown(b.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",bindKey:e("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(a){a.getSelection().selectWordLeft()},
multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",bindKey:e("Ctrl-Left","Option-Left"),exec:function(a){a.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",bindKey:e("Alt-Shift-Left","Command-Shift-Left"),exec:function(a){a.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",bindKey:e("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(a){a.navigateLineStart()},
multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",bindKey:e("Shift-Left","Shift-Left"),exec:function(a){a.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",bindKey:e("Left","Left|Ctrl-B"),exec:function(a,b){a.navigateLeft(b.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",bindKey:e("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(a){a.getSelection().selectWordRight()},
multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",bindKey:e("Ctrl-Right","Option-Right"),exec:function(a){a.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",bindKey:e("Alt-Shift-Right","Command-Shift-Right"),exec:function(a){a.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",bindKey:e("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(a){a.navigateLineEnd()},
multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",bindKey:e("Shift-Right","Shift-Right"),exec:function(a){a.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",bindKey:e("Right","Right|Ctrl-F"),exec:function(a,b){a.navigateRight(b.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",bindKey:"Shift-PageDown",exec:function(a){a.selectPageDown()},readOnly:!0},{name:"pagedown",
bindKey:e(null,"Option-PageDown"),exec:function(a){a.scrollPageDown()},readOnly:!0},{name:"gotopagedown",bindKey:e("PageDown","PageDown|Ctrl-V"),exec:function(a){a.gotoPageDown()},readOnly:!0},{name:"selectpageup",bindKey:"Shift-PageUp",exec:function(a){a.selectPageUp()},readOnly:!0},{name:"pageup",bindKey:e(null,"Option-PageUp"),exec:function(a){a.scrollPageUp()},readOnly:!0},{name:"gotopageup",bindKey:"PageUp",exec:function(a){a.gotoPageUp()},readOnly:!0},{name:"scrollup",bindKey:e("Ctrl-Up",null),
exec:function(a){a.renderer.scrollBy(0,-2*a.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",bindKey:e("Ctrl-Down",null),exec:function(a){a.renderer.scrollBy(0,2*a.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",bindKey:"Shift-Home",exec:function(a){a.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",bindKey:"Shift-End",exec:function(a){a.getSelection().selectLineEnd()},multiSelectAction:"forEach",
scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",bindKey:e("Ctrl-Alt-E","Command-Option-E"),exec:function(a){a.commands.toggleRecording(a)},readOnly:!0},{name:"replaymacro",bindKey:e("Ctrl-Shift-E","Command-Shift-E"),exec:function(a){a.commands.replay(a)},readOnly:!0},{name:"jumptomatching",bindKey:e("Ctrl-P","Ctrl-P"),exec:function(a){a.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",bindKey:e("Ctrl-Shift-P","Ctrl-Shift-P"),
exec:function(a){a.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",bindKey:e("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(a){a.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",bindKey:e(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",exec:function(a){},readOnly:!0},{name:"cut",exec:function(a){var b=a.getSelectionRange();a._emit("cut",b);a.selection.isEmpty()||
(a.session.remove(b),a.clearSelection())},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",exec:function(a,b){a.$handlePaste(b)},scrollIntoView:"cursor"},{name:"removeline",bindKey:e("Ctrl-D","Command-D"),exec:function(a){a.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",bindKey:e("Ctrl-Shift-D","Command-Shift-D"),exec:function(a){a.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",bindKey:e("Ctrl-Alt-S",
"Command-Alt-S"),exec:function(a){a.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",bindKey:e("Ctrl-/","Command-/"),exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",bindKey:e("Ctrl-Shift-/","Command-Shift-/"),exec:function(a){a.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",bindKey:e("Ctrl-Shift-Up","Alt-Shift-Up"),
exec:function(a){a.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",bindKey:e("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(a){a.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",bindKey:e("Ctrl-H","Command-Option-F"),exec:function(a){b.loadModule("ace/ext/searchbox",function(b){b.Search(a,!0)})}},{name:"undo",bindKey:e("Ctrl-Z","Command-Z"),exec:function(a){a.undo()}},{name:"redo",bindKey:e("Ctrl-Shift-Z|Ctrl-Y",
"Command-Shift-Z|Command-Y"),exec:function(a){a.redo()}},{name:"copylinesup",bindKey:e("Alt-Shift-Up","Command-Option-Up"),exec:function(a){a.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",bindKey:e("Alt-Up","Option-Up"),exec:function(a){a.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",bindKey:e("Alt-Shift-Down","Command-Option-Down"),exec:function(a){a.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",bindKey:e("Alt-Down","Option-Down"),exec:function(a){a.moveLinesDown()},
scrollIntoView:"cursor"},{name:"del",bindKey:e("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(a){a.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",bindKey:e("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(a){a.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",bindKey:e("Shift-Delete",null),exec:function(a){if(a.selection.isEmpty())a.remove("left");else return!1},multiSelectAction:"forEach",
scrollIntoView:"cursor"},{name:"removetolinestart",bindKey:e("Alt-Backspace","Command-Backspace"),exec:function(a){a.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",bindKey:e("Alt-Delete","Ctrl-K"),exec:function(a){a.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",bindKey:e("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(a){a.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},
{name:"removewordright",bindKey:e("Ctrl-Delete","Alt-Delete"),exec:function(a){a.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",bindKey:e("Shift-Tab","Shift-Tab"),exec:function(a){a.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",bindKey:e("Tab","Tab"),exec:function(a){a.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",bindKey:e("Ctrl-[","Ctrl-["),exec:function(a){a.blockOutdent()},
multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",bindKey:e("Ctrl-]","Ctrl-]"),exec:function(a){a.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",exec:function(a,b){a.insert(b)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",exec:function(a,b){a.insert(m.stringRepeat(b.text||"",b.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",bindKey:e(null,"Ctrl-O"),exec:function(a){a.splitLine()},
multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",bindKey:e("Ctrl-T","Ctrl-T"),exec:function(a){a.transposeLetters()},multiSelectAction:function(a){a.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",bindKey:e("Ctrl-U","Ctrl-U"),exec:function(a){a.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",bindKey:e("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(a){a.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},
{name:"expandtoline",bindKey:e("Ctrl-Shift-L","Command-Shift-L"),exec:function(a){var b=a.selection.getRange();b.start.column=b.end.column=0;b.end.row++;a.selection.setRange(b,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"joinlines",bindKey:e(null,null),exec:function(a){for(var b=a.selection.isBackwards(),e=b?a.selection.getSelectionLead():a.selection.getSelectionAnchor(),b=b?a.selection.getSelectionAnchor():a.selection.getSelectionLead(),f=a.session.doc.getLine(e.row).length,
h=a.session.doc.getTextRange(a.selection.getRange()).replace(/\n\s*/," ").length,k=a.session.doc.getLine(e.row),l=e.row+1;l<=b.row+1;l++){var p=m.stringTrimLeft(m.stringTrimRight(a.session.doc.getLine(l)));0!==p.length&&(p=" "+p);k+=p}b.row+1<a.session.doc.getLength()-1&&(k+=a.session.doc.getNewLineCharacter());a.clearSelection();a.session.doc.replace(new c(e.row,0,b.row+2,0),k);0<h?(a.selection.moveCursorTo(e.row,e.column),a.selection.selectTo(e.row,e.column+h)):(f=a.session.doc.getLine(e.row).length>
f?f+1:f,a.selection.moveCursorTo(e.row,f))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",bindKey:e(null,null),exec:function(a){var b=a.session.doc.getLength()-1,e=a.session.doc.getLine(b).length,f=a.selection.rangeList.ranges,h=[];1>f.length&&(f=[a.selection.getRange()]);for(var k=0;k<f.length;k++)k==f.length-1&&(f[k].end.row===b&&f[k].end.column===e||h.push(new c(f[k].end.row,f[k].end.column,b,e))),0===k?0===f[k].start.row&&0===f[k].start.column||h.push(new c(0,0,f[k].start.row,
f[k].start.column)):h.push(new c(f[k-1].end.row,f[k-1].end.column,f[k].start.row,f[k].start.column));a.exitMultiSelectMode();a.clearSelection();for(k=0;k<h.length;k++)a.selection.addRange(h[k],!1)},readOnly:!0,scrollIntoView:"none"}]});
define("ace/editor","require exports module ace/lib/fixoldbrowsers ace/lib/oop ace/lib/dom ace/lib/lang ace/lib/useragent ace/keyboard/textinput ace/mouse/mouse_handler ace/mouse/fold_handler ace/keyboard/keybinding ace/edit_session ace/search ace/range ace/lib/event_emitter ace/commands/command_manager ace/commands/default_commands ace/config ace/token_iterator".split(" "),function(f,k,r){f("./lib/fixoldbrowsers");var e=f("./lib/oop"),m=f("./lib/dom"),b=f("./lib/lang"),c=f("./lib/useragent"),a=f("./keyboard/textinput").TextInput,
d=f("./mouse/mouse_handler").MouseHandler,g=f("./mouse/fold_handler").FoldHandler,n=f("./keyboard/keybinding").KeyBinding,h=f("./edit_session").EditSession,t=f("./search").Search,l=f("./range").Range,p=f("./lib/event_emitter").EventEmitter,D=f("./commands/command_manager").CommandManager,s=f("./commands/default_commands").commands,q=f("./config"),v=f("./token_iterator").TokenIterator;f=function(e,f){this.container=e.getContainerElement();this.renderer=e;this.commands=new D(c.isMac?"mac":"win",s);
this.textInput=new a(e.getTextAreaContainer(),this);this.renderer.textarea=this.textInput.getElement();this.keyBinding=new n(this);this.$mouseHandler=new d(this);new g(this);this.$blockScrolling=0;this.$search=(new t).set({wrap:!0});this.$historyTracker=this.$historyTracker.bind(this);this.commands.on("exec",this.$historyTracker);this.$initOperationListeners();this._$emitInputEvent=b.delayedCall(function(){this._signal("input",{});this.session&&this.session.bgTokenizer&&this.session.bgTokenizer.scheduleStart()}.bind(this));
this.on("change",function(a,b){b._$emitInputEvent.schedule(31)});this.setSession(f||new h(""));q.resetOptions(this);q._signal("editor",this)};(function(){e.implement(this,p);this.$initOperationListeners=function(){this.selections=[];this.commands.on("exec",this.startOperation.bind(this),!0);this.commands.on("afterExec",this.endOperation.bind(this),!0);this.$opResetTimer=b.delayedCall(this.endOperation.bind(this));this.on("change",function(){this.curOp||this.startOperation();this.curOp.docChanged=
!0}.bind(this),!0);this.on("changeSelection",function(){this.curOp||this.startOperation();this.curOp.selectionChanged=!0}.bind(this),!0)};this.curOp=null;this.prevOp={};this.startOperation=function(a){if(this.curOp){if(!a||this.curOp.command)return;this.prevOp=this.curOp}a||(this.previousCommand=null,a={});this.$opResetTimer.schedule();this.curOp={command:a.command||{},args:a.args,scrollTop:this.renderer.scrollTop};this.curOp.command.name&&void 0!==this.curOp.command.scrollIntoView&&this.$blockScrolling++};
this.endOperation=function(a){if(this.curOp){if(a&&!1===a.returnValue)return this.curOp=null;this._signal("beforeEndOperation");a=this.curOp.command;a.name&&0<this.$blockScrolling&&this.$blockScrolling--;if(a=a&&a.scrollIntoView){switch(a){case "center-animate":a="animate";case "center":this.renderer.scrollCursorIntoView(null,.5);break;case "animate":case "cursor":this.renderer.scrollCursorIntoView();break;case "selectionPart":var b=this.selection.getRange(),d=this.renderer.layerConfig;(b.start.row>=
d.lastRow||b.end.row<=d.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead)}"animate"==a&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.prevOp=this.curOp;this.curOp=null}};this.$mergeableCommands=["backspace","del","insertstring"];this.$historyTracker=function(a){if(this.$mergeUndoDeltas){var b=this.prevOp,d=this.$mergeableCommands,c=b.command&&a.command.name==b.command.name;if("insertstring"==a.command.name){var e=a.args;void 0===this.mergeNextCommand&&
(this.mergeNextCommand=!0);c=c&&this.mergeNextCommand&&(!/\s/.test(e)||/\s/.test(b.args));this.mergeNextCommand=!0}else c=c&&-1!==d.indexOf(a.command.name);"always"!=this.$mergeUndoDeltas&&2E3<Date.now()-this.sequenceStartTime&&(c=!1);c?this.session.mergeUndoDeltas=!0:-1!==d.indexOf(a.command.name)&&(this.sequenceStartTime=Date.now())}};this.setKeyboardHandler=function(a,b){if(a&&"string"===typeof a){this.$keybindingId=a;var d=this;q.loadModule(["keybinding",a],function(c){d.$keybindingId==a&&d.keyBinding.setKeyboardHandler(c&&
c.handler);b&&b()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(a),b&&b()};this.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()};this.setSession=function(a){if(this.session!=a){this.curOp&&this.endOperation();this.curOp={};var b=this.session;if(b){this.session.removeEventListener("change",this.$onDocumentChange);this.session.removeEventListener("changeMode",this.$onChangeMode);this.session.removeEventListener("tokenizerUpdate",this.$onTokenizerUpdate);
this.session.removeEventListener("changeTabSize",this.$onChangeTabSize);this.session.removeEventListener("changeWrapLimit",this.$onChangeWrapLimit);this.session.removeEventListener("changeWrapMode",this.$onChangeWrapMode);this.session.removeEventListener("onChangeFold",this.$onChangeFold);this.session.removeEventListener("changeFrontMarker",this.$onChangeFrontMarker);this.session.removeEventListener("changeBackMarker",this.$onChangeBackMarker);this.session.removeEventListener("changeBreakpoint",this.$onChangeBreakpoint);
this.session.removeEventListener("changeAnnotation",this.$onChangeAnnotation);this.session.removeEventListener("changeOverwrite",this.$onCursorChange);this.session.removeEventListener("changeScrollTop",this.$onScrollTopChange);this.session.removeEventListener("changeScrollLeft",this.$onScrollLeftChange);var d=this.session.getSelection();d.removeEventListener("changeCursor",this.$onCursorChange);d.removeEventListener("changeSelection",this.$onSelectionChange)}(this.session=a)?(this.$onDocumentChange=
this.onDocumentChange.bind(this),a.addEventListener("change",this.$onDocumentChange),this.renderer.setSession(a),this.$onChangeMode=this.onChangeMode.bind(this),a.addEventListener("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),a.addEventListener("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),a.addEventListener("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),
a.addEventListener("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),a.addEventListener("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),a.addEventListener("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.addEventListener("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.addEventListener("changeBackMarker",
this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.addEventListener("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.addEventListener("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.addEventListener("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.addEventListener("changeScrollTop",
this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.addEventListener("changeScrollLeft",this.$onScrollLeftChange),this.selection=a.getSelection(),this.selection.addEventListener("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.addEventListener("changeSelection",this.$onSelectionChange),this.onChangeMode(),this.$blockScrolling+=1,this.onCursorChange(),this.$blockScrolling-=1,this.onScrollTopChange(),
this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(a));this._signal("changeSession",{session:a,oldSession:b});this.curOp=null;b&&b._signal("changeEditor",{oldEditor:this});a&&a._signal("changeEditor",{editor:this})}};this.getSession=function(){return this.session};
this.setValue=function(a,b){this.session.doc.setValue(a);b?1==b?this.navigateFileEnd():-1==b&&this.navigateFileStart():this.selectAll();return a};this.getValue=function(){return this.session.getValue()};this.getSelection=function(){return this.selection};this.resize=function(a){this.renderer.onResize(a)};this.setTheme=function(a,b){this.renderer.setTheme(a,b)};this.getTheme=function(){return this.renderer.getTheme()};this.setStyle=function(a){this.renderer.setStyle(a)};this.unsetStyle=function(a){this.renderer.unsetStyle(a)};
this.getFontSize=function(){return this.getOption("fontSize")||m.computedStyle(this.container,"fontSize")};this.setFontSize=function(a){this.setOption("fontSize",a)};this.$highlightBrackets=function(){this.session.$bracketHighlight&&(this.session.removeMarker(this.session.$bracketHighlight),this.session.$bracketHighlight=null);if(!this.$highlightPending){var a=this;this.$highlightPending=!0;setTimeout(function(){a.$highlightPending=!1;var b=a.session;if(b&&b.bgTokenizer){var d=b.findMatchingBracket(a.getCursorPosition());
if(d)var c=new l(d.row,d.column,d.row,d.column+1);else b.$mode.getMatching&&(c=b.$mode.getMatching(a.session));c&&(b.$bracketHighlight=b.addMarker(c,"ace_bracket","text"))}},50)}};this.$highlightTags=function(){if(!this.$highlightTagPending){var a=this;this.$highlightTagPending=!0;setTimeout(function(){a.$highlightTagPending=!1;var b=a.session;if(b&&b.bgTokenizer){var d=a.getCursorPosition(),c=new v(a.session,d.row,d.column);if((d=c.getCurrentToken())&&/\b(?:tag-open|tag-name)/.test(d.type)){if(-1!=
d.type.indexOf("tag-open")&&(d=c.stepForward(),!d))return;var e=d.value,g=0,h=c.stepBackward();if("<"==h.value){do h=d,(d=c.stepForward())&&d.value===e&&-1!==d.type.indexOf("tag-name")&&("<"===h.value?g++:"</"===h.value&&g--);while(d&&0<=g)}else{do d=h,h=c.stepBackward(),d&&d.value===e&&-1!==d.type.indexOf("tag-name")&&("<"===h.value?g++:"</"===h.value&&g--);while(h&&0>=g);c.stepForward()}d?(e=c.getCurrentTokenRow(),c=c.getCurrentTokenColumn(),d=new l(e,c,e,c+d.value.length),b.$tagHighlight&&0!==
d.compareRange(b.$backMarkers[b.$tagHighlight].range)&&(b.removeMarker(b.$tagHighlight),b.$tagHighlight=null),d&&!b.$tagHighlight&&(b.$tagHighlight=b.addMarker(d,"ace_bracket","text"))):(b.removeMarker(b.$tagHighlight),b.$tagHighlight=null)}else b.removeMarker(b.$tagHighlight),b.$tagHighlight=null}},50)}};this.focus=function(){var a=this;setTimeout(function(){a.textInput.focus()});this.textInput.focus()};this.isFocused=function(){return this.textInput.isFocused()};this.blur=function(){this.textInput.blur()};
this.onFocus=function(a){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",a))};this.onBlur=function(a){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",a))};this.$cursorChange=function(){this.renderer.updateCursor()};this.onDocumentChange=function(a){this.renderer.updateLines(a.start.row,a.start.row==a.end.row?a.end.row:Infinity,this.session.$useWrapMode);this._signal("change",
a);this.$cursorChange();this.$updateHighlightActiveLine()};this.onTokenizerUpdate=function(a){a=a.data;this.renderer.updateLines(a.first,a.last)};this.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())};this.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())};this.onCursorChange=function(){this.$cursorChange();this.$blockScrolling||(q.warn("Automatically scrolling cursor into view after selection change","this will be disabled in the next version",
"set editor.$blockScrolling = Infinity to disable this message"),this.renderer.scrollCursorIntoView());this.$highlightBrackets();this.$highlightTags();this.$updateHighlightActiveLine();this._signal("changeSelection")};this.$updateHighlightActiveLine=function(){var a=this.getSession(),b;this.$highlightActiveLine&&("line"==this.$selectionStyle&&this.selection.isMultiLine()||(b=this.getCursorPosition()),!this.renderer.$maxLines||1!==this.session.getLength()||1<this.renderer.$minLines||(b=!1));a.$highlightLineMarker&&
!b?(a.removeMarker(a.$highlightLineMarker.id),a.$highlightLineMarker=null):!a.$highlightLineMarker&&b?(b=new l(b.row,b.column,b.row,Infinity),b.id=a.addMarker(b,"ace_active-line","screenLine"),a.$highlightLineMarker=b):b&&(a.$highlightLineMarker.start.row=b.row,a.$highlightLineMarker.end.row=b.row,a.$highlightLineMarker.start.column=b.column,a._signal("changeBackMarker"))};this.onSelectionChange=function(a){a=this.session;a.$selectionMarker&&a.removeMarker(a.$selectionMarker);a.$selectionMarker=null;
if(this.selection.isEmpty())this.$updateHighlightActiveLine();else{var b=this.selection.getRange(),d=this.getSelectionStyle();a.$selectionMarker=a.addMarker(b,"ace_selection",d)}a=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(a);this._signal("changeSelection")};this.$getSelectionHighLightRegexp=function(){var a=this.session,b=this.getSelectionRange();if(!b.isEmpty()&&!b.isMultiLine()){var d=b.start.column-1,c=b.end.column+1,a=a.getLine(b.start.row),e=a.length,
g=a.substring(Math.max(d,0),Math.min(c,e));if(!(0<=d&&/^[\w\d]/.test(g)||c<=e&&/[\w\d]$/.test(g))&&(g=a.substring(b.start.column,b.end.column),/^[\w\d]+$/.test(g)))return this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:g})}};this.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()};this.onChangeBackMarker=function(){this.renderer.updateBackMarkers()};this.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()};this.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())};
this.onChangeMode=function(a){this.renderer.updateText();this._emit("changeMode",a)};this.onChangeWrapLimit=function(){this.renderer.updateFull()};this.onChangeWrapMode=function(){this.renderer.onResize(!0)};this.onChangeFold=function(){this.$updateHighlightActiveLine();this.renderer.updateFull()};this.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())};this.getCopyText=function(){var a=this.getSelectedText();this._signal("copy",a);return a};this.onCopy=function(){this.commands.exec("copy",
this)};this.onCut=function(){this.commands.exec("cut",this)};this.onPaste=function(a,b){this.commands.exec("paste",this,{text:a,event:b})};this.$handlePaste=function(a){"string"==typeof a&&(a={text:a});this._signal("paste",a);var b=a.text;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)this.insert(b);else{a=b.split(/\r\n|\r|\n/);var d=this.selection.rangeList.ranges;if(a.length>d.length||2>a.length||!a[1])return this.commands.exec("insertstring",this,b);for(b=d.length;b--;){var c=d[b];c.isEmpty()||
this.session.remove(c);this.session.insert(c.start,a[b])}}};this.execCommand=function(a,b){return this.commands.exec(a,this,b)};this.insert=function(a,b){var d=this.session,c=d.getMode(),e=this.getCursorPosition();if(this.getBehavioursEnabled()&&!b){var g=c.transformAction(d.getState(e.row),"insertion",this,d,a);g&&(a!==g.text&&(this.$mergeNextCommand=this.session.mergeUndoDeltas=!1),a=g.text)}"\t"==a&&(a=this.session.getTabString());if(this.selection.isEmpty())this.session.getOverwrite()&&(h=new l.fromPoints(e,
e),h.end.column+=a.length,this.session.remove(h));else{var h=this.getSelectionRange(),e=this.session.remove(h);this.clearSelection()}if("\n"==a||"\r\n"==a){var f=d.getLine(e.row);e.column>f.search(/\S|$/)&&(h=f.substr(e.column).search(/\S|$/),d.doc.removeInLine(e.row,e.column,e.column+h))}this.clearSelection();var n=e.column,h=d.getState(e.row),f=d.getLine(e.row),s=c.checkOutdent(h,f,a);d.insert(e,a);g&&g.selection&&(2==g.selection.length?this.selection.setSelectionRange(new l(e.row,n+g.selection[0],
e.row,n+g.selection[1])):this.selection.setSelectionRange(new l(e.row+g.selection[0],g.selection[1],e.row+g.selection[2],g.selection[3])));d.getDocument().isNewLine(a)&&(g=c.getNextLineIndent(h,f.slice(0,e.column),d.getTabString()),d.insert({row:e.row+1,column:0},g));s&&c.autoOutdent(h,d,e.row)};this.onTextInput=function(a){this.keyBinding.onTextInput(a)};this.onCommandKey=function(a,b,d){this.keyBinding.onCommandKey(a,b,d)};this.setOverwrite=function(a){this.session.setOverwrite(a)};this.getOverwrite=
function(){return this.session.getOverwrite()};this.toggleOverwrite=function(){this.session.toggleOverwrite()};this.setScrollSpeed=function(a){this.setOption("scrollSpeed",a)};this.getScrollSpeed=function(){return this.getOption("scrollSpeed")};this.setDragDelay=function(a){this.setOption("dragDelay",a)};this.getDragDelay=function(){return this.getOption("dragDelay")};this.setSelectionStyle=function(a){this.setOption("selectionStyle",a)};this.getSelectionStyle=function(){return this.getOption("selectionStyle")};
this.setHighlightActiveLine=function(a){this.setOption("highlightActiveLine",a)};this.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")};this.setHighlightGutterLine=function(a){this.setOption("highlightGutterLine",a)};this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")};this.setHighlightSelectedWord=function(a){this.setOption("highlightSelectedWord",a)};this.getHighlightSelectedWord=function(){return this.$highlightSelectedWord};this.setAnimatedScroll=
function(a){this.renderer.setAnimatedScroll(a)};this.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()};this.setShowInvisibles=function(a){this.renderer.setShowInvisibles(a)};this.getShowInvisibles=function(){return this.renderer.getShowInvisibles()};this.setDisplayIndentGuides=function(a){this.renderer.setDisplayIndentGuides(a)};this.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()};this.setShowPrintMargin=function(a){this.renderer.setShowPrintMargin(a)};
this.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()};this.setPrintMarginColumn=function(a){this.renderer.setPrintMarginColumn(a)};this.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()};this.setReadOnly=function(a){this.setOption("readOnly",a)};this.getReadOnly=function(){return this.getOption("readOnly")};this.setBehavioursEnabled=function(a){this.setOption("behavioursEnabled",a)};this.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")};
this.setWrapBehavioursEnabled=function(a){this.setOption("wrapBehavioursEnabled",a)};this.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")};this.setShowFoldWidgets=function(a){this.setOption("showFoldWidgets",a)};this.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")};this.setFadeFoldWidgets=function(a){this.setOption("fadeFoldWidgets",a)};this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")};this.remove=function(a){this.selection.isEmpty()&&
("left"==a?this.selection.selectLeft():this.selection.selectRight());a=this.getSelectionRange();if(this.getBehavioursEnabled()){var b=this.session,d=b.getState(a.start.row),d=b.getMode().transformAction(d,"deletion",this,b,a);if(0===a.end.column){var c=b.getTextRange(a);"\n"==c[c.length-1]&&(b=b.getLine(a.end.row),/^\s+$/.test(b)&&(a.end.column=b.length))}d&&(a=d)}this.session.remove(a);this.clearSelection()};this.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight();
this.session.remove(this.getSelectionRange());this.clearSelection()};this.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft();this.session.remove(this.getSelectionRange());this.clearSelection()};this.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart();this.session.remove(this.getSelectionRange());this.clearSelection()};this.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var a=this.getSelectionRange();
a.start.column==a.end.column&&a.start.row==a.end.row&&(a.end.column=0,a.end.row++);this.session.remove(a);this.clearSelection()};this.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var a=this.getCursorPosition();this.insert("\n");this.moveCursorToPosition(a)};this.transposeLetters=function(){if(this.selection.isEmpty()){var a=this.getCursorPosition(),b=a.column;if(0!==b){var d=this.session.getLine(a.row);b<d.length?(d=d.charAt(b)+
d.charAt(b-1),a=new l(a.row,b-1,a.row,b+1)):(d=d.charAt(b-1)+d.charAt(b-2),a=new l(a.row,b-2,a.row,b));this.session.replace(a,d)}}};this.toLowerCase=function(){var a=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var b=this.getSelectionRange(),d=this.session.getTextRange(b);this.session.replace(b,d.toLowerCase());this.selection.setSelectionRange(a)};this.toUpperCase=function(){var a=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var b=
this.getSelectionRange(),d=this.session.getTextRange(b);this.session.replace(b,d.toUpperCase());this.selection.setSelectionRange(a)};this.indent=function(){var a=this.session,d=this.getSelectionRange();if(d.start.row<d.end.row)d=this.$getSelectedRows(),a.indentRows(d.first,d.last,"\t");else{if(d.start.column<d.end.column){var c=a.getTextRange(d);if(!/^\s+$/.test(c)){d=this.$getSelectedRows();a.indentRows(d.first,d.last,"\t");return}}var c=a.getLine(d.start.row),e=d.start,g=a.getTabSize(),a=a.documentToScreenColumn(e.row,
e.column);if(this.session.getUseSoftTabs())d=b.stringRepeat(" ",g-a%g);else{for(a%=g;" "==c[d.start.column]&&a;)d.start.column--,a--;this.selection.setSelectionRange(d);d="\t"}return this.insert(d)}};this.blockIndent=function(){var a=this.$getSelectedRows();this.session.indentRows(a.first,a.last,"\t")};this.blockOutdent=function(){var a=this.session.getSelection();this.session.outdentRows(a.getRange())};this.sortLines=function(){for(var a=this.$getSelectedRows(),b=this.session,d=[],c=a.first;c<=a.last;c++)d.push(b.getLine(c));
d.sort(function(a,b){return a.toLowerCase()<b.toLowerCase()?-1:a.toLowerCase()>b.toLowerCase()?1:0});for(var e=new l(0,0,0,0),c=a.first;c<=a.last;c++){var g=b.getLine(c);e.start.row=c;e.end.row=c;e.end.column=g.length;b.replace(e,d[c-a.first])}};this.toggleCommentLines=function(){var a=this.session.getState(this.getCursorPosition().row),b=this.$getSelectedRows();this.session.getMode().toggleCommentLines(a,this.session,b.first,b.last)};this.toggleBlockComment=function(){var a=this.getCursorPosition(),
b=this.session.getState(a.row),d=this.getSelectionRange();this.session.getMode().toggleBlockComment(b,this.session,d,a)};this.getNumberAt=function(a,b){var d=/[\-]?[0-9]+(?:\.[0-9]+)?/g;d.lastIndex=0;for(var c=this.session.getLine(a);d.lastIndex<b;){var e=d.exec(c);if(e.index<=b&&e.index+e[0].length>=b)return{value:e[0],start:e.index,end:e.index+e[0].length}}return null};this.modifyNumber=function(a){var b=this.selection.getCursor().row,d=this.selection.getCursor().column,c=new l(b,d-1,b,d),c=this.session.getTextRange(c);
if(!isNaN(parseFloat(c))&&isFinite(c)&&(c=this.getNumberAt(b,d))){var e=0<=c.value.indexOf(".")?c.start+c.value.indexOf(".")+1:c.end,g=c.start+c.value.length-e,h=parseFloat(c.value),h=h*Math.pow(10,g);a=e!==c.end&&d<e?a*Math.pow(10,c.end-d-1):a*Math.pow(10,c.end-d);h=(h+a)/Math.pow(10,g);a=h.toFixed(g);e=new l(b,c.start,b,c.end);this.session.replace(e,a);this.moveCursorTo(b,Math.max(c.start+1,d+a.length-c.value.length))}};this.removeLines=function(){var a=this.$getSelectedRows();this.session.removeFullLines(a.first,
a.last);this.clearSelection()};this.duplicateSelection=function(){var a=this.selection,b=this.session,d=a.getRange(),c=a.isBackwards();if(d.isEmpty())a=d.start.row,b.duplicateLines(a,a);else{var e=c?d.start:d.end,b=b.insert(e,b.getTextRange(d),!1);d.start=e;d.end=b;a.setSelectionRange(d,c)}};this.moveLinesDown=function(){this.$moveLines(1,!1)};this.moveLinesUp=function(){this.$moveLines(-1,!1)};this.moveText=function(a,b,d){return this.session.moveText(a,b,d)};this.copyLinesUp=function(){this.$moveLines(-1,
!0)};this.copyLinesDown=function(){this.$moveLines(1,!0)};this.$moveLines=function(a,b){var d,c,e=this.selection;if(!e.inMultiSelectMode||this.inVirtualSelectionMode){var g=e.toOrientedRange();d=this.$getSelectedRows(g);c=this.session.$moveLines(d.first,d.last,b?0:a);b&&-1==a&&(c=0);g.moveBy(c,0);e.fromOrientedRange(g)}else{g=e.rangeList.ranges;e.rangeList.detach(this.session);this.inVirtualSelectionMode=!0;var h=0;c=0;for(var f=g.length,l=0;l<f;l++){var n=l;g[l].moveBy(h,0);d=this.$getSelectedRows(g[l]);
h=d.first;for(d=d.last;++l<f;){c&&g[l].moveBy(c,0);var s=this.$getSelectedRows(g[l]);if(b&&s.first!=d)break;else if(!b&&s.first>d+1)break;d=s.last}l--;h=this.session.$moveLines(h,d,b?0:a);for(b&&-1==a&&(n=l+1);n<=l;)g[n].moveBy(h,0),n++;b||(h=0);c+=h}e.fromOrientedRange(e.ranges[0]);e.rangeList.attach(this.session);this.inVirtualSelectionMode=!1}};this.$getSelectedRows=function(a){a=(a||this.getSelectionRange()).collapseRows();return{first:this.session.getRowFoldStart(a.start.row),last:this.session.getRowFoldEnd(a.end.row)}};
this.onCompositionStart=function(a){this.renderer.showComposition(this.getCursorPosition())};this.onCompositionUpdate=function(a){this.renderer.setCompositionText(a)};this.onCompositionEnd=function(){this.renderer.hideComposition()};this.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()};this.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()};this.isRowVisible=function(a){return a>=this.getFirstVisibleRow()&&a<=this.getLastVisibleRow()};this.isRowFullyVisible=
function(a){return a>=this.renderer.getFirstFullyVisibleRow()&&a<=this.renderer.getLastFullyVisibleRow()};this.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1};this.$moveByPage=function(a,b){var d=this.renderer,c=this.renderer.layerConfig,e=a*Math.floor(c.height/c.lineHeight);this.$blockScrolling++;!0===b?this.selection.$moveSelection(function(){this.moveCursorBy(e,0)}):!1===b&&(this.selection.moveCursorBy(e,0),this.selection.clearSelection());
this.$blockScrolling--;var g=d.scrollTop;d.scrollBy(0,e*c.lineHeight);null!=b&&d.scrollCursorIntoView(null,.5);d.animateScrolling(g)};this.selectPageDown=function(){this.$moveByPage(1,!0)};this.selectPageUp=function(){this.$moveByPage(-1,!0)};this.gotoPageDown=function(){this.$moveByPage(1,!1)};this.gotoPageUp=function(){this.$moveByPage(-1,!1)};this.scrollPageDown=function(){this.$moveByPage(1)};this.scrollPageUp=function(){this.$moveByPage(-1)};this.scrollToRow=function(a){this.renderer.scrollToRow(a)};
this.scrollToLine=function(a,b,d,c){this.renderer.scrollToLine(a,b,d,c)};this.centerSelection=function(){var a=this.getSelectionRange();this.renderer.alignCursor({row:Math.floor(a.start.row+(a.end.row-a.start.row)/2),column:Math.floor(a.start.column+(a.end.column-a.start.column)/2)},.5)};this.getCursorPosition=function(){return this.selection.getCursor()};this.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())};this.getSelectionRange=function(){return this.selection.getRange()};
this.selectAll=function(){this.$blockScrolling+=1;this.selection.selectAll();this.$blockScrolling-=1};this.clearSelection=function(){this.selection.clearSelection()};this.moveCursorTo=function(a,b){this.selection.moveCursorTo(a,b)};this.moveCursorToPosition=function(a){this.selection.moveCursorToPosition(a)};this.jumpToMatching=function(a,b){var d=this.getCursorPosition(),c=new v(this.session,d.row,d.column),e=c.getCurrentToken(),g=e||c.stepForward();if(g){var h,f=!1,n={},s=d.column-g.start,p,k={")":"(",
"(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(g.value.match(/[{}()\[\]]/g))for(;s<g.value.length&&!f;s++){if(k[g.value[s]])switch(p=k[g.value[s]]+"."+g.type.replace("rparen","lparen"),isNaN(n[p])&&(n[p]=0),g.value[s]){case "(":case "[":case "{":n[p]++;break;case ")":case "]":case "}":n[p]--,-1===n[p]&&(h="bracket",f=!0)}}else g&&-1!==g.type.indexOf("tag-name")&&(isNaN(n[g.value])&&(n[g.value]=0),"<"===e.value?n[g.value]++:"</"===e.value&&n[g.value]--,-1===n[g.value]&&(h="tag",f=!0));f||(e=g,g=c.stepForward(),
s=0)}while(g&&!f);if(h){var q,m;if("bracket"===h){if(q=this.session.getBracketRange(d),!q&&(q=new l(c.getCurrentTokenRow(),c.getCurrentTokenColumn()+s-1,c.getCurrentTokenRow(),c.getCurrentTokenColumn()+s-1),m=q.start,b||m.row===d.row&&2>Math.abs(m.column-d.column)))q=this.session.getBracketRange(m)}else if("tag"===h){if(g&&-1!==g.type.indexOf("tag-name"))h=g.value;else return;q=new l(c.getCurrentTokenRow(),c.getCurrentTokenColumn()-2,c.getCurrentTokenRow(),c.getCurrentTokenColumn()-2);if(0===q.compare(d.row,
d.column)){f=!1;do if(g=e,e=c.stepBackward())-1!==e.type.indexOf("tag-close")&&q.setEnd(c.getCurrentTokenRow(),c.getCurrentTokenColumn()+1),g.value===h&&-1!==g.type.indexOf("tag-name")&&("<"===e.value?n[h]++:"</"===e.value&&n[h]--,0===n[h]&&(f=!0));while(e&&!f)}g&&g.type.indexOf("tag-name")&&(m=q.start,m.row==d.row&&2>Math.abs(m.column-d.column)&&(m=q.end))}(m=q&&q.cursor||m)&&(a?q&&b?this.selection.setRange(q):q&&q.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(m.row,
m.column):this.selection.moveTo(m.row,m.column))}}};this.gotoLine=function(a,b,d){this.selection.clearSelection();this.session.unfold({row:a-1,column:b||0});this.$blockScrolling+=1;this.exitMultiSelectMode&&this.exitMultiSelectMode();this.moveCursorTo(a-1,b||0);this.$blockScrolling-=1;this.isRowFullyVisible(a-1)||this.scrollToLine(a-1,!0,d)};this.navigateTo=function(a,b){this.selection.moveTo(a,b)};this.navigateUp=function(a){if(this.selection.isMultiLine()&&!this.selection.isBackwards())return a=
this.selection.anchor.getPosition(),this.moveCursorToPosition(a);this.selection.clearSelection();this.selection.moveCursorBy(-a||-1,0)};this.navigateDown=function(a){if(this.selection.isMultiLine()&&this.selection.isBackwards())return a=this.selection.anchor.getPosition(),this.moveCursorToPosition(a);this.selection.clearSelection();this.selection.moveCursorBy(a||1,0)};this.navigateLeft=function(a){if(this.selection.isEmpty())for(a=a||1;a--;)this.selection.moveCursorLeft();else a=this.getSelectionRange().start,
this.moveCursorToPosition(a);this.clearSelection()};this.navigateRight=function(a){if(this.selection.isEmpty())for(a=a||1;a--;)this.selection.moveCursorRight();else a=this.getSelectionRange().end,this.moveCursorToPosition(a);this.clearSelection()};this.navigateLineStart=function(){this.selection.moveCursorLineStart();this.clearSelection()};this.navigateLineEnd=function(){this.selection.moveCursorLineEnd();this.clearSelection()};this.navigateFileEnd=function(){this.selection.moveCursorFileEnd();this.clearSelection()};
this.navigateFileStart=function(){this.selection.moveCursorFileStart();this.clearSelection()};this.navigateWordRight=function(){this.selection.moveCursorWordRight();this.clearSelection()};this.navigateWordLeft=function(){this.selection.moveCursorWordLeft();this.clearSelection()};this.replace=function(a,b){b&&this.$search.set(b);var d=this.$search.find(this.session),c=0;if(!d)return c;this.$tryReplace(d,a)&&(c=1);null!==d&&(this.selection.setSelectionRange(d),this.renderer.scrollSelectionIntoView(d.start,
d.end));return c};this.replaceAll=function(a,b){b&&this.$search.set(b);var d=this.$search.findAll(this.session),c=0;if(!d.length)return c;this.$blockScrolling+=1;var e=this.getSelectionRange();this.selection.moveTo(0,0);for(var g=d.length-1;0<=g;--g)this.$tryReplace(d[g],a)&&c++;this.selection.setSelectionRange(e);this.$blockScrolling-=1;return c};this.$tryReplace=function(a,b){var d=this.session.getTextRange(a);b=this.$search.replace(d,b);return null!==b?(a.end=this.session.replace(a,b),a):null};
this.getLastSearchOptions=function(){return this.$search.getOptions()};this.find=function(a,b,d){b||(b={});"string"==typeof a||a instanceof RegExp?b.needle=a:"object"==typeof a&&e.mixin(b,a);var c=this.selection.getRange();null==b.needle&&(a=this.session.getTextRange(c)||this.$search.$options.needle,a||(c=this.session.getWordRange(c.start.row,c.start.column),a=this.session.getTextRange(c)),this.$search.set({needle:a}));this.$search.set(b);b.start||this.$search.set({start:c});a=this.$search.find(this.session);
if(b.preventScroll)return a;if(a)return this.revealRange(a,d),a;b.backwards?c.start=c.end:c.end=c.start;this.selection.setRange(c)};this.findNext=function(a,b){this.find({skipCurrent:!0,backwards:!1},a,b)};this.findPrevious=function(a,b){this.find(a,{skipCurrent:!0,backwards:!0},b)};this.revealRange=function(a,b){this.$blockScrolling+=1;this.session.unfold(a);this.selection.setSelectionRange(a);this.$blockScrolling-=1;var d=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(a.start,a.end,
.5);!1!==b&&this.renderer.animateScrolling(d)};this.undo=function(){this.$blockScrolling++;this.session.getUndoManager().undo();this.$blockScrolling--;this.renderer.scrollCursorIntoView(null,.5)};this.redo=function(){this.$blockScrolling++;this.session.getUndoManager().redo();this.$blockScrolling--;this.renderer.scrollCursorIntoView(null,.5)};this.destroy=function(){this.renderer.destroy();this._signal("destroy",this);this.session&&this.session.destroy()};this.setAutoScrollEditorIntoView=function(a){if(a){var b,
d=this,c=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var e=this.$scrollAnchor;e.style.cssText="position:absolute";this.container.insertBefore(e,this.container.firstChild);var g=this.on("changeSelection",function(){c=!0}),h=this.renderer.on("beforeRender",function(){c&&(b=d.renderer.container.getBoundingClientRect())}),f=this.renderer.on("afterRender",function(){if(c&&b&&(d.isFocused()||d.searchBox&&d.searchBox.isFocused())){var a=d.renderer,g=a.$cursorLayer.$pixelPos,
a=a.layerConfig,h=g.top-a.offset;c=0<=g.top&&0>h+b.top?!0:g.top<a.height&&g.top+b.top+a.lineHeight>window.innerHeight?!1:null;null!=c&&(e.style.top=h+"px",e.style.left=g.left+"px",e.style.height=a.lineHeight+"px",e.scrollIntoView(c));c=b=null}});this.setAutoScrollEditorIntoView=function(a){a||(delete this.setAutoScrollEditorIntoView,this.removeEventListener("changeSelection",g),this.renderer.removeEventListener("afterRender",f),this.renderer.removeEventListener("beforeRender",h))}}};this.$resetCursorStyle=
function(){var a=this.$cursorStyle||"ace",b=this.renderer.$cursorLayer;b&&(b.setSmoothBlinking(/smooth/.test(a)),b.isBlinking=!this.$readOnly&&"wide"!=a,m.setCssClass(b.element,"ace_slim-cursors",/slim/.test(a)))}}).call(f.prototype);q.defineOptions(f.prototype,"editor",{selectionStyle:{set:function(a){this.onSelectionChange();this._signal("changeSelectionStyle",{data:a})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(a){this.$onSelectionChange()},
initialValue:!0},readOnly:{set:function(a){this.$resetCursorStyle()},initialValue:!1},cursorStyle:{set:function(a){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},autoScrollEditorIntoView:{set:function(a){this.setAutoScrollEditorIntoView(a)}},hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",
animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",showLineNumbers:"renderer",showGutter:"renderer",displayIndentGuides:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimout:"$mouseHandler",
tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});k.Editor=f});
define("ace/undomanager",["require","exports","module"],function(f,k,r){f=function(){this.reset()};(function(){function e(b){return{action:b.action,start:b.start,end:b.end,lines:1==b.lines.length?null:b.lines,text:1==b.lines.length?b.lines[0]:null}}function f(b){return{action:b.action,start:b.start,end:b.end,lines:b.lines||[b.text]}}function b(b,a){for(var d=Array(b.length),e=0;e<b.length;e++){for(var f=b[e],h={group:f.group,deltas:Array(f.length)},k=0;k<f.deltas.length;k++)h.deltas[k]=a(f.deltas[k]);
d[e]=h}return d}this.execute=function(b){var a=b.args[0];this.$doc=b.args[1];b.merge&&this.hasUndo()&&(this.dirtyCounter--,a=this.$undoStack.pop().concat(a));this.$undoStack.push(a);this.$redoStack=[];0>this.dirtyCounter&&(this.dirtyCounter=NaN);this.dirtyCounter++};this.undo=function(b){var a=this.$undoStack.pop(),d=null;a&&(d=this.$doc.undoChanges(this.$deserializeDeltas(a),b),this.$redoStack.push(a),this.dirtyCounter--);return d};this.redo=function(b){var a=this.$redoStack.pop(),d=null;a&&(d=this.$doc.redoChanges(this.$deserializeDeltas(a),
b),this.$undoStack.push(a),this.dirtyCounter++);return d};this.reset=function(){this.$undoStack=[];this.$redoStack=[];this.dirtyCounter=0};this.hasUndo=function(){return 0<this.$undoStack.length};this.hasRedo=function(){return 0<this.$redoStack.length};this.markClean=function(){this.dirtyCounter=0};this.isClean=function(){return 0===this.dirtyCounter};this.$serializeDeltas=function(c){return b(c,e)};this.$deserializeDeltas=function(c){return b(c,f)}}).call(f.prototype);k.UndoManager=f});
define("ace/layer/gutter","require exports module ace/lib/dom ace/lib/oop ace/lib/lang ace/lib/event_emitter".split(" "),function(f,k,r){var e=f("../lib/dom"),m=f("../lib/oop"),b=f("../lib/lang"),c=f("../lib/event_emitter").EventEmitter;f=function(a){this.element=e.createElement("div");this.element.className="ace_layer ace_gutter-layer";a.appendChild(this.element);this.setShowFoldWidgets(this.$showFoldWidgets);this.gutterWidth=0;this.$annotations=[];this.$updateAnnotations=this.$updateAnnotations.bind(this);
this.$cells=[]};(function(){m.implement(this,c);this.setSession=function(a){this.session&&this.session.removeEventListener("change",this.$updateAnnotations);if(this.session=a)a.on("change",this.$updateAnnotations)};this.addGutterDecoration=function(a,b){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration");this.session.addGutterDecoration(a,b)};this.removeGutterDecoration=function(a,b){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration");
this.session.removeGutterDecoration(a,b)};this.setAnnotations=function(a){this.$annotations=[];for(var d=0;d<a.length;d++){var c=a[d],e=c.row,h=this.$annotations[e];h||(h=this.$annotations[e]={text:[]});e=(e=c.text)?b.escapeHTML(e):c.html||"";-1===h.text.indexOf(e)&&h.text.push(e);c=c.type;"error"==c?h.className=" ace_error":"warning"==c&&" ace_error"!=h.className?h.className=" ace_warning":"info"!=c||h.className||(h.className=" ace_info")}};this.$updateAnnotations=function(a){if(this.$annotations.length){var b=
a.start.row,c=a.end.row-b;0!==c&&("remove"==a.action?this.$annotations.splice(b,c+1,null):(a=Array(c+1),a.unshift(b,1),this.$annotations.splice.apply(this.$annotations,a)))}};this.update=function(a){for(var b=this.session,c=a.firstRow,f=Math.min(a.lastRow+a.gutterOffset,b.getLength()-1),h=b.getNextFoldLine(c),k=h?h.start.row:Infinity,l=this.$showFoldWidgets&&b.foldWidgets,p=b.$breakpoints,m=b.$decorations,s=b.$firstLineNumber,q=0,v=b.gutterRenderer||this.$renderer,u=null,r=-1;;){c>k&&(c=h.end.row+
1,k=(h=b.getNextFoldLine(c,h))?h.start.row:Infinity);if(c>f){for(;this.$cells.length>r+1;)u=this.$cells.pop(),this.element.removeChild(u.element);break}u=this.$cells[++r];u||(u={element:null,textNode:null,foldWidget:null},u.element=e.createElement("div"),u.textNode=document.createTextNode(""),u.element.appendChild(u.textNode),this.element.appendChild(u.element),this.$cells[r]=u);q="ace_gutter-cell ";p[c]&&(q+=p[c]);m[c]&&(q+=m[c]);this.$annotations[c]&&(q+=this.$annotations[c].className);u.element.className!=
q&&(u.element.className=q);q=b.getRowLength(c)*a.lineHeight+"px";q!=u.element.style.height&&(u.element.style.height=q);if(l){var B=l[c];null==B&&(B=l[c]=b.getFoldWidget(c))}B?(u.foldWidget||(u.foldWidget=e.createElement("span"),u.element.appendChild(u.foldWidget)),q="ace_fold-widget ace_"+B,q="start"==B&&c==k&&c<h.end.row?q+" ace_closed":q+" ace_open",u.foldWidget.className!=q&&(u.foldWidget.className=q),q=a.lineHeight+"px",u.foldWidget.style.height!=q&&(u.foldWidget.style.height=q)):u.foldWidget&&
(u.element.removeChild(u.foldWidget),u.foldWidget=null);var I=q=v?v.getText(b,c):c+s;I!=u.textNode.data&&(u.textNode.data=I);c++}this.element.style.height=a.minHeight+"px";if(this.$fixedWidth||b.$useWrapMode)q=b.getLength()+s;a=v?v.getWidth(b,q,a):q.toString().length*a.characterWidth;b=this.$padding||this.$computePadding();a+=b.left+b.right;a===this.gutterWidth||isNaN(a)||(this.gutterWidth=a,this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._emit("changeGutterWidth",a))};this.$fixedWidth=
!1;this.$showLineNumbers=!0;this.$renderer="";this.setShowLineNumbers=function(a){this.$renderer=!a&&{getWidth:function(){return""},getText:function(){return""}}};this.getShowLineNumbers=function(){return this.$showLineNumbers};this.$showFoldWidgets=!0;this.setShowFoldWidgets=function(a){a?e.addCssClass(this.element,"ace_folding-enabled"):e.removeCssClass(this.element,"ace_folding-enabled");this.$showFoldWidgets=a;this.$padding=null};this.getShowFoldWidgets=function(){return this.$showFoldWidgets};
this.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var a=e.computedStyle(this.element.firstChild);this.$padding={};this.$padding.left=parseInt(a.paddingLeft)+1||0;this.$padding.right=parseInt(a.paddingRight)||0;return this.$padding};this.getRegion=function(a){var b=this.$padding||this.$computePadding(),c=this.element.getBoundingClientRect();if(a.x<b.left+c.left)return"markers";if(this.$showFoldWidgets&&a.x>c.right-b.right)return"foldWidgets"}}).call(f.prototype);k.Gutter=
f});
define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(f,k,r){var e=f("../range").Range,m=f("../lib/dom");f=function(b){this.element=m.createElement("div");this.element.className="ace_layer ace_marker-layer";b.appendChild(this.element)};(function(){this.$padding=0;this.setPadding=function(b){this.$padding=b};this.setSession=function(b){this.session=b};this.setMarkers=function(b){this.markers=b};this.update=function(b){if(b=b||this.config){this.config=b;var c=[],
a;for(a in this.markers){var d=this.markers[a];if(d.range){var e=d.range.clipRows(b.firstRow,b.lastRow);if(!e.isEmpty())if(e=e.toScreenRange(this.session),d.renderer){var f=this.$getTop(e.start.row,b);d.renderer(c,e,this.$padding+e.start.column*b.characterWidth,f,b)}else"fullLine"==d.type?this.drawFullLineMarker(c,e,d.clazz,b):"screenLine"==d.type?this.drawScreenLineMarker(c,e,d.clazz,b):e.isMultiLine()?"text"==d.type?this.drawTextMarker(c,e,d.clazz,b):this.drawMultiLineMarker(c,e,d.clazz,b):this.drawSingleLineMarker(c,
e,d.clazz+" ace_start ace_br15",b)}else d.update(c,this,this.session,b)}this.element.innerHTML=c.join("")}};this.$getTop=function(b,c){return(b-c.firstRowScreen)*c.lineHeight};this.drawTextMarker=function(b,c,a,d,g){for(var f=this.session,h=c.start.row,k=c.end.row,l=h,p=0,m=0,s=f.getScreenLastRowColumn(l),q=new e(l,c.start.column,l,m);l<=k;l++)q.start.row=q.end.row=l,q.start.column=l==h?c.start.column:f.getRowWrapIndent(l),q.end.column=s,p=m,m=s,s=l+1<k?f.getScreenLastRowColumn(l+1):l==k?0:c.end.column,
this.drawSingleLineMarker(b,q,a+(l==h?" ace_start":"")+" ace_br"+((l==h||l==h+1&&c.start.column?1:0)|(p<m?2:0)|(m>s?4:0)|(l==k?8:0)),d,l==k?0:1,g)};this.drawMultiLineMarker=function(b,c,a,d,e){var f=this.$padding,h=d.lineHeight,k=this.$getTop(c.start.row,d),l=f+c.start.column*d.characterWidth;e=e||"";b.push("<div class='",a," ace_br1 ace_start' style='","height:",h,"px;","right:0;","top:",k,"px;","left:",l,"px;",e,"'></div>");k=this.$getTop(c.end.row,d);b.push("<div class='",a," ace_br12' style='",
"height:",h,"px;","width:",c.end.column*d.characterWidth,"px;","top:",k,"px;","left:",f,"px;",e,"'></div>");h=(c.end.row-c.start.row-1)*d.lineHeight;0>=h||(k=this.$getTop(c.start.row+1,d),c=(c.start.column?1:0)|(c.end.column?0:8),b.push("<div class='",a,c?" ace_br"+c:"","' style='","height:",h,"px;","right:0;","top:",k,"px;","left:",f,"px;",e,"'></div>"))};this.drawSingleLineMarker=function(b,c,a,d,e,f){var h=d.lineHeight;e=(c.end.column+(e||0)-c.start.column)*d.characterWidth;var k=this.$getTop(c.start.row,
d);b.push("<div class='",a,"' style='","height:",h,"px;","width:",e,"px;","top:",k,"px;","left:",this.$padding+c.start.column*d.characterWidth,"px;",f||"","'></div>")};this.drawFullLineMarker=function(b,c,a,d,e){var f=this.$getTop(c.start.row,d),h=d.lineHeight;c.start.row!=c.end.row&&(h+=this.$getTop(c.end.row,d)-f);b.push("<div class='",a,"' style='","height:",h,"px;","top:",f,"px;","left:0;right:0;",e||"","'></div>")};this.drawScreenLineMarker=function(b,c,a,d,e){c=this.$getTop(c.start.row,d);b.push("<div class='",
a,"' style='","height:",d.lineHeight,"px;","top:",c,"px;","left:0;right:0;",e||"","'></div>")}}).call(f.prototype);k.Marker=f});
define("ace/layer/text","require exports module ace/lib/oop ace/lib/dom ace/lib/lang ace/lib/useragent ace/lib/event_emitter".split(" "),function(f,k,r){var e=f("../lib/oop"),m=f("../lib/dom"),b=f("../lib/lang");f("../lib/useragent");var c=f("../lib/event_emitter").EventEmitter;f=function(a){this.element=m.createElement("div");this.element.className="ace_layer ace_text-layer";a.appendChild(this.element);this.$updateEolChar=this.$updateEolChar.bind(this)};(function(){e.implement(this,c);this.EOF_CHAR=
"\u00b6";this.EOL_CHAR_LF="\u00ac";this.EOL_CHAR_CRLF="\u00a4";this.EOL_CHAR=this.EOL_CHAR_LF;this.TAB_CHAR="\u2014";this.SPACE_CHAR="\u00b7";this.$padding=0;this.$updateEolChar=function(){var a="\n"==this.session.doc.getNewLineCharacter()?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=a)return this.EOL_CHAR=a,!0};this.setPadding=function(a){this.$padding=a;this.element.style.padding="0 "+a+"px"};this.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0};this.getCharacterWidth=
function(){return this.$fontMetrics.$characterSize.width||0};this.$setFontMetrics=function(a){this.$fontMetrics=a;this.$fontMetrics.on("changeCharacterSize",function(a){this._signal("changeCharacterSize",a)}.bind(this));this.$pollSizeChanges()};this.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()};this.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()};this.setSession=function(a){(this.session=a)&&this.$computeTabString()};this.showInvisibles=
!1;this.setShowInvisibles=function(a){if(this.showInvisibles==a)return!1;this.showInvisibles=a;this.$computeTabString();return!0};this.displayIndentGuides=!0;this.setDisplayIndentGuides=function(a){if(this.displayIndentGuides==a)return!1;this.displayIndentGuides=a;this.$computeTabString();return!0};this.$tabStrings=[];this.onChangeTabSize=this.$computeTabString=function(){var a=this.session.getTabSize();this.tabSize=a;for(var d=this.$tabStrings=[0],c=1;c<a+1;c++)this.showInvisibles?d.push("<span class='ace_invisible ace_invisible_tab'>"+
b.stringRepeat(this.TAB_CHAR,c)+"</span>"):d.push(b.stringRepeat(" ",c));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;a="ace_indent-guide";c=d="";if(this.showInvisibles)var a=a+" ace_invisible",d=" ace_invisible_space",c=" ace_invisible_tab",e=b.stringRepeat(this.SPACE_CHAR,this.tabSize),h=b.stringRepeat(this.TAB_CHAR,this.tabSize);else h=e=b.stringRepeat(" ",this.tabSize);this.$tabStrings[" "]="<span class='"+a+d+"'>"+e+"</span>";this.$tabStrings["\t"]="<span class='"+a+c+
"'>"+h+"</span>"}};this.updateLines=function(a,b,c){this.config.lastRow==a.lastRow&&this.config.firstRow==a.firstRow||this.scrollLines(a);this.config=a;var e=Math.max(b,a.firstRow);c=Math.min(c,a.lastRow);b=this.element.childNodes;for(var h=0,f=a.firstRow;f<e;f++){var l=this.session.getFoldLine(f);if(l)if(l.containsRow(e)){e=l.start.row;break}else f=l.end.row;h++}f=e;for(e=(l=this.session.getNextFoldLine(f))?l.start.row:Infinity;;){f>e&&(f=l.end.row+1,e=(l=this.session.getNextFoldLine(f,l))?l.start.row:
Infinity);if(f>c)break;var k=b[h++];if(k){var m=[];this.$renderLine(m,f,!this.$useLineGroups(),f==e?l:!1);k.style.height=a.lineHeight*this.session.getRowLength(f)+"px";k.innerHTML=m.join("")}f++}};this.scrollLines=function(a){var b=this.config;this.config=a;if(!b||b.lastRow<a.firstRow||a.lastRow<b.firstRow)return this.update(a);var c=this.element;if(b.firstRow<a.firstRow)for(var e=this.session.getFoldedRowCount(b.firstRow,a.firstRow-1);0<e;e--)c.removeChild(c.firstChild);if(b.lastRow>a.lastRow)for(e=
this.session.getFoldedRowCount(a.lastRow+1,b.lastRow);0<e;e--)c.removeChild(c.lastChild);a.firstRow<b.firstRow&&(e=this.$renderLinesFragment(a,a.firstRow,b.firstRow-1),c.firstChild?c.insertBefore(e,c.firstChild):c.appendChild(e));a.lastRow>b.lastRow&&(e=this.$renderLinesFragment(a,b.lastRow+1,a.lastRow),c.appendChild(e))};this.$renderLinesFragment=function(a,b,c){for(var e=this.element.ownerDocument.createDocumentFragment(),h=this.session.getNextFoldLine(b),f=h?h.start.row:Infinity;;){b>f&&(b=h.end.row+
1,f=(h=this.session.getNextFoldLine(b,h))?h.start.row:Infinity);if(b>c)break;var l=m.createElement("div"),k=[];this.$renderLine(k,b,!1,b==f?h:!1);l.innerHTML=k.join("");if(this.$useLineGroups())l.className="ace_line_group",e.appendChild(l),l.style.height=a.lineHeight*this.session.getRowLength(b)+"px";else for(;l.firstChild;)e.appendChild(l.firstChild);b++}return e};this.update=function(a){this.config=a;for(var b=[],c=a.lastRow,e=a.firstRow,h=this.session.getNextFoldLine(e),f=h?h.start.row:Infinity;;){e>
f&&(e=h.end.row+1,f=(h=this.session.getNextFoldLine(e,h))?h.start.row:Infinity);if(e>c)break;this.$useLineGroups()&&b.push("<div class='ace_line_group' style='height:",a.lineHeight*this.session.getRowLength(e),"px'>");this.$renderLine(b,e,!1,e==f?h:!1);this.$useLineGroups()&&b.push("</div>");e++}this.element.innerHTML=b.join("")};this.$textToken={text:!0,rparen:!0,lparen:!0};this.$renderToken=function(a,d,c,e){var h=this,f=e.replace(/\t|&|<|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\u3000\uFEFF])|[\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3000-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]/g,
function(a,c,e,g,f){if(c)return h.showInvisibles?"<span class='ace_invisible ace_invisible_space'>"+b.stringRepeat(h.SPACE_CHAR,a.length)+"</span>":a;if("&"==a)return"&#38;";if("<"==a)return"&#60;";if("\t"==a)return a=h.session.getScreenTabSize(d+g),d+=a-1,h.$tabStrings[a];if("\u3000"==a)return a=h.showInvisibles?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",c=h.showInvisibles?h.SPACE_CHAR:"",d+=1,"<span class='"+a+"' style='width:"+2*h.config.characterWidth+"px'>"+c+"</span>";if(e)return"<span class='ace_invisible ace_invisible_space ace_invalid'>"+
h.SPACE_CHAR+"</span>";d+=1;return"<span class='ace_cjk' style='width:"+2*h.config.characterWidth+"px'>"+a+"</span>"});if(this.$textToken[c.type])a.push(f);else{var l="ace_"+c.type.replace(/\./g," ace_"),k="";"fold"==c.type&&(k=" style='width:"+c.value.length*this.config.characterWidth+"px;' ");a.push("<span class='",l,"'",k,">",f,"</span>")}return d+e.length};this.renderIndentGuide=function(a,d,c){var e=d.search(this.$indentGuideRe);return 0>=e||e>=c?d:" "==d[0]?(e-=e%this.tabSize,a.push(b.stringRepeat(this.$tabStrings[" "],
e/this.tabSize)),d.substr(e)):"\t"==d[0]?(a.push(b.stringRepeat(this.$tabStrings["\t"],e)),d.substr(e)):d};this.$renderWrappedLine=function(a,d,c,e){for(var h=0,f=0,l=c[0],k=0,m=0;m<d.length;m++){var s=d[m],q=s.value;if(0==m&&this.displayIndentGuides){h=q.length;q=this.renderIndentGuide(a,q,l);if(!q)continue;h-=q.length}if(h+q.length<l)k=this.$renderToken(a,k,s,q),h+=q.length;else{for(;h+q.length>=l;)this.$renderToken(a,k,s,q.substring(0,l-h)),q=q.substring(l-h),h=l,e||a.push("</div>","<div class='ace_line' style='height:",
this.config.lineHeight,"px'>"),a.push(b.stringRepeat("\u00a0",c.indent)),f++,k=0,l=c[f]||Number.MAX_VALUE;0!=q.length&&(h+=q.length,k=this.$renderToken(a,k,s,q))}}};this.$renderSimpleLine=function(a,b){var c=0,e=b[0],h=e.value;this.displayIndentGuides&&(h=this.renderIndentGuide(a,h));h&&(c=this.$renderToken(a,c,e,h));for(var f=1;f<b.length;f++)e=b[f],h=e.value,c=this.$renderToken(a,c,e,h)};this.$renderLine=function(a,b,c,e){e||!1==e||(e=this.session.getFoldLine(b));var f=e?this.$getFoldLineTokens(b,
e):this.session.getTokens(b);c||a.push("<div class='ace_line' style='height:",this.config.lineHeight*(this.$useLineGroups()?1:this.session.getRowLength(b)),"px'>");if(f.length){var k=this.session.getRowSplitData(b);k&&k.length?this.$renderWrappedLine(a,f,k,c):this.$renderSimpleLine(a,f)}this.showInvisibles&&(e&&(b=e.end.row),a.push("<span class='ace_invisible ace_invisible_eol'>",b==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,"</span>"));c||a.push("</div>")};this.$getFoldLineTokens=function(a,
b){var c=this.session,e=[],f=c.getTokens(a);b.walk(function(a,b,d,k,s){if(null!=a)e.push({type:"fold",value:a});else if(s&&(f=c.getTokens(b)),f.length)a:{a=f;for(s=b=0;s+a[b].value.length<k;)if(s+=a[b].value.length,b++,b==a.length)break a;if(s!=k){var q=a[b].value.substring(k-s);q.length>d-k&&(q=q.substring(0,d-k));e.push({type:a[b].type,value:q});s=k+q.length;b+=1}for(;s<d&&b<a.length;)q=a[b].value,q.length+s>d?e.push({type:a[b].type,value:q.substring(0,d-s)}):e.push(a[b]),s+=q.length,b+=1}},b.end.row,
this.session.getLine(b.end.row).length);return e};this.$useLineGroups=function(){return this.session.getUseWrapMode()};this.destroy=function(){clearInterval(this.$pollSizeChangesTimer);this.$measureNode&&this.$measureNode.parentNode.removeChild(this.$measureNode);delete this.$measureNode}}).call(f.prototype);k.Text=f});
define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(f,k,r){var e=f("../lib/dom"),m;f=function(b){this.element=e.createElement("div");this.element.className="ace_layer ace_cursor-layer";b.appendChild(this.element);void 0===m&&(m="opacity"in this.element);this.isVisible=!1;this.isBlinking=!0;this.blinkInterval=1E3;this.smoothBlinking=!1;this.cursors=[];this.cursor=this.addCursor();e.addCssClass(this.element,"ace_hidden-cursors");this.$updateCursors=this.$updateVisibility.bind(this)};
(function(){this.$updateVisibility=function(b){for(var c=this.cursors,a=c.length;a--;)c[a].style.visibility=b?"":"hidden"};this.$updateOpacity=function(b){for(var c=this.cursors,a=c.length;a--;)c[a].style.opacity=b?"":"0"};this.$padding=0;this.setPadding=function(b){this.$padding=b};this.setSession=function(b){this.session=b};this.setBlinking=function(b){b!=this.isBlinking&&(this.isBlinking=b,this.restartTimer())};this.setBlinkInterval=function(b){b!=this.blinkInterval&&(this.blinkInterval=b,this.restartTimer())};
this.setSmoothBlinking=function(b){b==this.smoothBlinking||m||(this.smoothBlinking=b,e.setCssClass(this.element,"ace_smooth-blinking",b),this.$updateCursors(!0),this.$updateCursors=(b?this.$updateOpacity:this.$updateVisibility).bind(this),this.restartTimer())};this.addCursor=function(){var b=e.createElement("div");b.className="ace_cursor";this.element.appendChild(b);this.cursors.push(b);return b};this.removeCursor=function(){if(1<this.cursors.length){var b=this.cursors.pop();b.parentNode.removeChild(b);
return b}};this.hideCursor=function(){this.isVisible=!1;e.addCssClass(this.element,"ace_hidden-cursors");this.restartTimer()};this.showCursor=function(){this.isVisible=!0;e.removeCssClass(this.element,"ace_hidden-cursors");this.restartTimer()};this.restartTimer=function(){var b=this.$updateCursors;clearInterval(this.intervalId);clearTimeout(this.timeoutId);this.smoothBlinking&&e.removeCssClass(this.element,"ace_smooth-blinking");b(!0);if(this.isBlinking&&this.blinkInterval&&this.isVisible){this.smoothBlinking&&
setTimeout(function(){e.addCssClass(this.element,"ace_smooth-blinking")}.bind(this));var c=function(){this.timeoutId=setTimeout(function(){b(!1)},.6*this.blinkInterval)}.bind(this);this.intervalId=setInterval(function(){b(!0);c()},this.blinkInterval);c()}};this.getPixelPosition=function(b,c){if(!this.config||!this.session)return{left:0,top:0};b||(b=this.session.selection.getCursor());var a=this.session.documentToScreenPosition(b);return{left:this.$padding+a.column*this.config.characterWidth,top:(a.row-
(c?this.config.firstRowScreen:0))*this.config.lineHeight}};this.update=function(b){this.config=b;var c=this.session.$selectionMarkers,a=0,d=0;if(void 0===c||0===c.length)c=[{cursor:null}];for(var a=0,e=c.length;a<e;a++){var f=this.getPixelPosition(c[a].cursor,!0);if(!((f.top>b.height+b.offset||0>f.top)&&1<a)){var h=(this.cursors[d++]||this.addCursor()).style;this.drawCursor?this.drawCursor(h,f,b,c[a],this.session):(h.left=f.left+"px",h.top=f.top+"px",h.width=b.characterWidth+"px",h.height=b.lineHeight+
"px")}}for(;this.cursors.length>d;)this.removeCursor();b=this.session.getOverwrite();this.$setOverwrite(b);this.$pixelPos=f;this.restartTimer()};this.drawCursor=null;this.$setOverwrite=function(b){b!=this.overwrite&&((this.overwrite=b)?e.addCssClass(this.element,"ace_overwrite-cursors"):e.removeCssClass(this.element,"ace_overwrite-cursors"))};this.destroy=function(){clearInterval(this.intervalId);clearTimeout(this.timeoutId)}}).call(f.prototype);k.Cursor=f});
define("ace/scrollbar","require exports module ace/lib/oop ace/lib/dom ace/lib/event ace/lib/event_emitter".split(" "),function(f,k,r){var e=f("./lib/oop"),m=f("./lib/dom"),b=f("./lib/event"),c=f("./lib/event_emitter").EventEmitter,a=function(a){this.element=m.createElement("div");this.element.className="ace_scrollbar ace_scrollbar"+this.classSuffix;this.inner=m.createElement("div");this.inner.className="ace_scrollbar-inner";this.element.appendChild(this.inner);a.appendChild(this.element);this.setVisible(!1);
this.skipEvent=!1;b.addListener(this.element,"scroll",this.onScroll.bind(this));b.addListener(this.element,"mousedown",b.preventDefault)};(function(){e.implement(this,c);this.setVisible=function(a){this.element.style.display=a?"":"none";this.isVisible=a}}).call(a.prototype);f=function(b,c){a.call(this,b);this.scrollTop=0;c.$scrollbarWidth=this.width=m.scrollbarWidth(b.ownerDocument);this.inner.style.width=this.element.style.width=(this.width||15)+5+"px"};e.inherits(f,a);(function(){this.classSuffix=
"-v";this.onScroll=function(){this.skipEvent||(this.scrollTop=this.element.scrollTop,this._emit("scroll",{data:this.scrollTop}));this.skipEvent=!1};this.getWidth=function(){return this.isVisible?this.width:0};this.setHeight=function(a){this.element.style.height=a+"px"};this.setInnerHeight=function(a){this.inner.style.height=a+"px"};this.setScrollHeight=function(a){this.inner.style.height=a+"px"};this.setScrollTop=function(a){this.scrollTop!=a&&(this.skipEvent=!0,this.scrollTop=this.element.scrollTop=
a)}}).call(f.prototype);r=function(b,c){a.call(this,b);this.scrollLeft=0;this.height=c.$scrollbarWidth;this.inner.style.height=this.element.style.height=(this.height||15)+5+"px"};e.inherits(r,a);(function(){this.classSuffix="-h";this.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft}));this.skipEvent=!1};this.getHeight=function(){return this.isVisible?this.height:0};this.setWidth=function(a){this.element.style.width=a+"px"};this.setInnerWidth=
function(a){this.inner.style.width=a+"px"};this.setScrollWidth=function(a){this.inner.style.width=a+"px"};this.setScrollLeft=function(a){this.scrollLeft!=a&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=a)}}).call(r.prototype);k.ScrollBar=f;k.ScrollBarV=f;k.ScrollBarH=r;k.VScrollBar=f;k.HScrollBar=r});
define("ace/renderloop",["require","exports","module","ace/lib/event"],function(f,k,r){var e=f("./lib/event");f=function(e,b){this.onRender=e;this.pending=!1;this.changes=0;this.window=b||window};(function(){this.schedule=function(f){this.changes|=f;if(!this.pending&&this.changes){this.pending=!0;var b=this;e.nextFrame(function(){b.pending=!1;for(var c;c=b.changes;)b.changes=0,b.onRender(c)},this.window)}}}).call(f.prototype);k.RenderLoop=f});
define("ace/layer/font_metrics","require exports module ace/lib/oop ace/lib/dom ace/lib/lang ace/lib/useragent ace/lib/event_emitter".split(" "),function(f,k,r){var e=f("../lib/oop"),m=f("../lib/dom"),b=f("../lib/lang"),c=f("../lib/useragent"),a=f("../lib/event_emitter").EventEmitter,d=0;f=k.FontMetrics=function(a,c){this.el=m.createElement("div");this.$setMeasureNodeStyles(this.el.style,!0);this.$main=m.createElement("div");this.$setMeasureNodeStyles(this.$main.style);this.$measureNode=m.createElement("div");
this.$setMeasureNodeStyles(this.$measureNode.style);this.el.appendChild(this.$main);this.el.appendChild(this.$measureNode);a.appendChild(this.el);d||this.$testFractionalRect();this.$measureNode.innerHTML=b.stringRepeat("X",d);this.$characterSize={width:0,height:0};this.checkForSizeChanges()};(function(){e.implement(this,a);this.$characterSize={width:0,height:0};this.$testFractionalRect=function(){var a=m.createElement("div");this.$setMeasureNodeStyles(a.style);a.style.width="0.2px";document.documentElement.appendChild(a);
var b=a.getBoundingClientRect().width;d=0<b&&1>b?50:100;a.parentNode.removeChild(a)};this.$setMeasureNodeStyles=function(a,b){a.width=a.height="auto";a.left=a.top="0px";a.visibility="hidden";a.position="absolute";a.whiteSpace="pre";8>c.isIE?a["font-family"]="inherit":a.font="inherit";a.overflow=b?"hidden":"visible"};this.checkForSizeChanges=function(){var a=this.$measureSizes();if(a&&(this.$characterSize.width!==a.width||this.$characterSize.height!==a.height)){this.$measureNode.style.fontWeight="bold";
var b=this.$measureSizes();this.$measureNode.style.fontWeight="";this.$characterSize=a;this.charSizes=Object.create(null);this.allowBoldFonts=b&&b.width===a.width&&b.height===a.height;this._emit("changeCharacterSize",{data:a})}};this.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer)return this.$pollSizeChangesTimer;var a=this;return this.$pollSizeChangesTimer=setInterval(function(){a.checkForSizeChanges()},500)};this.setPolling=function(a){a?this.$pollSizeChanges():this.$pollSizeChangesTimer&&
(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)};this.$measureSizes=function(){if(50===d){var a=null;try{a=this.$measureNode.getBoundingClientRect()}catch(b){a={width:0,height:0}}a={height:a.height,width:a.width/d}}else a={height:this.$measureNode.clientHeight,width:this.$measureNode.clientWidth/d};return 0===a.width||0===a.height?null:a};this.$measureCharWidth=function(a){this.$main.innerHTML=b.stringRepeat(a,d);return this.$main.getBoundingClientRect().width/d};this.getCharacterWidth=
function(a){var b=this.charSizes[a];void 0===b&&(this.charSizes[a]=this.$measureCharWidth(a)/this.$characterSize.width);return b};this.destroy=function(){clearInterval(this.$pollSizeChangesTimer);this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)}}).call(f.prototype)});
define("ace/virtual_renderer","require exports module ace/lib/oop ace/lib/dom ace/config ace/lib/useragent ace/layer/gutter ace/layer/marker ace/layer/text ace/layer/cursor ace/scrollbar ace/scrollbar ace/renderloop ace/layer/font_metrics ace/lib/event_emitter".split(" "),function(f,k,r){var e=f("./lib/oop"),m=f("./lib/dom"),b=f("./config"),c=f("./lib/useragent"),a=f("./layer/gutter").Gutter,d=f("./layer/marker").Marker,g=f("./layer/text").Text,n=f("./layer/cursor").Cursor,h=f("./scrollbar").HScrollBar,
t=f("./scrollbar").VScrollBar,l=f("./renderloop").RenderLoop,p=f("./layer/font_metrics").FontMetrics,D=f("./lib/event_emitter").EventEmitter;m.importCssString('.ace_editor {position: relative;overflow: hidden;font: 12px/normal \'Monaco\', \'Menlo\', \'Ubuntu Mono\', \'Consolas\', \'source-code-pro\', monospace;direction: ltr;}.ace_scroller {position: absolute;overflow: hidden;top: 0;bottom: 0;background-color: inherit;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;cursor: text;}.ace_content {position: absolute;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;min-width: 100%;}.ace_dragging .ace_scroller:before{position: absolute;top: 0;left: 0;right: 0;bottom: 0;content: \'\';background: rgba(250, 250, 250, 0.01);z-index: 1000;}.ace_dragging.ace_dark .ace_scroller:before{background: rgba(0, 0, 0, 0.01);}.ace_selecting, .ace_selecting * {cursor: text !important;}.ace_gutter {position: absolute;overflow : hidden;width: auto;top: 0;bottom: 0;left: 0;cursor: default;z-index: 4;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;}.ace_gutter-active-line {position: absolute;left: 0;right: 0;}.ace_scroller.ace_scroll-left {box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;}.ace_gutter-cell {padding-left: 19px;padding-right: 6px;background-repeat: no-repeat;}.ace_gutter-cell.ace_error {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: 2px center;}.ace_gutter-cell.ace_warning {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");background-position: 2px center;}.ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");background-position: 2px center;}.ace_dark .ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");}.ace_scrollbar {position: absolute;right: 0;bottom: 0;z-index: 6;}.ace_scrollbar-inner {position: absolute;cursor: text;left: 0;top: 0;}.ace_scrollbar-v{overflow-x: hidden;overflow-y: scroll;top: 0;}.ace_scrollbar-h {overflow-x: scroll;overflow-y: hidden;left: 0;}.ace_print-margin {position: absolute;height: 100%;}.ace_text-input {position: absolute;z-index: 0;width: 0.5em;height: 1em;opacity: 0;background: transparent;-moz-appearance: none;appearance: none;border: none;resize: none;outline: none;overflow: hidden;font: inherit;padding: 0 1px;margin: 0 -1px;text-indent: -1em;-ms-user-select: text;-moz-user-select: text;-webkit-user-select: text;user-select: text;}.ace_text-input.ace_composition {background: inherit;color: inherit;z-index: 1000;opacity: 1;text-indent: 0;}.ace_layer {z-index: 1;position: absolute;overflow: hidden;word-wrap: normal;white-space: pre;height: 100%;width: 100%;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;pointer-events: none;}.ace_gutter-layer {position: relative;width: auto;text-align: right;pointer-events: auto;}.ace_text-layer {font: inherit !important;}.ace_cjk {display: inline-block;text-align: center;}.ace_cursor-layer {z-index: 4;}.ace_cursor {z-index: 4;position: absolute;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;border-left: 2px solid}.ace_slim-cursors .ace_cursor {border-left-width: 1px;}.ace_overwrite-cursors .ace_cursor {border-left-width: 0;border-bottom: 1px solid;}.ace_hidden-cursors .ace_cursor {opacity: 0.2;}.ace_smooth-blinking .ace_cursor {-webkit-transition: opacity 0.18s;transition: opacity 0.18s;}.ace_editor.ace_multiselect .ace_cursor {border-left-width: 1px;}.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {position: absolute;z-index: 3;}.ace_marker-layer .ace_selection {position: absolute;z-index: 5;}.ace_marker-layer .ace_bracket {position: absolute;z-index: 6;}.ace_marker-layer .ace_active-line {position: absolute;z-index: 2;}.ace_marker-layer .ace_selected-word {position: absolute;z-index: 4;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;}.ace_line .ace_fold {-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;display: inline-block;height: 11px;margin-top: -2px;vertical-align: middle;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");background-repeat: no-repeat, repeat-x;background-position: center center, top left;color: transparent;border: 1px solid black;border-radius: 2px;cursor: pointer;pointer-events: auto;}.ace_dark .ace_fold {}.ace_fold:hover{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");}.ace_tooltip {background-color: #FFF;background-image: -webkit-linear-gradient(top, transparent, rgba(0, 0, 0, 0.1));background-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.1));border: 1px solid gray;border-radius: 1px;box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);color: black;max-width: 100%;padding: 3px 4px;position: fixed;z-index: 999999;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;cursor: default;white-space: pre;word-wrap: break-word;line-height: normal;font-style: normal;font-weight: normal;letter-spacing: normal;pointer-events: none;}.ace_folding-enabled > .ace_gutter-cell {padding-right: 13px;}.ace_fold-widget {-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;margin: 0 -12px 0 1px;display: none;width: 11px;vertical-align: top;background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: center;border-radius: 3px;border: 1px solid transparent;cursor: pointer;}.ace_folding-enabled .ace_fold-widget {display: inline-block;   }.ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");}.ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");}.ace_fold-widget:hover {border: 1px solid rgba(0, 0, 0, 0.3);background-color: rgba(255, 255, 255, 0.2);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);}.ace_fold-widget:active {border: 1px solid rgba(0, 0, 0, 0.4);background-color: rgba(0, 0, 0, 0.05);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);}.ace_dark .ace_fold-widget {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");}.ace_dark .ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget:hover {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);background-color: rgba(255, 255, 255, 0.1);}.ace_dark .ace_fold-widget:active {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);}.ace_fold-widget.ace_invalid {background-color: #FFB4B4;border-color: #DE5555;}.ace_fade-fold-widgets .ace_fold-widget {-webkit-transition: opacity 0.4s ease 0.05s;transition: opacity 0.4s ease 0.05s;opacity: 0;}.ace_fade-fold-widgets:hover .ace_fold-widget {-webkit-transition: opacity 0.05s ease 0.05s;transition: opacity 0.05s ease 0.05s;opacity:1;}.ace_underline {text-decoration: underline;}.ace_bold {font-weight: bold;}.ace_nobold .ace_bold {font-weight: normal;}.ace_italic {font-style: italic;}.ace_error-marker {background-color: rgba(255, 0, 0,0.2);position: absolute;z-index: 9;}.ace_highlight-marker {background-color: rgba(255, 255, 0,0.2);position: absolute;z-index: 8;}.ace_br1 {border-top-left-radius    : 3px;}.ace_br2 {border-top-right-radius   : 3px;}.ace_br3 {border-top-left-radius    : 3px; border-top-right-radius:    3px;}.ace_br4 {border-bottom-right-radius: 3px;}.ace_br5 {border-top-left-radius    : 3px; border-bottom-right-radius: 3px;}.ace_br6 {border-top-right-radius   : 3px; border-bottom-right-radius: 3px;}.ace_br7 {border-top-left-radius    : 3px; border-top-right-radius:    3px; border-bottom-right-radius: 3px;}.ace_br8 {border-bottom-left-radius : 3px;}.ace_br9 {border-top-left-radius    : 3px; border-bottom-left-radius:  3px;}.ace_br10{border-top-right-radius   : 3px; border-bottom-left-radius:  3px;}.ace_br11{border-top-left-radius    : 3px; border-top-right-radius:    3px; border-bottom-left-radius:  3px;}.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius:  3px;}.ace_br13{border-top-left-radius    : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius:  3px;}.ace_br14{border-top-right-radius   : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius:  3px;}.ace_br15{border-top-left-radius    : 3px; border-top-right-radius:    3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}',
"ace_editor.css");f=function(e,f){var k=this;this.container=e||m.createElement("div");this.$keepTextAreaAtCursor=!c.isOldIE;m.addCssClass(this.container,"ace_editor");this.setTheme(f);this.$gutter=m.createElement("div");this.$gutter.className="ace_gutter";this.container.appendChild(this.$gutter);this.scroller=m.createElement("div");this.scroller.className="ace_scroller";this.container.appendChild(this.scroller);this.content=m.createElement("div");this.content.className="ace_content";this.scroller.appendChild(this.content);
this.$gutterLayer=new a(this.$gutter);this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this));this.$markerBack=new d(this.content);this.canvas=(this.$textLayer=new g(this.content)).element;this.$markerFront=new d(this.content);this.$cursorLayer=new n(this.content);this.$vScroll=this.$horizScroll=!1;this.scrollBar=this.scrollBarV=new t(this.container,this);this.scrollBarH=new h(this.container,this);this.scrollBarV.addEventListener("scroll",function(a){k.$scrollAnimation||k.session.setScrollTop(a.data-
k.scrollMargin.top)});this.scrollBarH.addEventListener("scroll",function(a){k.$scrollAnimation||k.session.setScrollLeft(a.data-k.scrollMargin.left)});this.scrollLeft=this.scrollTop=0;this.cursorPos={row:0,column:0};this.$fontMetrics=new p(this.container,500);this.$textLayer.$setFontMetrics(this.$fontMetrics);this.$textLayer.addEventListener("changeCharacterSize",function(a){k.updateCharacterSize();k.onResize(!0,k.gutterWidth,k.$size.width,k.$size.height);k._signal("changeCharacterSize",a)});this.$size=
{width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0};this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1};this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0};this.$loop=new l(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView);this.$loop.schedule(this.CHANGE_FULL);this.updateCharacterSize();this.setPadding(4);b.resetOptions(this);b._emit("renderer",this)};
(function(){this.CHANGE_CURSOR=1;this.CHANGE_MARKER=2;this.CHANGE_GUTTER=4;this.CHANGE_SCROLL=8;this.CHANGE_LINES=16;this.CHANGE_TEXT=32;this.CHANGE_SIZE=64;this.CHANGE_MARKER_BACK=128;this.CHANGE_MARKER_FRONT=256;this.CHANGE_FULL=512;this.CHANGE_H_SCROLL=1024;e.implement(this,D);this.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts));this.layerConfig.characterWidth=
this.characterWidth=this.$textLayer.getCharacterWidth();this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight();this.$updatePrintMargin()};this.setSession=function(a){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode);(this.session=a)&&this.scrollMargin.top&&0>=a.getScrollTop()&&a.setScrollTop(-this.scrollMargin.top);this.$cursorLayer.setSession(a);this.$markerBack.setSession(a);this.$markerFront.setSession(a);this.$gutterLayer.setSession(a);this.$textLayer.setSession(a);
a&&(this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode))};this.updateLines=function(a,b,c){void 0===b&&(b=Infinity);this.$changedLines?(this.$changedLines.firstRow>a&&(this.$changedLines.firstRow=a),this.$changedLines.lastRow<b&&(this.$changedLines.lastRow=b)):this.$changedLines={firstRow:a,lastRow:b};if(this.$changedLines.lastRow<
this.layerConfig.firstRow)if(c)this.$changedLines.lastRow=this.layerConfig.lastRow;else return;this.$changedLines.firstRow>this.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)};this.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT);this.$textLayer.$updateEolChar()};this.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER);this.$textLayer.onChangeTabSize()};this.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)};this.updateFull=
function(a){a?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)};this.updateFontSize=function(){this.$textLayer.checkForSizeChanges()};this.$changes=0;this.$updateSizeAsync=function(){if(this.$loop.pending)this.$size.$dirty=!0;else this.onResize()};this.onResize=function(a,b,c,d){if(!(2<this.resizing)){0<this.resizing?this.resizing++:this.resizing=a?1:0;var e=this.container;d||(d=e.clientHeight||e.scrollHeight);c||(c=e.clientWidth||e.scrollWidth);b=this.$updateCachedSize(a,
b,c,d);if(!this.$size.scrollerHeight||!c&&!d)return this.resizing=0;a&&(this.$gutterLayer.$padding=null);a?this.$renderChanges(b|this.$changes,!0):this.$loop.schedule(b|this.$changes);this.resizing&&(this.resizing=0);this.scrollBarV.scrollLeft=this.scrollBarV.scrollTop=null}};this.$updateCachedSize=function(a,b,c,d){d-=this.$extraHeight||0;var e=0,g=this.$size,f={width:g.width,height:g.height,scrollerHeight:g.scrollerHeight,scrollerWidth:g.scrollerWidth};d&&(a||g.height!=d)&&(g.height=d,e|=this.CHANGE_SIZE,
g.scrollerHeight=g.height,this.$horizScroll&&(g.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",e|=this.CHANGE_SCROLL);c&&(a||g.width!=c)&&(e|=this.CHANGE_SIZE,g.width=c,null==b&&(b=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=b,this.scrollBarH.element.style.left=this.scroller.style.left=b+"px",g.scrollerWidth=Math.max(0,c-b-this.scrollBarV.getWidth()),this.scrollBarH.element.style.right=this.scroller.style.right=
this.scrollBarV.getWidth()+"px",this.scroller.style.bottom=this.scrollBarH.getHeight()+"px",this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||a)&&(e|=this.CHANGE_FULL);g.$dirty=!c||!d;e&&this._signal("resize",f);return e};this.onGutterResize=function(){var a=this.$showGutter?this.$gutter.offsetWidth:0;a!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,a,this.$size.width,this.$size.height));this.session.getUseWrapMode()&&this.adjustWrapLimit()?this.$loop.schedule(this.CHANGE_FULL):
this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):(this.$computeLayerConfig(),this.$loop.schedule(this.CHANGE_MARKER))};this.adjustWrapLimit=function(){return this.session.adjustWrapLimit(Math.floor((this.$size.scrollerWidth-2*this.$padding)/this.characterWidth),this.$showPrintMargin&&this.$printMarginColumn)};this.setAnimatedScroll=function(a){this.setOption("animatedScroll",a)};this.getAnimatedScroll=function(){return this.$animatedScroll};this.setShowInvisibles=function(a){this.setOption("showInvisibles",
a)};this.getShowInvisibles=function(){return this.getOption("showInvisibles")};this.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")};this.setDisplayIndentGuides=function(a){this.setOption("displayIndentGuides",a)};this.setShowPrintMargin=function(a){this.setOption("showPrintMargin",a)};this.getShowPrintMargin=function(){return this.getOption("showPrintMargin")};this.setPrintMarginColumn=function(a){this.setOption("printMarginColumn",a)};this.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")};
this.getShowGutter=function(){return this.getOption("showGutter")};this.setShowGutter=function(a){return this.setOption("showGutter",a)};this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")};this.setFadeFoldWidgets=function(a){this.setOption("fadeFoldWidgets",a)};this.setHighlightGutterLine=function(a){this.setOption("highlightGutterLine",a)};this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")};this.$updateGutterLineHighlight=function(){var a=
this.$cursorLayer.$pixelPos,b=this.layerConfig.lineHeight;if(this.session.getUseWrapMode()){var c=this.session.selection.getCursor();c.column=0;a=this.$cursorLayer.getPixelPosition(c,!0);b*=this.session.getRowLength(c.row)}this.$gutterLineHighlight.style.top=a.top-this.layerConfig.offset+"px";this.$gutterLineHighlight.style.height=b+"px"};this.$updatePrintMargin=function(){if(this.$showPrintMargin||this.$printMarginEl){if(!this.$printMarginEl){var a=m.createElement("div");a.className="ace_layer ace_print-margin-layer";
this.$printMarginEl=m.createElement("div");this.$printMarginEl.className="ace_print-margin";a.appendChild(this.$printMarginEl);this.content.insertBefore(a,this.content.firstChild)}a=this.$printMarginEl.style;a.left=this.characterWidth*this.$printMarginColumn+this.$padding+"px";a.visibility=this.$showPrintMargin?"visible":"hidden";this.session&&-1==this.session.$wrap&&this.adjustWrapLimit()}};this.getContainerElement=function(){return this.container};this.getMouseEventTarget=function(){return this.scroller};
this.getTextAreaContainer=function(){return this.container};this.$moveTextAreaToCursor=function(){if(this.$keepTextAreaAtCursor){var a=this.layerConfig,b=this.$cursorLayer.$pixelPos.top,c=this.$cursorLayer.$pixelPos.left,b=b-a.offset,d=this.textarea.style,e=this.lineHeight;if(0>b||b>a.height-e)d.top=d.left="0";else{a=this.characterWidth;if(this.$composition)var g=this.textarea.value.replace(/^\x01+/,""),a=a*(this.session.$getStringScreenWidth(g)[0]+2),e=e+2;c-=this.scrollLeft;c>this.$size.scrollerWidth-
a&&(c=this.$size.scrollerWidth-a);c+=this.gutterWidth;d.height=e+"px";d.width=a+"px";d.left=Math.min(c,this.$size.scrollerWidth-a)+"px";d.top=Math.min(b,this.$size.height-e)+"px"}}};this.getFirstVisibleRow=function(){return this.layerConfig.firstRow};this.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(0===this.layerConfig.offset?0:1)};this.getLastFullyVisibleRow=function(){return this.layerConfig.firstRow-1+Math.floor((this.layerConfig.height+this.layerConfig.offset)/this.layerConfig.lineHeight)};
this.getLastVisibleRow=function(){return this.layerConfig.lastRow};this.$padding=null;this.setPadding=function(a){this.$padding=a;this.$textLayer.setPadding(a);this.$cursorLayer.setPadding(a);this.$markerFront.setPadding(a);this.$markerBack.setPadding(a);this.$loop.schedule(this.CHANGE_FULL);this.$updatePrintMargin()};this.setScrollMargin=function(a,b,c,d){var e=this.scrollMargin;e.top=a|0;e.bottom=b|0;e.right=d|0;e.left=c|0;e.v=e.top+e.bottom;e.h=e.left+e.right;e.top&&0>=this.scrollTop&&this.session&&
this.session.setScrollTop(-e.top);this.updateFull()};this.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible};this.setHScrollBarAlwaysVisible=function(a){this.setOption("hScrollBarAlwaysVisible",a)};this.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible};this.setVScrollBarAlwaysVisible=function(a){this.setOption("vScrollBarAlwaysVisible",a)};this.$updateScrollBarV=function(){var a=this.layerConfig.maxHeight,b=this.$size.scrollerHeight;!this.$maxLines&&
this.$scrollPastEnd&&(a-=(b-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>a-b&&(a=this.scrollTop+b,this.scrollBarV.scrollTop=null));this.scrollBarV.setScrollHeight(a+this.scrollMargin.v);this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)};this.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h);this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)};this.$frozen=!1;this.freeze=function(){this.$frozen=
!0};this.unfreeze=function(){this.$frozen=!1};this.$renderChanges=function(a,b){this.$changes&&(a|=this.$changes,this.$changes=0);if(this.session&&this.container.offsetWidth&&!this.$frozen&&(a||b)){if(this.$size.$dirty)return this.$changes|=a,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges();this._signal("beforeRender");var c=this.layerConfig;if(a&this.CHANGE_FULL||a&this.CHANGE_SIZE||a&this.CHANGE_TEXT||a&this.CHANGE_LINES||a&this.CHANGE_SCROLL||a&this.CHANGE_H_SCROLL)a|=this.$computeLayerConfig(),
c.firstRow!=this.layerConfig.firstRow&&c.firstRowScreen==this.layerConfig.firstRowScreen&&(c=this.scrollTop+(c.firstRow-this.layerConfig.firstRow)*this.lineHeight,0<c&&(this.scrollTop=c,a|=this.CHANGE_SCROLL,a|=this.$computeLayerConfig())),c=this.layerConfig,this.$updateScrollBarV(),a&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),this.$gutterLayer.element.style.marginTop=-c.offset+"px",this.content.style.marginTop=-c.offset+"px",this.content.style.width=c.width+2*this.$padding+"px",this.content.style.height=
c.minHeight+"px";a&this.CHANGE_H_SCROLL&&(this.content.style.marginLeft=-this.scrollLeft+"px",this.scroller.className=0>=this.scrollLeft?"ace_scroller":"ace_scroller ace_scroll-left");a&this.CHANGE_FULL?(this.$textLayer.update(c),this.$showGutter&&this.$gutterLayer.update(c),this.$markerBack.update(c),this.$markerFront.update(c),this.$cursorLayer.update(c),this.$moveTextAreaToCursor(),this.$highlightGutterLine&&this.$updateGutterLineHighlight()):a&this.CHANGE_SCROLL?(a&this.CHANGE_TEXT||a&this.CHANGE_LINES?
this.$textLayer.update(c):this.$textLayer.scrollLines(c),this.$showGutter&&this.$gutterLayer.update(c),this.$markerBack.update(c),this.$markerFront.update(c),this.$cursorLayer.update(c),this.$highlightGutterLine&&this.$updateGutterLineHighlight(),this.$moveTextAreaToCursor()):(a&this.CHANGE_TEXT?(this.$textLayer.update(c),this.$showGutter&&this.$gutterLayer.update(c)):a&this.CHANGE_LINES?(this.$updateLines()||a&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(c):(a&this.CHANGE_TEXT||
a&this.CHANGE_GUTTER)&&this.$showGutter&&this.$gutterLayer.update(c),a&this.CHANGE_CURSOR&&(this.$cursorLayer.update(c),this.$moveTextAreaToCursor(),this.$highlightGutterLine&&this.$updateGutterLineHighlight()),a&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(c),a&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(c));this._signal("afterRender")}else this.$changes|=a};this.$autosize=function(){var a=this.session.getScreenLength()*this.lineHeight,b=this.$maxLines*
this.lineHeight,c=Math.max((this.$minLines||1)*this.lineHeight,Math.min(b,a))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(c+=this.scrollBarH.getHeight());a=a>b;if(c!=this.desiredHeight||this.$size.height!=this.desiredHeight||a!=this.$vScroll)a!=this.$vScroll&&(this.$vScroll=a,this.scrollBarV.setVisible(a)),a=this.container.clientWidth,this.container.style.height=c+"px",this.$updateCachedSize(!0,this.$gutterWidth,a,c),this.desiredHeight=c,this._signal("autosize")};this.$computeLayerConfig=
function(){var a=this.session,b=this.$size,c=b.height<=2*this.lineHeight,d=this.session.getScreenLength()*this.lineHeight,e=this.$getLongestLine(),g=!c&&(this.$hScrollBarAlwaysVisible||0>b.scrollerWidth-e-2*this.$padding),f=this.$horizScroll!==g;f&&(this.$horizScroll=g,this.scrollBarH.setVisible(g));this.$maxLines&&1<this.lineHeight&&this.$autosize();var g=this.scrollTop%this.lineHeight,h=b.scrollerHeight+this.lineHeight,l=!this.$maxLines&&this.$scrollPastEnd?(b.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:
0,d=d+l,k=this.scrollMargin;this.session.setScrollTop(Math.max(-k.top,Math.min(this.scrollTop,d-b.scrollerHeight+k.bottom)));this.session.setScrollLeft(Math.max(-k.left,Math.min(this.scrollLeft,e+2*this.$padding-b.scrollerWidth+k.right)));l=!c&&(this.$vScrollBarAlwaysVisible||0>b.scrollerHeight-d+l||this.scrollTop>k.top);if(c=this.$vScroll!==l)this.$vScroll=l,this.scrollBarV.setVisible(l);var h=Math.ceil(h/this.lineHeight)-1,l=Math.max(0,Math.round((this.scrollTop-g)/this.lineHeight)),k=l+h,n,p=this.lineHeight,
l=a.screenToDocumentRow(l,0);if(g=a.getFoldLine(l))l=g.start.row;n=a.documentToScreenRow(l,0);g=a.getRowLength(l)*p;k=Math.min(a.screenToDocumentRow(k,0),a.getLength()-1);h=b.scrollerHeight+a.getRowLength(k)*p+g;g=this.scrollTop-n*p;a=0;this.layerConfig.width!=e&&(a=this.CHANGE_H_SCROLL);if(f||c)a=this.$updateCachedSize(!0,this.gutterWidth,b.width,b.height),this._signal("scrollbarVisibilityChanged"),c&&(e=this.$getLongestLine());this.layerConfig={width:e,padding:this.$padding,firstRow:l,firstRowScreen:n,
lastRow:k,lineHeight:p,characterWidth:this.characterWidth,minHeight:h,maxHeight:d,offset:g,gutterOffset:Math.max(0,Math.ceil((g+b.height-b.scrollerHeight)/p)),height:this.$size.scrollerHeight};return a};this.$updateLines=function(){var a=this.$changedLines.firstRow,b=this.$changedLines.lastRow;this.$changedLines=null;var c=this.layerConfig;if(!(a>c.lastRow+1||b<c.firstRow))if(Infinity===b)this.$showGutter&&this.$gutterLayer.update(c),this.$textLayer.update(c);else return this.$textLayer.updateLines(c,
a,b),!0};this.$getLongestLine=function(){var a=this.session.getScreenWidth();this.showInvisibles&&!this.session.$useWrapMode&&(a+=1);return Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(a*this.characterWidth))};this.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0));this.$loop.schedule(this.CHANGE_MARKER_FRONT)};this.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers());this.$loop.schedule(this.CHANGE_MARKER_BACK)};
this.addGutterDecoration=function(a,b){this.$gutterLayer.addGutterDecoration(a,b)};this.removeGutterDecoration=function(a,b){this.$gutterLayer.removeGutterDecoration(a,b)};this.updateBreakpoints=function(a){this.$loop.schedule(this.CHANGE_GUTTER)};this.setAnnotations=function(a){this.$gutterLayer.setAnnotations(a);this.$loop.schedule(this.CHANGE_GUTTER)};this.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)};this.hideCursor=function(){this.$cursorLayer.hideCursor()};this.showCursor=
function(){this.$cursorLayer.showCursor()};this.scrollSelectionIntoView=function(a,b,c){this.scrollCursorIntoView(a,c);this.scrollCursorIntoView(b,c)};this.scrollCursorIntoView=function(a,b,c){if(0!==this.$size.scrollerHeight){var d=this.$cursorLayer.getPixelPosition(a);a=d.left;var d=d.top,e=c&&c.top||0;c=c&&c.bottom||0;var g=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;g+e>d?(b&&(d-=b*this.$size.scrollerHeight),0===d&&(d=-this.scrollMargin.top),this.session.setScrollTop(d)):
g+this.$size.scrollerHeight-c<d+this.lineHeight&&(b&&(d+=b*this.$size.scrollerHeight),this.session.setScrollTop(d+this.lineHeight-this.$size.scrollerHeight));b=this.scrollLeft;b>a?(a<this.$padding+2*this.layerConfig.characterWidth&&(a=-this.scrollMargin.left),this.session.setScrollLeft(a)):b+this.$size.scrollerWidth<a+this.characterWidth?this.session.setScrollLeft(Math.round(a+this.characterWidth-this.$size.scrollerWidth)):b<=this.$padding&&a-b<this.characterWidth&&this.session.setScrollLeft(0)}};
this.getScrollTop=function(){return this.session.getScrollTop()};this.getScrollLeft=function(){return this.session.getScrollLeft()};this.getScrollTopRow=function(){return this.scrollTop/this.lineHeight};this.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)};this.scrollToRow=function(a){this.session.setScrollTop(a*this.lineHeight)};this.alignCursor=function(a,b){"number"==typeof a&&(a={row:a,column:0});var c=this.$cursorLayer.getPixelPosition(a).top-
(this.$size.scrollerHeight-this.lineHeight)*(b||0);this.session.setScrollTop(c);return c};this.STEPS=8;this.$calcSteps=function(a,b){for(var c=0,d=this.STEPS,e=[],g=function(a,b,c){return c*(Math.pow(a-1,3)+1)+b},c=0;c<d;++c)e.push(g(c/this.STEPS,a,b-a));return e};this.scrollToLine=function(a,b,c,d){a=this.$cursorLayer.getPixelPosition({row:a,column:0}).top;b&&(a-=this.$size.scrollerHeight/2);b=this.scrollTop;this.session.setScrollTop(a);!1!==c&&this.animateScrolling(b,d)};this.animateScrolling=function(a,
b){var c=this.scrollTop;if(this.$animatedScroll){var d=this;if(a!=c){if(this.$scrollAnimation){var e=this.$scrollAnimation.steps;if(e.length&&(a=e[0],a==c))return}var g=d.$calcSteps(a,c);this.$scrollAnimation={from:a,to:c,steps:g};clearInterval(this.$timer);d.session.setScrollTop(g.shift());d.session.$scrollTop=c;this.$timer=setInterval(function(){g.length?(d.session.setScrollTop(g.shift()),d.session.$scrollTop=c):null!=c?(d.session.$scrollTop=-1,d.session.setScrollTop(c),c=null):(d.$timer=clearInterval(d.$timer),
d.$scrollAnimation=null,b&&b())},10)}}};this.scrollToY=function(a){this.scrollTop!==a&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=a)};this.scrollToX=function(a){this.scrollLeft!==a&&(this.scrollLeft=a);this.$loop.schedule(this.CHANGE_H_SCROLL)};this.scrollTo=function(a,b){this.session.setScrollTop(b);this.session.setScrollLeft(b)};this.scrollBy=function(a,b){b&&this.session.setScrollTop(this.session.getScrollTop()+b);a&&this.session.setScrollLeft(this.session.getScrollLeft()+a)};this.isScrollableBy=
function(a,b){if(0>b&&this.session.getScrollTop()>=1-this.scrollMargin.top||0<b&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||0>a&&this.session.getScrollLeft()>=1-this.scrollMargin.left||0<a&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0};this.pixelToScreenCoordinates=function(a,b){var c=this.scroller.getBoundingClientRect(),d=(a+this.scrollLeft-c.left-this.$padding)/
this.characterWidth,c=Math.floor((b+this.scrollTop-c.top)/this.lineHeight),e=Math.round(d);return{row:c,column:e,side:0<d-e?1:-1}};this.screenToTextCoordinates=function(a,b){var c=this.scroller.getBoundingClientRect(),d=Math.round((a+this.scrollLeft-c.left-this.$padding)/this.characterWidth);return this.session.screenToDocumentPosition((b+this.scrollTop-c.top)/this.lineHeight,Math.max(d,0))};this.textToScreenCoordinates=function(a,b){var c=this.scroller.getBoundingClientRect(),d=this.session.documentToScreenPosition(a,
b),e=this.$padding+Math.round(d.column*this.characterWidth);return{pageX:c.left+e-this.scrollLeft,pageY:c.top+d.row*this.lineHeight-this.scrollTop}};this.visualizeFocus=function(){m.addCssClass(this.container,"ace_focus")};this.visualizeBlur=function(){m.removeCssClass(this.container,"ace_focus")};this.showComposition=function(a){this.$composition||(this.$composition={keepTextAreaAtCursor:this.$keepTextAreaAtCursor,cssText:this.textarea.style.cssText});this.$keepTextAreaAtCursor=!0;m.addCssClass(this.textarea,
"ace_composition");this.textarea.style.cssText="";this.$moveTextAreaToCursor()};this.setCompositionText=function(a){this.$moveTextAreaToCursor()};this.hideComposition=function(){this.$composition&&(m.removeCssClass(this.textarea,"ace_composition"),this.$keepTextAreaAtCursor=this.$composition.keepTextAreaAtCursor,this.textarea.style.cssText=this.$composition.cssText,this.$composition=null)};this.setTheme=function(a,c){function d(b){if(e.$themeId!=a)return c&&c();if(b.cssClass){m.importCssString(b.cssText,
b.cssClass,e.container.ownerDocument);e.theme&&m.removeCssClass(e.container,e.theme.cssClass);var g="padding"in b?b.padding:"padding"in(e.theme||{})?4:e.$padding;e.$padding&&g!=e.$padding&&e.setPadding(g);e.$theme=b.cssClass;e.theme=b;m.addCssClass(e.container,b.cssClass);m.setCssClass(e.container,"ace_dark",b.isDark);e.$size&&(e.$size.width=0,e.$updateSizeAsync());e._dispatchEvent("themeLoaded",{theme:b});c&&c()}}var e=this;this.$themeId=a;e._dispatchEvent("themeChange",{theme:a});a&&"string"!=typeof a?
d(a):b.loadModule(["theme",a||this.$options.theme.initialValue],d)};this.getTheme=function(){return this.$themeId};this.setStyle=function(a,b){m.setCssClass(this.container,a,!1!==b)};this.unsetStyle=function(a){m.removeCssClass(this.container,a)};this.setCursorStyle=function(a){this.scroller.style.cursor!=a&&(this.scroller.style.cursor=a)};this.setMouseCursor=function(a){this.scroller.style.cursor=a};this.destroy=function(){this.$textLayer.destroy();this.$cursorLayer.destroy()}}).call(f.prototype);
b.defineOptions(f.prototype,"renderer",{animatedScroll:{initialValue:!1},showInvisibles:{set:function(a){this.$textLayer.setShowInvisibles(a)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!1},showPrintMargin:{set:function(){this.$updatePrintMargin()},initialValue:!0},printMarginColumn:{set:function(){this.$updatePrintMargin()},initialValue:80},printMargin:{set:function(a){"number"==typeof a&&(this.$printMarginColumn=a);this.$showPrintMargin=!!a;this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&
this.$printMarginColumn}},showGutter:{set:function(a){this.$gutter.style.display=a?"block":"none";this.$loop.schedule(this.CHANGE_FULL);this.onGutterResize()},initialValue:!0},fadeFoldWidgets:{set:function(a){m.setCssClass(this.$gutter,"ace_fade-fold-widgets",a)},initialValue:!1},showFoldWidgets:{set:function(a){this.$gutterLayer.setShowFoldWidgets(a)},initialValue:!0},showLineNumbers:{set:function(a){this.$gutterLayer.setShowLineNumbers(a);this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},
displayIndentGuides:{set:function(a){this.$textLayer.setDisplayIndentGuides(a)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightGutterLine:{set:function(a){this.$gutterLineHighlight?(this.$gutterLineHighlight.style.display=a?"":"none",this.$cursorLayer.$pixelPos&&this.$updateGutterLineHighlight()):(this.$gutterLineHighlight=m.createElement("div"),this.$gutterLineHighlight.className="ace_gutter-active-line",this.$gutter.appendChild(this.$gutterLineHighlight))},initialValue:!1,value:!0},
hScrollBarAlwaysVisible:{set:function(a){this.$hScrollBarAlwaysVisible&&this.$horizScroll||this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(a){this.$vScrollBarAlwaysVisible&&this.$vScroll||this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(a){"number"==typeof a&&(a+="px");this.container.style.fontSize=a;this.updateFontSize()},initialValue:12},fontFamily:{set:function(a){this.container.style.fontFamily=a;this.updateFontSize()}},
maxLines:{set:function(a){this.updateFull()}},minLines:{set:function(a){this.updateFull()}},scrollPastEnd:{set:function(a){a=+a||0;this.$scrollPastEnd!=a&&(this.$scrollPastEnd=a,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(a){this.$gutterLayer.$fixedWidth=!!a;this.$loop.schedule(this.CHANGE_GUTTER)}},theme:{set:function(a){this.setTheme(a)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0}});k.VirtualRenderer=
f});
define("ace/worker/worker_client","require exports module ace/lib/oop ace/lib/net ace/lib/event_emitter ace/config".split(" "),function(f,k,r){var e=f("../lib/oop"),m=f("../lib/net"),b=f("../lib/event_emitter").EventEmitter,c=f("../config");r=function(a,b,e,h){this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this);this.changeListener=this.changeListener.bind(this);this.onMessage=this.onMessage.bind(this);f.nameToUrl&&!f.toUrl&&(f.toUrl=f.nameToUrl);if(c.get("packaged")||!f.toUrl)h=h||c.moduleUrl(b,"worker");
else{var k=this.$normalizePath;h=h||k(f.toUrl("ace/worker/worker.js",null,"_"));var l={};a.forEach(function(a){l[a]=k(f.toUrl(a,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}try{this.$worker=new Worker(h)}catch(p){if(p instanceof window.DOMException)h=this.$workerBlob(h),a=window.URL||window.webkitURL,h=a.createObjectURL(h),this.$worker=new Worker(h),a.revokeObjectURL(h);else throw p;}this.$worker.postMessage({init:!0,tlns:l,module:b,classname:e});this.callbackId=1;this.callbacks={};this.$worker.onmessage=
this.onMessage};(function(){e.implement(this,b);this.onMessage=function(a){a=a.data;switch(a.type){case "event":this._signal(a.name,{data:a.data});break;case "call":var b=this.callbacks[a.id];b&&(b(a.data),delete this.callbacks[a.id]);break;case "error":this.reportError(a.data);break;case "log":window.console&&console.log&&console.log.apply(console,a.data)}};this.reportError=function(a){window.console&&console.error&&console.error(a)};this.$normalizePath=function(a){return m.qualifyURL(a)};this.terminate=
function(){this._signal("terminate",{});this.deltaQueue=null;this.$worker.terminate();this.$worker=null;this.$doc&&this.$doc.off("change",this.changeListener);this.$doc=null};this.send=function(a,b){this.$worker.postMessage({command:a,args:b})};this.call=function(a,b,c){if(c){var e=this.callbackId++;this.callbacks[e]=c;b.push(e)}this.send(a,b)};this.emit=function(a,b){try{this.$worker.postMessage({event:a,data:{data:b.data}})}catch(c){console.error(c.stack)}};this.attachToDocument=function(a){this.$doc&&
this.terminate();this.$doc=a;this.call("setValue",[a.getValue()]);a.on("change",this.changeListener)};this.changeListener=function(a){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0));"insert"==a.action?this.deltaQueue.push(a.start,a.lines):this.deltaQueue.push(a.start,a.end)};this.$sendDeltaQueue=function(){var a=this.deltaQueue;a&&(this.deltaQueue=null,50<a.length&&a.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:a}))};
this.$workerBlob=function(a){a="importScripts('"+m.qualifyURL(a)+"');";try{return new Blob([a],{type:"application/javascript"})}catch(b){var c=new (window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder);c.append(a);return c.getBlob("application/javascript")}}}).call(r.prototype);var a=function(a,e,f){this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this);this.changeListener=this.changeListener.bind(this);this.callbackId=1;this.callbacks={};this.messageBuffer=[];var h=null,k=!1,l=Object.create(b),
p=this;this.$worker={};this.$worker.terminate=function(){};this.$worker.postMessage=function(a){p.messageBuffer.push(a);h&&(k?setTimeout(m):m())};this.setEmitSync=function(a){k=a};var m=function(){var a=p.messageBuffer.shift();a.command?h[a.command].apply(h,a.args):a.event&&l._signal(a.event,a.data)};l.postMessage=function(a){p.onMessage({data:a})};l.callback=function(a,b){this.postMessage({type:"call",id:b,data:a})};l.emit=function(a,b){this.postMessage({type:"event",name:a,data:b})};c.loadModule(["worker",
e],function(a){for(h=new a[f](l);p.messageBuffer.length;)m()})};a.prototype=r.prototype;k.UIWorkerClient=a;k.WorkerClient=r});
define("ace/placeholder","require exports module ace/range ace/lib/event_emitter ace/lib/oop".split(" "),function(f,k,r){var e=f("./range").Range,m=f("./lib/event_emitter").EventEmitter,b=f("./lib/oop");f=function(b,a,d,e,f,h){var k=this;this.length=a;this.session=b;this.doc=b.getDocument();this.mainClass=f;this.othersClass=h;this.$onUpdate=this.onUpdate.bind(this);this.doc.on("change",this.$onUpdate);this.$others=e;this.$onCursorChange=function(){setTimeout(function(){k.onCursorChange()})};this.$pos=
d;this.$undoStackDepth=(b.getUndoManager().$undoStack||b.getUndoManager().$undostack||{length:-1}).length;this.setup();b.selection.on("changeCursor",this.$onCursorChange)};(function(){b.implement(this,m);this.setup=function(){var b=this,a=this.doc,d=this.session,g=this.$pos;this.selectionBefore=d.selection.toJSON();d.selection.inMultiSelectMode&&d.selection.toSingleRange();this.pos=a.createAnchor(g.row,g.column);this.markerId=d.addMarker(new e(g.row,g.column,g.row,g.column+this.length),this.mainClass,
null,!1);this.pos.on("change",function(a){d.removeMarker(b.markerId);b.markerId=d.addMarker(new e(a.value.row,a.value.column,a.value.row,a.value.column+b.length),b.mainClass,null,!1)});this.others=[];this.$others.forEach(function(d){d=a.createAnchor(d.row,d.column);b.others.push(d)});d.setUndoSelect(!1)};this.showOtherMarkers=function(){if(!this.othersActive){var b=this.session,a=this;this.othersActive=!0;this.others.forEach(function(d){d.markerId=b.addMarker(new e(d.row,d.column,d.row,d.column+a.length),
a.othersClass,null,!1);d.on("change",function(g){b.removeMarker(d.markerId);d.markerId=b.addMarker(new e(g.value.row,g.value.column,g.value.row,g.value.column+a.length),a.othersClass,null,!1)})})}};this.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var b=0;b<this.others.length;b++)this.session.removeMarker(this.others[b].markerId)}};this.onUpdate=function(b){if(b.start.row===b.end.row&&b.start.row===this.pos.row&&!this.$updating){this.$updating=!0;var a="insert"===b.action?
b.end.column-b.start.column:b.start.column-b.end.column;if(b.start.column>=this.pos.column&&b.start.column<=this.pos.column+this.length+1){var d=b.start.column-this.pos.column;this.length+=a;if(!this.session.$fromUndo){if("insert"===b.action)for(var g=this.others.length-1;0<=g;g--){var f=this.others[g],h={row:f.row,column:f.column+d};f.row===b.start.row&&b.start.column<f.column&&(h.column+=a);this.doc.insertMergedLines(h,b.lines)}else if("remove"===b.action)for(g=this.others.length-1;0<=g;g--)f=this.others[g],
h={row:f.row,column:f.column+d},f.row===b.start.row&&b.start.column<f.column&&(h.column+=a),this.doc.remove(new e(h.row,h.column,h.row,h.column-a));b.start.column===this.pos.column&&"insert"===b.action?setTimeout(function(){this.pos.setPosition(this.pos.row,this.pos.column-a);for(var d=0;d<this.others.length;d++){var e=this.others[d],g=e.row,f=e.column-a;e.row===b.start.row&&b.start.column<e.column&&(f+=a);e.setPosition(g,f)}}.bind(this),0):b.start.column===this.pos.column&&"remove"===b.action&&setTimeout(function(){for(var d=
0;d<this.others.length;d++){var e=this.others[d];e.row===b.start.row&&b.start.column<e.column&&e.setPosition(e.row,e.column-a)}}.bind(this),0)}this.pos._emit("change",{value:this.pos});for(g=0;g<this.others.length;g++)this.others[g]._emit("change",{value:this.others[g]})}this.$updating=!1}};this.onCursorChange=function(b){if(!this.$updating&&this.session){var a=this.session.selection.getCursor();a.row===this.pos.row&&a.column>=this.pos.column&&a.column<=this.pos.column+this.length?(this.showOtherMarkers(),
this._emit("cursorEnter",b)):(this.hideOtherMarkers(),this._emit("cursorLeave",b))}};this.detach=function(){this.session.removeMarker(this.markerId);this.hideOtherMarkers();this.doc.removeEventListener("change",this.$onUpdate);this.session.selection.removeEventListener("changeCursor",this.$onCursorChange);this.pos.detach();for(var b=0;b<this.others.length;b++)this.others[b].detach();this.session.setUndoSelect(!0);this.session=null};this.cancel=function(){if(-1===this.$undoStackDepth)throw Error("Canceling placeholders only supported with undo manager attached to session.");
for(var b=this.session.getUndoManager(),a=(b.$undoStack||b.$undostack).length-this.$undoStackDepth,d=0;d<a;d++)b.undo(!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}}).call(f.prototype);k.PlaceHolder=f});
define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(f,k,r){function e(b,a){return b.row==a.row&&b.column==a.column}var m=f("../lib/event"),b=f("../lib/useragent");k.onMouseDown=function(c){var a=c.domEvent,d=a.altKey,g=a.shiftKey,f=a.ctrlKey,h=c.getAccelKey(),k=c.getButton();f&&b.isMac&&(k=a.button);if(c.editor.inMultiSelectMode&&2==k)c.editor.textInput.onContextMenu(c.domEvent);else if(!f&&!d&&!h)0===k&&c.editor.inMultiSelectMode&&c.editor.exitMultiSelectMode();
else if(0===k){var l=c.editor,p=l.selection,k=l.inMultiSelectMode,D=c.getDocumentPosition(),s=p.getCursor(),s=c.inSelection()||p.isEmpty()&&e(D,s),q=c.x,r=c.y,u=function(a){q=a.clientX;r=a.clientY},x=l.session,B=l.renderer.pixelToScreenCoordinates(q,r),I=B,C;if(l.$mouseHandler.$enableJumpToDef)f&&d||h&&d?C=g?"block":"add":d&&l.$blockSelectEnabled&&(C="block");else if(h&&!d){if(C="add",!k&&g)return}else d&&l.$blockSelectEnabled&&(C="block");C&&b.isMac&&a.ctrlKey&&l.$mouseHandler.cancelContextMenu();
if("add"==C){if(k||!s){if(!k){var y=p.toOrientedRange();l.addSelectionMarker(y)}var A=p.rangeList.rangeAtPoint(D);l.$blockScrolling++;l.inVirtualSelectionMode=!0;g&&(A=null,y=p.ranges[0]||y,l.removeSelectionMarker(y));l.once("mouseup",function(){var a=p.toOrientedRange();A&&a.isEmpty()&&e(A.cursor,a.cursor)?p.substractPoint(a.cursor):(g?p.substractPoint(y.cursor):y&&(l.removeSelectionMarker(y),p.addRange(y)),p.addRange(a));l.$blockScrolling--;l.inVirtualSelectionMode=!1})}}else if("block"==C){c.stop();
l.inVirtualSelectionMode=!0;var G,z=[];l.$blockScrolling++;k&&!h?p.toSingleRange():!k&&h&&(G=p.toOrientedRange(),l.addSelectionMarker(G));g?B=x.documentToScreenPosition(p.lead):p.moveToPosition(D);l.$blockScrolling--;I={row:-1,column:-1};m.capture(l.container,u,function(a){clearInterval(F);l.removeSelectionMarkers(z);z.length||(z=[p.toOrientedRange()]);l.$blockScrolling++;G&&(l.removeSelectionMarker(G),p.toSingleRange(G));for(a=0;a<z.length;a++)p.addRange(z[a]);l.inVirtualSelectionMode=!1;l.$mouseHandler.$clickSelection=
null;l.$blockScrolling--});var F=setInterval(function(){var a=l.renderer.pixelToScreenCoordinates(q,r),b=x.screenToDocumentPosition(a.row,a.column);e(I,a)&&e(b,p.lead)||(I=a,l.$blockScrolling++,l.selection.moveToPosition(b),l.renderer.scrollCursorIntoView(),l.removeSelectionMarkers(z),z=p.rectangularRangeBlock(I,B),l.$mouseHandler.$clickSelection&&1==z.length&&z[0].isEmpty()&&(z[0]=l.$mouseHandler.$clickSelection.clone()),z.forEach(l.addSelectionMarker,l),l.updateSelectionMarkers(),l.$blockScrolling--)},
20);return c.preventDefault()}}}});
define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(f,k,r){k.defaultCommands=[{name:"addCursorAbove",exec:function(e){e.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readonly:!0},{name:"addCursorBelow",exec:function(e){e.selectMoreLines(1)},bindKey:{win:"Ctrl-Alt-Down",mac:"Ctrl-Alt-Down"},scrollIntoView:"cursor",readonly:!0},{name:"addCursorAboveSkipCurrent",exec:function(e){e.selectMoreLines(-1,
!0)},bindKey:{win:"Ctrl-Alt-Shift-Up",mac:"Ctrl-Alt-Shift-Up"},scrollIntoView:"cursor",readonly:!0},{name:"addCursorBelowSkipCurrent",exec:function(e){e.selectMoreLines(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Down",mac:"Ctrl-Alt-Shift-Down"},scrollIntoView:"cursor",readonly:!0},{name:"selectMoreBefore",exec:function(e){e.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readonly:!0},{name:"selectMoreAfter",exec:function(e){e.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",
mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readonly:!0},{name:"selectNextBefore",exec:function(e){e.selectMore(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Left",mac:"Ctrl-Alt-Shift-Left"},scrollIntoView:"cursor",readonly:!0},{name:"selectNextAfter",exec:function(e){e.selectMore(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Right",mac:"Ctrl-Alt-Shift-Right"},scrollIntoView:"cursor",readonly:!0},{name:"splitIntoLines",exec:function(e){e.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readonly:!0},
{name:"alignCursors",exec:function(e){e.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",exec:function(e){e.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readonly:!0}];k.multiSelectCommands=[{name:"singleSelection",bindKey:"esc",exec:function(e){e.exitMultiSelectMode()},scrollIntoView:"cursor",readonly:!0,isAvailable:function(e){return e&&e.inMultiSelectMode}}];f=f("../keyboard/hash_handler").HashHandler;k.keyboardHandler=
new f(k.multiSelectCommands)});
define("ace/multi_select","require exports module ace/range_list ace/range ace/selection ace/mouse/multi_select_handler ace/lib/event ace/lib/lang ace/commands/multi_select_commands ace/search ace/edit_session ace/editor ace/config".split(" "),function(f,k,r){function e(a){a.$multiselectOnSessionChange||(a.$onAddRange=a.$onAddRange.bind(a),a.$onRemoveRange=a.$onRemoveRange.bind(a),a.$onMultiSelect=a.$onMultiSelect.bind(a),a.$onSingleSelect=a.$onSingleSelect.bind(a),a.$multiselectOnSessionChange=k.onSessionChange.bind(a),
a.$checkMultiselectChange=a.$checkMultiselectChange.bind(a),a.$multiselectOnSessionChange(a),a.on("changeSession",a.$multiselectOnSessionChange),a.on("mousedown",d),a.commands.addCommands(h.defaultCommands),m(a))}function m(a){function b(c){d&&(a.renderer.setMouseCursor(""),d=!1)}var c=a.textInput.getElement(),d=!1;g.addListener(c,"keydown",function(c){c=18==c.keyCode&&!(c.ctrlKey||c.shiftKey||c.metaKey);a.$blockSelectEnabled&&c?d||(a.renderer.setMouseCursor("crosshair"),d=!0):d&&b()});g.addListener(c,
"keyup",b);g.addListener(c,"blur",b)}var b=f("./range_list").RangeList,c=f("./range").Range,a=f("./selection").Selection,d=f("./mouse/multi_select_handler").onMouseDown,g=f("./lib/event"),n=f("./lib/lang"),h=f("./commands/multi_select_commands");k.commands=h.defaultCommands.concat(h.multiSelectCommands);var t=new (f("./search").Search);r=f("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(r.prototype);(function(){this.rangeList=this.ranges=
null;this.addRange=function(a,b){if(a){if(!this.inMultiSelectMode&&0===this.rangeCount){var c=this.toOrientedRange();this.rangeList.add(c);this.rangeList.add(a);if(2!=this.rangeList.ranges.length)return this.rangeList.removeAll(),b||this.fromOrientedRange(a);this.rangeList.removeAll();this.rangeList.add(c);this.$onAddRange(c)}a.cursor||(a.cursor=a.end);c=this.rangeList.add(a);this.$onAddRange(a);c.length&&this.$onRemoveRange(c);1<this.rangeCount&&!this.inMultiSelectMode&&(this._signal("multiSelect"),
this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session));return b||this.fromOrientedRange(a)}};this.toSingleRange=function(a){a=a||this.ranges[0];var b=this.rangeList.removeAll();b.length&&this.$onRemoveRange(b);a&&this.fromOrientedRange(a)};this.substractPoint=function(a){if(a=this.rangeList.substractPoint(a))return this.$onRemoveRange(a),a[0]};this.mergeOverlappingRanges=function(){var a=this.rangeList.merge();a.length?this.$onRemoveRange(a):this.ranges[0]&&this.fromOrientedRange(this.ranges[0])};
this.$onAddRange=function(a){this.rangeCount=this.rangeList.ranges.length;this.ranges.unshift(a);this._signal("addRange",{range:a})};this.$onRemoveRange=function(a){this.rangeCount=this.rangeList.ranges.length;if(1==this.rangeCount&&this.inMultiSelectMode){var b=this.rangeList.ranges.pop();a.push(b);this.rangeCount=0}for(var c=a.length;c--;){var d=this.ranges.indexOf(a[c]);this.ranges.splice(d,1)}this._signal("removeRange",{ranges:a});0===this.rangeCount&&this.inMultiSelectMode&&(this.inMultiSelectMode=
!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session));(b=b||this.ranges[0])&&!b.isEqual(this.getRange())&&this.fromOrientedRange(b)};this.$initRangeList=function(){this.rangeList||(this.rangeList=new b,this.ranges=[],this.rangeCount=0)};this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]};this.splitIntoLines=function(){if(1<this.rangeCount){var a=this.rangeList.ranges,b=a[a.length-1],a=c.fromPoints(a[0].start,
b.end);this.toSingleRange();this.setSelectionRange(a,b.cursor==b.start)}else{var a=this.getRange(),d=this.isBackwards(),e=a.start.row,b=a.end.row;if(e==b)d?(b=a.end,a=a.start):(b=a.start,a=a.end),this.addRange(c.fromPoints(a,a)),this.addRange(c.fromPoints(b,b));else{var d=[],g=this.getLineRange(e,!0);g.start.column=a.start.column;d.push(g);for(e+=1;e<b;e++)d.push(this.getLineRange(e,!0));g=this.getLineRange(b,!0);g.end.column=a.end.column;d.push(g);d.forEach(this.addRange,this)}}};this.toggleBlockSelection=
function(){if(1<this.rangeCount){var a=this.rangeList.ranges,b=a[a.length-1],a=c.fromPoints(a[0].start,b.end);this.toSingleRange();this.setSelectionRange(a,b.cursor==b.start)}else b=this.session.documentToScreenPosition(this.selectionLead),a=this.session.documentToScreenPosition(this.selectionAnchor),this.rectangularRangeBlock(b,a).forEach(this.addRange,this)};this.rectangularRangeBlock=function(a,b,d){var e=[],g=a.column<b.column;if(g)var f=a.column,h=b.column;else f=b.column,h=a.column;var k=a.row<
b.row;if(k){var n=a.row;a=b.row}else n=b.row,a=a.row;0>f&&(f=0);0>n&&(n=0);for(n==a&&(d=!0);n<=a;n++){b=c.fromPoints(this.session.screenToDocumentPosition(n,f),this.session.screenToDocumentPosition(n,h));if(b.isEmpty()){var m;if(m=r)m=b.end,m=m.row==r.row&&m.column==r.column;if(m)break;var r=b.end}b.cursor=g?b.start:b.end;e.push(b)}k&&e.reverse();if(!d){for(d=e.length-1;e[d].isEmpty()&&0<d;)d--;if(0<d)for(var t=0;e[t].isEmpty();)t++;for(;d>=t;d--)e[d].isEmpty()&&e.splice(d,1)}return e}}).call(a.prototype);
r=f("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor();this.renderer.updateBackMarkers()};this.addSelectionMarker=function(a){a.cursor||(a.cursor=a.end);var b=this.getSelectionStyle();a.marker=this.session.addMarker(a,"ace_selection",b);this.session.$selectionMarkers.push(a);this.session.selectionMarkerCount=this.session.$selectionMarkers.length;return a};this.removeSelectionMarker=function(a){a.marker&&(this.session.removeMarker(a.marker),a=this.session.$selectionMarkers.indexOf(a),
-1!=a&&this.session.$selectionMarkers.splice(a,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length)};this.removeSelectionMarkers=function(a){for(var b=this.session.$selectionMarkers,c=a.length;c--;){var d=a[c];d.marker&&(this.session.removeMarker(d.marker),d=b.indexOf(d),-1!=d&&b.splice(d,1))}this.session.selectionMarkerCount=b.length};this.$onAddRange=function(a){this.addSelectionMarker(a.range);this.renderer.updateCursor();this.renderer.updateBackMarkers()};this.$onRemoveRange=
function(a){this.removeSelectionMarkers(a.ranges);this.renderer.updateCursor();this.renderer.updateBackMarkers()};this.$onMultiSelect=function(a){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(h.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())};this.$onSingleSelect=function(a){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=
!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(h.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))};this.$onMultiSelectExec=function(a){var b=a.command,c=a.editor;if(c.multiSelect)return b.multiSelectAction?"forEach"==b.multiSelectAction?a=c.forEachSelection(b,a.args):"forEachLine"==b.multiSelectAction?a=c.forEachSelection(b,a.args,!0):"single"==
b.multiSelectAction?(c.exitMultiSelectMode(),a=b.exec(c,a.args||{})):a=b.multiSelectAction(c,a.args||{}):(a=b.exec(c,a.args||{}),c.multiSelect.addRange(c.multiSelect.toOrientedRange()),c.multiSelect.mergeOverlappingRanges()),a};this.forEachSelection=function(b,c,d){if(!this.inVirtualSelectionMode){var e=!0==d||d&&d.$byLines,g=this.session,f=this.selection,h=f.rangeList;d=(d&&d.keepOrder?f:h).ranges;var k;if(!d.length)return b.exec?b.exec(this,c||{}):b(this,c||{});h=f._eventRegistry;f._eventRegistry=
{};var n=new a(g);this.inVirtualSelectionMode=!0;for(var m=d.length;m--;){if(e)for(;0<m&&d[m].start.row==d[m-1].end.row;)m--;n.fromOrientedRange(d[m]);n.index=m;this.selection=g.selection=n;var r=b.exec?b.exec(this,c||{}):b(this,c||{});k||void 0===r||(k=r);n.toOrientedRange(d[m])}n.detach();this.selection=g.selection=f;this.inVirtualSelectionMode=!1;f._eventRegistry=h;f.mergeOverlappingRanges();b=this.renderer.$scrollAnimation;this.onCursorChange();this.onSelectionChange();b&&b.from==b.to&&this.renderer.animateScrolling(b.from);
return k}};this.exitMultiSelectMode=function(){this.inMultiSelectMode&&!this.inVirtualSelectionMode&&this.multiSelect.toSingleRange()};this.getSelectedText=function(){var a="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var a=this.multiSelect.rangeList.ranges,b=[],c=0;c<a.length;c++)b.push(this.session.getTextRange(a[c]));c=this.session.getDocument().getNewLineCharacter();a=b.join(c);a.length==(b.length-1)*c.length&&(a="")}else this.selection.isEmpty()||(a=this.session.getTextRange(this.getSelectionRange()));
return a};this.$checkMultiselectChange=function(a,b){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var c=this.multiSelect.ranges[0];this.multiSelect.isEmpty()&&b==this.multiSelect.anchor||(c=b==this.multiSelect.anchor?c.cursor==c.start?c.end:c.start:c.cursor,c.row==b.row&&this.session.$clipPositionToDocument(c.row,c.column).column==b.column||this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()))}};this.findAll=function(a,b,c){b=b||{};b.needle=a||b.needle;if(void 0==b.needle){var d=
this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();b.needle=this.session.getTextRange(d)}this.$search.set(b);a=this.$search.findAll(this.session);if(!a.length)return 0;this.$blockScrolling+=1;b=this.multiSelect;c||b.toSingleRange(a[0]);for(c=a.length;c--;)b.addRange(a[c],!0);d&&b.rangeList.rangeAtPoint(d.start)&&b.addRange(d,!0);this.$blockScrolling-=1;return a.length};this.selectMoreLines=function(a,b){var d=this.selection.toOrientedRange(),e=d.cursor==d.end,g=this.session.documentToScreenPosition(d.cursor);
this.selection.$desiredColumn&&(g.column=this.selection.$desiredColumn);var f=this.session.screenToDocumentPosition(g.row+a,g.column);if(d.isEmpty())h=f;else var h=this.session.documentToScreenPosition(e?d.end:d.start),h=this.session.screenToDocumentPosition(h.row+a,h.column);e?(e=c.fromPoints(f,h),e.cursor=e.start):(e=c.fromPoints(h,f),e.cursor=e.end);e.desiredColumn=g.column;if(!this.selection.inMultiSelectMode)this.selection.addRange(d);else if(b)var k=d.cursor;this.selection.addRange(e);k&&this.selection.substractPoint(k)};
this.transposeSelections=function(a){for(var b=this.session,c=b.multiSelect,d=c.ranges,e=d.length;e--;){var g=d[e];if(g.isEmpty()){var f=b.getWordRange(g.start.row,g.start.column);g.start.row=f.start.row;g.start.column=f.start.column;g.end.row=f.end.row;g.end.column=f.end.column}}c.mergeOverlappingRanges();c=[];for(e=d.length;e--;)g=d[e],c.unshift(b.getTextRange(g));0>a?c.unshift(c.pop()):c.push(c.shift());for(e=d.length;e--;)g=d[e],f=g.clone(),b.replace(g,c[e]),g.start.row=f.start.row,g.start.column=
f.start.column};this.selectMore=function(a,b,c){var d=this.session,e=d.multiSelect.toOrientedRange();if(e.isEmpty()&&(e=d.getWordRange(e.start.row,e.start.column),e.cursor=-1==a?e.start:e.end,this.multiSelect.addRange(e),c))return;c=d.getTextRange(e);t.$options.wrap=!0;t.$options.needle=c;t.$options.backwards=-1==a;if(d=t.find(d))d.cursor=-1==a?d.start:d.end,this.$blockScrolling+=1,this.session.unfold(d),this.multiSelect.addRange(d),this.$blockScrolling-=1,this.renderer.scrollCursorIntoView(null,
.5);b&&this.multiSelect.substractPoint(e.cursor)};this.alignCursors=function(){var a=this.session,b=a.multiSelect,d=b.ranges,e=-1,g=d.filter(function(a){if(a.cursor.row==e)return!0;e=a.cursor.row});if(d.length&&g.length!=d.length-1){g.forEach(function(a){b.substractPoint(a.cursor)});var f=0,h=Infinity,k=d.map(function(b){b=b.cursor;var c=a.getLine(b.row).substr(b.column).search(/\S/g);-1==c&&(c=0);b.column>f&&(f=b.column);c<h&&(h=c);return c});d.forEach(function(b,d){var e=b.cursor,g=f-e.column,m=
k[d]-h;g>m?a.insert(e,n.stringRepeat(" ",g-m)):a.remove(new c(e.row,e.column,e.row,e.column-g+m));b.start.column=b.end.column=f;b.start.row=b.end.row=e.row;b.cursor=b.end});b.fromOrientedRange(d[0]);this.renderer.updateCursor();this.renderer.updateBackMarkers()}else{var d=this.selection.getRange(),g=d.start.row,m=d.end.row,r=g==m;if(r){var t=this.session.getLength(),y;do y=this.session.getLine(m);while(/[=:]/.test(y)&&++m<t);do y=this.session.getLine(g);while(/[=:]/.test(y)&&0<--g);0>g&&(g=0);m>=
t&&(m=t-1)}m=this.session.removeFullLines(g,m);m=this.$reAlignText(m,r);this.session.insert({row:g,column:0},m.join("\n")+"\n");r||(d.start.column=0,d.end.column=m[m.length-1].length);this.selection.setRange(d)}};this.$reAlignText=function(a,b){function c(a){return n.stringRepeat(" ",a)}function d(a){return a[2]?c(k)+a[2]+c(m-a[2].length+r)+a[4].replace(/^([=:])\s+/,"$1 "):a[0]}function e(a){return a[2]?c(k+m-a[2].length)+a[2]+c(r," ")+a[4].replace(/^([=:])\s+/,"$1 "):a[0]}function g(a){return a[2]?
c(k)+a[2]+c(r)+a[4].replace(/^([=:])\s+/,"$1 "):a[0]}var f=!0,h=!0,k,m,r;return a.map(function(a){var b=a.match(/(\s*)(.*?)(\s*)([=:].*)/);if(!b)return[a];if(null==k)return k=b[1].length,m=b[2].length,r=b[3].length,b;k+m+r!=b[1].length+b[2].length+b[3].length&&(h=!1);k!=b[1].length&&(f=!1);k>b[1].length&&(k=b[1].length);m<b[2].length&&(m=b[2].length);r>b[3].length&&(r=b[3].length);return b}).map(b?d:f?h?e:d:g)}}).call(r.prototype);k.onSessionChange=function(a){var b=a.session;b&&!b.multiSelect&&(b.$selectionMarkers=
[],b.selection.$initRangeList(),b.multiSelect=b.selection);this.multiSelect=b&&b.multiSelect;if(a=a.oldSession)a.multiSelect.off("addRange",this.$onAddRange),a.multiSelect.off("removeRange",this.$onRemoveRange),a.multiSelect.off("multiSelect",this.$onMultiSelect),a.multiSelect.off("singleSelect",this.$onSingleSelect),a.multiSelect.lead.off("change",this.$checkMultiselectChange),a.multiSelect.anchor.off("change",this.$checkMultiselectChange);b&&(b.multiSelect.on("addRange",this.$onAddRange),b.multiSelect.on("removeRange",
this.$onRemoveRange),b.multiSelect.on("multiSelect",this.$onMultiSelect),b.multiSelect.on("singleSelect",this.$onSingleSelect),b.multiSelect.lead.on("change",this.$checkMultiselectChange),b.multiSelect.anchor.on("change",this.$checkMultiselectChange));b&&this.inMultiSelectMode!=b.selection.inMultiSelectMode&&(b.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())};k.MultiSelect=e;f("./config").defineOptions(r.prototype,"editor",{enableMultiselect:{set:function(a){e(this);a?(this.on("changeSession",
this.$multiselectOnSessionChange),this.on("mousedown",d)):(this.off("changeSession",this.$multiselectOnSessionChange),this.off("mousedown",d))},value:!0},enableBlockSelect:{set:function(a){this.$blockSelectEnabled=a},value:!0}})});
define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(f,k,r){var e=f("../../range").Range;f=k.FoldMode=function(){};(function(){this.foldingStopMarker=this.foldingStartMarker=null;this.getFoldWidget=function(e,b,c){e=e.getLine(c);return this.foldingStartMarker.test(e)?"start":"markbeginend"==b&&this.foldingStopMarker&&this.foldingStopMarker.test(e)?"end":""};this.getFoldWidgetRange=function(e,b,c){return null};this.indentationBlock=function(f,b,c){var a=/\S/,d=f.getLine(b),
g=d.search(a);if(-1!=g){c=c||d.length;for(var k=f.getLength(),h=d=b;++b<k;){var r=f.getLine(b).search(a);if(-1!=r){if(r<=g)break;h=b}}if(h>d)return f=f.getLine(h).length,new e(d,c,h,f)}};this.openingBracketBlock=function(f,b,c,a,d){c={row:c,column:a+1};if(b=f.$findClosingBracket(b,c,d))return d=f.foldWidgets[b.row],null==d&&(d=f.getFoldWidget(b.row)),"start"==d&&b.row>c.row&&(b.row--,b.column=f.getLine(b.row).length),e.fromPoints(c,b)};this.closingBracketBlock=function(f,b,c,a,d){c={row:c,column:a};
if(f=f.$findOpeningBracket(b,c))return f.column++,c.column--,e.fromPoints(f,c)}}).call(f.prototype)});
define("ace/theme/textmate",["require","exports","module","ace/lib/dom"],function(f,k,r){k.isDark=!1;k.cssClass="ace-tm";k.cssText='.ace-tm .ace_gutter {background: #f0f0f0;color: #333;}.ace-tm .ace_print-margin {width: 1px;background: #e8e8e8;}.ace-tm .ace_fold {background-color: #6B72E6;}.ace-tm {background-color: #FFFFFF;color: black;}.ace-tm .ace_cursor {color: black;}.ace-tm .ace_invisible {color: rgb(191, 191, 191);}.ace-tm .ace_storage,.ace-tm .ace_keyword {color: blue;}.ace-tm .ace_constant {color: rgb(197, 6, 11);}.ace-tm .ace_constant.ace_buildin {color: rgb(88, 72, 246);}.ace-tm .ace_constant.ace_language {color: rgb(88, 92, 246);}.ace-tm .ace_constant.ace_library {color: rgb(6, 150, 14);}.ace-tm .ace_invalid {background-color: rgba(255, 0, 0, 0.1);color: red;}.ace-tm .ace_support.ace_function {color: rgb(60, 76, 114);}.ace-tm .ace_support.ace_constant {color: rgb(6, 150, 14);}.ace-tm .ace_support.ace_type,.ace-tm .ace_support.ace_class {color: rgb(109, 121, 222);}.ace-tm .ace_keyword.ace_operator {color: rgb(104, 118, 135);}.ace-tm .ace_string {color: rgb(3, 106, 7);}.ace-tm .ace_comment {color: rgb(76, 136, 107);}.ace-tm .ace_comment.ace_doc {color: rgb(0, 102, 255);}.ace-tm .ace_comment.ace_doc.ace_tag {color: rgb(128, 159, 191);}.ace-tm .ace_constant.ace_numeric {color: rgb(0, 0, 205);}.ace-tm .ace_variable {color: rgb(49, 132, 149);}.ace-tm .ace_xml-pe {color: rgb(104, 104, 91);}.ace-tm .ace_entity.ace_name.ace_function {color: #0000A2;}.ace-tm .ace_heading {color: rgb(12, 7, 255);}.ace-tm .ace_list {color:rgb(185, 6, 144);}.ace-tm .ace_meta.ace_tag {color:rgb(0, 22, 142);}.ace-tm .ace_string.ace_regex {color: rgb(255, 0, 0)}.ace-tm .ace_marker-layer .ace_selection {background: rgb(181, 213, 255);}.ace-tm.ace_multiselect .ace_selection.ace_start {box-shadow: 0 0 3px 0px white;}.ace-tm .ace_marker-layer .ace_step {background: rgb(252, 255, 0);}.ace-tm .ace_marker-layer .ace_stack {background: rgb(164, 229, 101);}.ace-tm .ace_marker-layer .ace_bracket {margin: -1px 0 0 -1px;border: 1px solid rgb(192, 192, 192);}.ace-tm .ace_marker-layer .ace_active-line {background: rgba(0, 0, 0, 0.07);}.ace-tm .ace_gutter-active-line {background-color : #dcdcdc;}.ace-tm .ace_marker-layer .ace_selected-word {background: rgb(250, 250, 255);border: 1px solid rgb(200, 200, 250);}.ace-tm .ace_indent-guide {background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;}';f("../lib/dom").importCssString(k.cssText,
k.cssClass)});
define("ace/line_widgets","require exports module ace/lib/oop ace/lib/dom ace/range".split(" "),function(f,k,r){function e(b){this.session=b;this.session.widgetManager=this;this.session.getRowLength=this.getRowLength;this.session.$getWidgetScreenLength=this.$getWidgetScreenLength;this.updateOnChange=this.updateOnChange.bind(this);this.renderWidgets=this.renderWidgets.bind(this);this.measureWidgets=this.measureWidgets.bind(this);this.session._changedWidgets=[];this.$onChangeEditor=this.$onChangeEditor.bind(this);this.session.on("change",
this.updateOnChange);this.session.on("changeEditor",this.$onChangeEditor)}f("./lib/oop");var m=f("./lib/dom");f("./range");(function(){this.getRowLength=function(b){var c;c=this.lineWidgets?this.lineWidgets[b]&&this.lineWidgets[b].rowCount||0:0;return this.$useWrapMode&&this.$wrapData[b]?this.$wrapData[b].length+1+c:1+c};this.$getWidgetScreenLength=function(){var b=0;this.lineWidgets.forEach(function(c){c&&c.rowCount&&(b+=c.rowCount)});return b};this.$onChangeEditor=function(b){this.attach(b.editor)};
this.attach=function(b){b&&b.widgetManager&&b.widgetManager!=this&&b.widgetManager.detach();this.editor!=b&&(this.detach(),this.editor=b)&&(b.widgetManager=this,b.renderer.on("beforeRender",this.measureWidgets),b.renderer.on("afterRender",this.renderWidgets))};this.detach=function(b){if(b=this.editor)this.editor=null,b.widgetManager=null,b.renderer.off("beforeRender",this.measureWidgets),b.renderer.off("afterRender",this.renderWidgets),(b=this.session.lineWidgets)&&b.forEach(function(b){b&&b.el&&
b.el.parentNode&&(b._inDocument=!1,b.el.parentNode.removeChild(b.el))})};this.updateOnChange=function(b){var c=this.session.lineWidgets;if(c){var a=b.start.row,d=b.end.row-a;0!==d&&("remove"==b.action?c.splice(a+1,d).forEach(function(a){a&&this.removeLineWidget(a)},this):(b=Array(d),b.unshift(a,0),c.splice.apply(c,b)),this.$updateRows())}};this.$updateRows=function(){var b=this.session.lineWidgets;if(b){var c=!0;b.forEach(function(a,b){a&&(c=!1,a.row=b)});c&&(this.session.lineWidgets=null)}};this.addLineWidget=
function(b){this.session.lineWidgets||(this.session.lineWidgets=Array(this.session.getLength()));this.session.lineWidgets[b.row]=b;var c=this.editor.renderer;b.html&&!b.el&&(b.el=m.createElement("div"),b.el.innerHTML=b.html);b.el&&(m.addCssClass(b.el,"ace_lineWidgetContainer"),b.el.style.position="absolute",b.el.style.zIndex=5,c.container.appendChild(b.el),b._inDocument=!0);b.coverGutter||(b.el.style.zIndex=3);b.pixelHeight||(b.pixelHeight=b.el.offsetHeight);null==b.rowCount&&(b.rowCount=b.pixelHeight/
c.layerConfig.lineHeight);this.session._emit("changeFold",{data:{start:{row:b.row}}});this.$updateRows();this.renderWidgets(null,c);return b};this.removeLineWidget=function(b){b._inDocument=!1;b.el&&b.el.parentNode&&b.el.parentNode.removeChild(b.el);if(b.editor&&b.editor.destroy)try{b.editor.destroy()}catch(c){}this.session.lineWidgets&&(this.session.lineWidgets[b.row]=void 0);this.session._emit("changeFold",{data:{start:{row:b.row}}});this.$updateRows()};this.onWidgetChanged=function(b){this.session._changedWidgets.push(b);
this.editor&&this.editor.renderer.updateFull()};this.measureWidgets=function(b,c){var a=this.session._changedWidgets,d=c.layerConfig;if(a&&a.length){for(var e=Infinity,f=0;f<a.length;f++){var h=a[f];h._inDocument||(h._inDocument=!0,c.container.appendChild(h.el));h.h=h.el.offsetHeight;h.fixedWidth||(h.w=h.el.offsetWidth,h.screenWidth=Math.ceil(h.w/d.characterWidth));var k=h.h/d.lineHeight;h.coverLine&&(k-=this.session.getRowLineCount(h.row),0>k&&(k=0));h.rowCount!=k&&(h.rowCount=k,h.row<e&&(e=h.row))}Infinity!=
e&&(this.session._emit("changeFold",{data:{start:{row:e}}}),this.session.lineWidgetWidth=null);this.session._changedWidgets=[]}};this.renderWidgets=function(b,c){var a=c.layerConfig,d=this.session.lineWidgets;if(d){for(var e=Math.min(this.firstRow,a.firstRow),f=Math.max(this.lastRow,a.lastRow,d.length);0<e&&!d[e];)e--;this.firstRow=a.firstRow;this.lastRow=a.lastRow;for(c.$cursorLayer.config=a;e<=f;e++){var h=d[e];if(h&&h.el){h._inDocument||(h._inDocument=!0,c.container.appendChild(h.el));var k=c.$cursorLayer.getPixelPosition({row:e,
column:0},!0).top;h.coverLine||(k+=a.lineHeight*this.session.getRowLineCount(h.row));h.el.style.top=k-a.offset+"px";k=h.coverGutter?0:c.gutterWidth;h.fixedWidth||(k-=c.scrollLeft);h.el.style.left=k+"px";h.el.style.right=h.fixedWidth?c.scrollBar.getWidth()+"px":""}}}}}).call(e.prototype);k.LineWidgets=e});
define("ace/ext/error_marker","require exports module ace/line_widgets ace/lib/dom ace/range".split(" "),function(f,k,r){function e(a,b,e){a=a.getAnnotations().sort(c.comparePoints);if(a.length){var f;a:{f={row:b,column:-1};for(var h=c.comparePoints,k=0,l=a.length-1;k<=l;){var m=k+l>>1,r=h(f,a[m]);if(0<r)k=m+1;else if(0>r)l=m-1;else{f=m;break a}}f=-(k+1)}0>f&&(f=-f-1);f>=a.length?f=0<e?0:a.length-1:0===f&&0>e&&(f=a.length-1);if((h=a[f])&&e){if(h.row===b){do h=a[f+=e];while(h&&h.row===b);if(!h)return a.slice()}k=
[];b=h.row;do k[0>e?"unshift":"push"](h),h=a[f+=e];while(h&&h.row==b);return k.length&&k}}}var m=f("../line_widgets").LineWidgets,b=f("../lib/dom"),c=f("../range").Range;k.showErrorMarker=function(a,c){var g=a.session;g.widgetManager||(g.widgetManager=new m(g),g.widgetManager.attach(a));var f=a.getCursorPosition(),h=f.row,k=g.lineWidgets&&g.lineWidgets[h];k?k.destroy():h-=c;if(h=e(g,h,c))k=h[0],f.column=(k.pos&&"number"!=typeof k.column?k.pos.sc:k.column)||0,f.row=k.row,k=a.renderer.$gutterLayer.$annotations[f.row];
else{if(k)return;k={text:["Looks good!"],className:"ace_ok"}}a.session.unfold(f.row);a.selection.moveToPosition(f);var l={row:f.row,fixedWidth:!0,coverGutter:!0,el:b.createElement("div")},h=l.el.appendChild(b.createElement("div")),p=l.el.appendChild(b.createElement("div"));p.className="error_widget_arrow "+k.className;f=a.renderer.$cursorLayer.getPixelPosition(f).left;p.style.left=f+a.renderer.gutterWidth-5+"px";l.el.className="error_widget_wrapper";h.className="error_widget "+k.className;h.innerHTML=
k.text.join("<br>");h.appendChild(b.createElement("div"));var r=function(a,b,c){if(0===b&&("esc"===c||"return"===c))return l.destroy(),{command:"null"}};l.destroy=function(){a.$mouseHandler.isMousePressed||(a.keyBinding.removeKeyboardHandler(r),g.widgetManager.removeLineWidget(l),a.off("changeSelection",l.destroy),a.off("changeSession",l.destroy),a.off("mouseup",l.destroy),a.off("change",l.destroy))};a.keyBinding.addKeyboardHandler(r);a.on("changeSelection",l.destroy);a.on("changeSession",l.destroy);
a.on("mouseup",l.destroy);a.on("change",l.destroy);a.session.widgetManager.addLineWidget(l);l.el.onmousedown=a.focus.bind(a);a.renderer.scrollCursorIntoView(null,.5,{bottom:l.el.offsetHeight})};b.importCssString("    .error_widget_wrapper {        background: inherit;        color: inherit;        border:none    }    .error_widget {        border-top: solid 2px;        border-bottom: solid 2px;        margin: 5px 0;        padding: 10px 40px;        white-space: pre-wrap;    }    .error_widget.ace_error, .error_widget_arrow.ace_error{        border-color: #ff5a5a    }    .error_widget.ace_warning, .error_widget_arrow.ace_warning{        border-color: #F1D817    }    .error_widget.ace_info, .error_widget_arrow.ace_info{        border-color: #5a5a5a    }    .error_widget.ace_ok, .error_widget_arrow.ace_ok{        border-color: #5aaa5a    }    .error_widget_arrow {        position: absolute;        border: solid 5px;        border-top-color: transparent!important;        border-right-color: transparent!important;        border-left-color: transparent!important;        top: -5px;    }",
"")});
define("ace/ace","require exports module ace/lib/fixoldbrowsers ace/lib/dom ace/lib/event ace/editor ace/edit_session ace/undomanager ace/virtual_renderer ace/worker/worker_client ace/keyboard/hash_handler ace/placeholder ace/multi_select ace/mode/folding/fold_mode ace/theme/textmate ace/ext/error_marker ace/config".split(" "),function(f,k,r){f("./lib/fixoldbrowsers");var e=f("./lib/dom"),m=f("./lib/event"),b=f("./editor").Editor,c=f("./edit_session").EditSession,a=f("./undomanager").UndoManager,d=
f("./virtual_renderer").VirtualRenderer;f("./worker/worker_client");f("./keyboard/hash_handler");f("./placeholder");f("./multi_select");f("./mode/folding/fold_mode");f("./theme/textmate");f("./ext/error_marker");k.config=f("./config");k.require=f;k.edit=function(a){if("string"==typeof a){var c=a;a=document.getElementById(c);if(!a)throw Error("ace.edit can't find div #"+c);}if(a&&a.env&&a.env.editor instanceof b)return a.env.editor;c="";if(a&&/input|textarea/i.test(a.tagName)){var f=a,c=f.value;a=
e.createElement("pre");f.parentNode.replaceChild(a,f)}else c=e.getInnerText(a),a.innerHTML="";c=k.createEditSession(c);a=new b(new d(a));a.setSession(c);var r={document:c,editor:a,onResize:a.resize.bind(a,null)};f&&(r.textarea=f);m.addListener(window,"resize",r.onResize);a.on("destroy",function(){m.removeListener(window,"resize",r.onResize);r.editor.container.env=null});a.container.env=a.env=r;return a};k.createEditSession=function(b,d){var e=new c(b,d);e.setUndoManager(new a);return e};k.EditSession=
c;k.UndoManager=a});(function(){window.require(["ace/ace"],function(f){f&&f.config.init(!0);window.ace||(window.ace=f);for(var k in f)f.hasOwnProperty(k)&&(window.ace[k]=f[k])})})();
