ace.define("ace/mode/c9search_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"],function(r,v,m){"use strict";var p=r("../lib/oop"),f=r("../lib/lang"),s=r("./text_highlight_rules").TextHighlightRules,g=function(){this.$rules={start:[{tokenNames:["c9searchresults.constant.numeric","c9searchresults.text","c9searchresults.text","c9searchresults.keyword"],regex:/(^\s+[0-9]+)(:)(\d*\s?)([^\r\n]+)/,onMatch:function(h,i,n){var e=this.splitRegex.exec(h),a=this.tokenNames,o=[{type:a[0],value:e[1]},{type:a[1],value:e[2]}];e[3]&&(" "==e[3]?o[1]={type:a[1],value:e[2]+" "}:o.push({type:a[1],value:e[3]}));var d,t=n[1],l=e[4],u=0;if(t&&t.exec)for(t.lastIndex=0;d=t.exec(l);){var x=l.substring(u,d.index);if(u=t.lastIndex,x&&o.push({type:a[2],value:x}),d[0])o.push({type:a[3],value:d[0]});else if(!x)break}return u<l.length&&o.push({type:a[2],value:l.substr(u)}),o}},{regex:"^Searching for [^\\r\\n]*$",onMatch:function(h,i,n){var e=h.split("\x01");if(e.length<3)return"text";var a,o,t=0,l=[{value:e[t++]+"'",type:"text"},{value:o=e[t++],type:"text"},{value:"'"+e[t++],type:"text"}];for(" in"!==e[2]&&l.push({value:"'"+e[t++]+"'",type:"text"},{value:e[t++],type:"text"}),l.push({value:" "+e[t++]+" ",type:"text"}),e[t+1]?(a=e[t+1],l.push({value:"("+e[t+1]+")",type:"text"}),t+=1):t-=1;t++<e.length;)e[t]&&l.push({value:e[t],type:"text"});o&&(/regex/.test(a)||(o=f.escapeRegExp(o)),/whole/.test(a)&&(o="\\b"+o+"\\b"));var d=o&&function c(h,i){try{return new RegExp(h,i)}catch(n){}}("("+o+")",/ sensitive/.test(a)?"g":"ig");return d&&(n[0]=i,n[1]=d),l}},{regex:"^(?=Found \\d+ matches)",token:"text",next:"numbers"},{token:"string",regex:"^\\S:?[^:]+",next:"numbers"}],numbers:[{regex:"\\d+",token:"constant.numeric"},{regex:"$",token:"text",next:"start"}]},this.normalizeRules()};p.inherits(g,s),v.C9SearchHighlightRules=g}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(r,v,m){"use strict";var p=r("../range").Range,f=function(){};(function(){this.checkOutdent=function(s,c){return!!/^\s+$/.test(s)&&/^\s*\}/.test(c)},this.autoOutdent=function(s,c){var h=s.getLine(c).match(/^(\s*\})/);if(!h)return 0;var i=h[1].length,n=s.findMatchingBracket({row:c,column:i});if(!n||n.row==c)return 0;var e=this.$getIndent(s.getLine(n.row));s.replace(new p(c,0,c,i-1),e)},this.$getIndent=function(s){return s.match(/^\s*/)[0]}}).call(f.prototype),v.MatchingBraceOutdent=f}),ace.define("ace/mode/folding/c9search",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(r,v,m){"use strict";var p=r("../../lib/oop"),f=r("../../range").Range,s=r("./fold_mode").FoldMode,c=v.FoldMode=function(){};p.inherits(c,s),function(){this.foldingStartMarker=/^(\S.*:|Searching for.*)$/,this.foldingStopMarker=/^(\s+|Found.*)$/,this.getFoldWidgetRange=function(g,h,i){var n=g.doc.getAllLines(i),e=n[i],a=/^(Found.*|Searching for.*)$/,t=a.test(e)?a:/^(\S.*:|\s*)$/,l=i,d=i;if(this.foldingStartMarker.test(e)){for(var u=i+1,x=g.getLength();u<x&&!t.test(n[u]);u++);d=u}else if(this.foldingStopMarker.test(e)){for(u=i-1;u>=0&&!t.test(e=n[u]);u--);l=u}if(l!=d){var y=e.length;return t===a&&(y=e.search(/\(Found[^)]+\)$|$/)),new f(l,y,d,0)}}}.call(c.prototype)}),ace.define("ace/mode/c9search",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/c9search_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/c9search"],function(r,v,m){"use strict";var p=r("../lib/oop"),f=r("./text").Mode,s=r("./c9search_highlight_rules").C9SearchHighlightRules,c=r("./matching_brace_outdent").MatchingBraceOutdent,g=r("./folding/c9search").FoldMode,h=function(){this.HighlightRules=s,this.$outdent=new c,this.foldingRules=new g};p.inherits(h,f),function(){this.getNextLineIndent=function(i,n,e){return this.$getIndent(n)},this.checkOutdent=function(i,n,e){return this.$outdent.checkOutdent(n,e)},this.autoOutdent=function(i,n,e){this.$outdent.autoOutdent(n,e)},this.$id="ace/mode/c9search"}.call(h.prototype),v.Mode=h}),ace.require(["ace/mode/c9search"],function(r){"object"==typeof module&&"object"==typeof exports&&module&&(module.exports=r)});