jquery-ace-rails 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +36 -0
- data/lib/jquery-ace-rails.rb +5 -0
- data/lib/jquery-ace-rails/engine.rb +4 -0
- data/lib/jquery-ace-rails/version.rb +3 -0
- data/vendor/assets/javascripts/jquery-ace/jquery-ace.coffee +126 -0
- data/vendor/assets/javascripts/jquery-ace/jquery-ace.js +195 -0
- data/vendor/assets/javascripts/jquery-ace/jquery-ace.min.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/ace.js +11 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/ext-static_highlight.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/ext-textarea.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/keybinding-emacs.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/keybinding-vim.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-abap.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-asciidoc.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-c9search.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-c_cpp.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-clojure.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-coffee.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-coldfusion.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-csharp.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-css.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-dart.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-diff.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-dot.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-glsl.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-golang.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-groovy.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-haml.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-haxe.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-html.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-jade.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-java.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-javascript.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-json.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-jsp.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-jsx.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-latex.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-less.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-liquid.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-lisp.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-lua.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-luapage.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-lucene.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-makefile.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-markdown.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-objectivec.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-ocaml.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-perl.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-pgsql.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-php.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-powershell.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-python.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-r.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-rdoc.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-rhtml.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-ruby.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-scad.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-scala.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-scss.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-sh.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-sql.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-stylus.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-svg.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-tcl.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-tex.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-text.js +0 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-textile.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-typescript.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-xml.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-xquery.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-yaml.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-ambiance.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-chaos.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-chrome.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-clouds.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-clouds_midnight.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-cobalt.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-crimson_editor.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-dawn.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-dreamweaver.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-eclipse.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-github.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-idle_fingers.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-kr.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-merbivore.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-merbivore_soft.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-mono_industrial.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-monokai.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-pastel_on_dark.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-solarized_dark.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-solarized_light.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-textmate.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow_night.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow_night_blue.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow_night_bright.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow_night_eighties.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-twilight.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-vibrant_ink.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-xcode.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-coffee.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-css.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-javascript.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-json.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-xquery.js +1 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/ace.js +14262 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/ext-static_highlight.js +96 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/ext-textarea.js +591 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/keybinding-emacs.js +364 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/keybinding-vim.js +1646 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-abap.js +259 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-asciidoc.js +372 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-c9search.js +187 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-c_cpp.js +765 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-clojure.js +325 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-coffee.js +520 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-coldfusion.js +1725 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-csharp.js +605 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-css.js +680 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-dart.js +279 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-diff.js +163 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-dot.js +348 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-glsl.js +838 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-golang.js +660 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-groovy.js +1082 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-haml.js +440 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-haxe.js +610 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-html.js +1850 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-jade.js +2035 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-java.js +1041 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-javascript.js +921 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-json.js +574 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-jsp.js +1371 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-jsx.js +635 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-latex.js +217 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-less.js +394 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-liquid.js +921 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-lisp.js +142 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-lua.js +609 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-luapage.js +2463 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-lucene.js +64 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-makefile.js +314 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-markdown.js +2228 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-objectivec.js +655 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-ocaml.js +448 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-perl.js +319 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-pgsql.js +928 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-php.js +2299 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-powershell.js +611 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-python.js +290 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-r.js +410 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-rdoc.js +189 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-rhtml.js +2138 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-ruby.js +410 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-scad.js +698 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-scala.js +1070 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-scss.js +416 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-sh.js +232 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-sql.js +145 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-stylus.js +474 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-svg.js +1490 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-tcl.js +342 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-tex.js +171 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-text.js +0 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-textile.js +175 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-typescript.js +1011 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-xml.js +792 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-xquery.js +676 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-yaml.js +298 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-ambiance.js +202 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-chaos.js +167 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-chrome.js +161 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-clouds.js +135 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-clouds_midnight.js +136 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-cobalt.js +150 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-crimson_editor.js +154 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-dawn.js +146 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-dreamweaver.js +173 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-eclipse.js +122 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-github.js +136 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-idle_fingers.js +136 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-kr.js +143 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-merbivore.js +135 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-merbivore_soft.js +136 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-mono_industrial.js +148 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-monokai.js +140 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-pastel_on_dark.js +148 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-solarized_dark.js +128 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-solarized_light.js +131 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-textmate.js +163 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow.js +147 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow_night.js +147 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow_night_blue.js +145 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow_night_bright.js +147 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow_night_eighties.js +144 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-twilight.js +147 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-vibrant_ink.js +131 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-xcode.js +125 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-coffee.js +6985 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-css.js +7741 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-javascript.js +6387 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-json.js +2228 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-xquery.js +21719 -0
- data/vendor/assets/javascripts/jquery-ace/vendor/jquery-1.8.3.min.js +2 -0
- metadata +249 -0
@@ -0,0 +1,342 @@
|
|
1
|
+
/* ***** BEGIN LICENSE BLOCK *****
|
2
|
+
* Distributed under the BSD license:
|
3
|
+
*
|
4
|
+
* Copyright (c) 2010, Ajax.org B.V.
|
5
|
+
* All rights reserved.
|
6
|
+
*
|
7
|
+
* Redistribution and use in source and binary forms, with or without
|
8
|
+
* modification, are permitted provided that the following conditions are met:
|
9
|
+
* * Redistributions of source code must retain the above copyright
|
10
|
+
* notice, this list of conditions and the following disclaimer.
|
11
|
+
* * Redistributions in binary form must reproduce the above copyright
|
12
|
+
* notice, this list of conditions and the following disclaimer in the
|
13
|
+
* documentation and/or other materials provided with the distribution.
|
14
|
+
* * Neither the name of Ajax.org B.V. nor the
|
15
|
+
* names of its contributors may be used to endorse or promote products
|
16
|
+
* derived from this software without specific prior written permission.
|
17
|
+
*
|
18
|
+
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
19
|
+
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
20
|
+
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
21
|
+
* DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
|
22
|
+
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
23
|
+
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
|
24
|
+
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
25
|
+
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
26
|
+
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
27
|
+
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
28
|
+
*
|
29
|
+
* ***** END LICENSE BLOCK ***** */
|
30
|
+
|
31
|
+
define('ace/mode/tcl', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text', 'ace/tokenizer', 'ace/mode/folding/cstyle', 'ace/mode/tcl_highlight_rules', 'ace/mode/matching_brace_outdent', 'ace/range'], function(require, exports, module) {
|
32
|
+
|
33
|
+
|
34
|
+
var oop = require("../lib/oop");
|
35
|
+
var TextMode = require("./text").Mode;
|
36
|
+
var Tokenizer = require("../tokenizer").Tokenizer;
|
37
|
+
var CStyleFoldMode = require("./folding/cstyle").FoldMode;
|
38
|
+
var TclHighlightRules = require("./tcl_highlight_rules").TclHighlightRules;
|
39
|
+
var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
|
40
|
+
var Range = require("../range").Range;
|
41
|
+
|
42
|
+
var Mode = function() {
|
43
|
+
this.$tokenizer = new Tokenizer(new TclHighlightRules().getRules());
|
44
|
+
this.$outdent = new MatchingBraceOutdent();
|
45
|
+
this.foldingRules = new CStyleFoldMode();
|
46
|
+
};
|
47
|
+
oop.inherits(Mode, TextMode);
|
48
|
+
|
49
|
+
(function() {
|
50
|
+
|
51
|
+
this.toggleCommentLines = function(state, doc, startRow, endRow) {
|
52
|
+
var outdent = true;
|
53
|
+
var re = /^(\s*)#/;
|
54
|
+
|
55
|
+
for (var i=startRow; i<= endRow; i++) {
|
56
|
+
if (!re.test(doc.getLine(i))) {
|
57
|
+
outdent = false;
|
58
|
+
break;
|
59
|
+
}
|
60
|
+
}
|
61
|
+
|
62
|
+
if (outdent) {
|
63
|
+
var deleteRange = new Range(0, 0, 0, 0);
|
64
|
+
for (var i=startRow; i<= endRow; i++)
|
65
|
+
{
|
66
|
+
var line = doc.getLine(i);
|
67
|
+
var m = line.match(re);
|
68
|
+
deleteRange.start.row = i;
|
69
|
+
deleteRange.end.row = i;
|
70
|
+
deleteRange.end.column = m[0].length;
|
71
|
+
doc.replace(deleteRange, m[1]);
|
72
|
+
}
|
73
|
+
}
|
74
|
+
else {
|
75
|
+
doc.indentRows(startRow, endRow, "#");
|
76
|
+
}
|
77
|
+
};
|
78
|
+
|
79
|
+
this.getNextLineIndent = function(state, line, tab) {
|
80
|
+
var indent = this.$getIndent(line);
|
81
|
+
|
82
|
+
var tokenizedLine = this.$tokenizer.getLineTokens(line, state);
|
83
|
+
var tokens = tokenizedLine.tokens;
|
84
|
+
|
85
|
+
if (tokens.length && tokens[tokens.length-1].type == "comment") {
|
86
|
+
return indent;
|
87
|
+
}
|
88
|
+
|
89
|
+
if (state == "start") {
|
90
|
+
var match = line.match(/^.*[\{\(\[]\s*$/);
|
91
|
+
if (match) {
|
92
|
+
indent += tab;
|
93
|
+
}
|
94
|
+
}
|
95
|
+
|
96
|
+
return indent;
|
97
|
+
};
|
98
|
+
|
99
|
+
this.checkOutdent = function(state, line, input) {
|
100
|
+
return this.$outdent.checkOutdent(line, input);
|
101
|
+
};
|
102
|
+
|
103
|
+
this.autoOutdent = function(state, doc, row) {
|
104
|
+
this.$outdent.autoOutdent(doc, row);
|
105
|
+
};
|
106
|
+
|
107
|
+
}).call(Mode.prototype);
|
108
|
+
|
109
|
+
exports.Mode = Mode;
|
110
|
+
});
|
111
|
+
|
112
|
+
define('ace/mode/folding/cstyle', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/range', 'ace/mode/folding/fold_mode'], function(require, exports, module) {
|
113
|
+
|
114
|
+
|
115
|
+
var oop = require("../../lib/oop");
|
116
|
+
var Range = require("../../range").Range;
|
117
|
+
var BaseFoldMode = require("./fold_mode").FoldMode;
|
118
|
+
|
119
|
+
var FoldMode = exports.FoldMode = function() {};
|
120
|
+
oop.inherits(FoldMode, BaseFoldMode);
|
121
|
+
|
122
|
+
(function() {
|
123
|
+
|
124
|
+
this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
|
125
|
+
this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
|
126
|
+
|
127
|
+
this.getFoldWidgetRange = function(session, foldStyle, row) {
|
128
|
+
var line = session.getLine(row);
|
129
|
+
var match = line.match(this.foldingStartMarker);
|
130
|
+
if (match) {
|
131
|
+
var i = match.index;
|
132
|
+
|
133
|
+
if (match[1])
|
134
|
+
return this.openingBracketBlock(session, match[1], row, i);
|
135
|
+
|
136
|
+
return session.getCommentFoldRange(row, i + match[0].length, 1);
|
137
|
+
}
|
138
|
+
|
139
|
+
if (foldStyle !== "markbeginend")
|
140
|
+
return;
|
141
|
+
|
142
|
+
var match = line.match(this.foldingStopMarker);
|
143
|
+
if (match) {
|
144
|
+
var i = match.index + match[0].length;
|
145
|
+
|
146
|
+
if (match[1])
|
147
|
+
return this.closingBracketBlock(session, match[1], row, i);
|
148
|
+
|
149
|
+
return session.getCommentFoldRange(row, i, -1);
|
150
|
+
}
|
151
|
+
};
|
152
|
+
|
153
|
+
}).call(FoldMode.prototype);
|
154
|
+
|
155
|
+
});
|
156
|
+
|
157
|
+
define('ace/mode/tcl_highlight_rules', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text_highlight_rules'], function(require, exports, module) {
|
158
|
+
|
159
|
+
|
160
|
+
var oop = require("../lib/oop");
|
161
|
+
var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
|
162
|
+
|
163
|
+
var TclHighlightRules = function() {
|
164
|
+
|
165
|
+
this.$rules = {
|
166
|
+
"start" : [
|
167
|
+
{
|
168
|
+
token : "comment",
|
169
|
+
regex : "#.*\\\\$",
|
170
|
+
next : "commentfollow"
|
171
|
+
}, {
|
172
|
+
token : "comment",
|
173
|
+
regex : "#.*$"
|
174
|
+
}, {
|
175
|
+
token : "support.function",
|
176
|
+
regex : '[\\\\]$',
|
177
|
+
next : "splitlineStart"
|
178
|
+
}, {
|
179
|
+
token : "text",
|
180
|
+
regex : '[\\\\](?:["]|[{]|[}]|[[]|[]]|[$]|[\])'
|
181
|
+
}, {
|
182
|
+
token : "text", // last value before command
|
183
|
+
regex : '^|[^{][;][^}]|[/\r/]',
|
184
|
+
next : "commandItem"
|
185
|
+
}, {
|
186
|
+
token : "string", // single line
|
187
|
+
regex : '[ ]*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
|
188
|
+
}, {
|
189
|
+
token : "string", // multi line """ string start
|
190
|
+
regex : '[ ]*["]',
|
191
|
+
next : "qqstring"
|
192
|
+
}, {
|
193
|
+
token : "variable.instancce", // variable xotcl with braces
|
194
|
+
regex : "[$]",
|
195
|
+
next : "variable"
|
196
|
+
}, {
|
197
|
+
token : "support.function",
|
198
|
+
regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|{\\*}|;|::"
|
199
|
+
}, {
|
200
|
+
token : "identifier",
|
201
|
+
regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
|
202
|
+
}, {
|
203
|
+
token : "paren.lparen",
|
204
|
+
regex : "[[{]",
|
205
|
+
next : "commandItem"
|
206
|
+
}, {
|
207
|
+
token : "paren.lparen",
|
208
|
+
regex : "[(]"
|
209
|
+
}, {
|
210
|
+
token : "paren.rparen",
|
211
|
+
regex : "[\\])}]"
|
212
|
+
}, {
|
213
|
+
token : "text",
|
214
|
+
regex : "\\s+"
|
215
|
+
}
|
216
|
+
],
|
217
|
+
"commandItem" : [
|
218
|
+
{
|
219
|
+
token : "comment",
|
220
|
+
regex : "#.*\\\\$",
|
221
|
+
next : "commentfollow"
|
222
|
+
}, {
|
223
|
+
token : "comment",
|
224
|
+
regex : "#.*$",
|
225
|
+
next : "start"
|
226
|
+
}, {
|
227
|
+
token : "string", // single line
|
228
|
+
regex : '[ ]*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
|
229
|
+
}, {
|
230
|
+
token : "variable.instancce", // variable xotcl with braces
|
231
|
+
regex : "[$]",
|
232
|
+
next : "variable"
|
233
|
+
}, {
|
234
|
+
token : "support.function",
|
235
|
+
regex : "(?:[:][:])[a-zA-Z0-9_/]+(?:[:][:])",
|
236
|
+
next : "commandItem"
|
237
|
+
}, {
|
238
|
+
token : "support.function",
|
239
|
+
regex : "[a-zA-Z0-9_/]+(?:[:][:])",
|
240
|
+
next : "commandItem"
|
241
|
+
}, {
|
242
|
+
token : "support.function",
|
243
|
+
regex : "(?:[:][:])",
|
244
|
+
next : "commandItem"
|
245
|
+
}, {
|
246
|
+
token : "support.function",
|
247
|
+
regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|{\\*}|;|::"
|
248
|
+
}, {
|
249
|
+
token : "keyword",
|
250
|
+
regex : "[a-zA-Z0-9_/]+",
|
251
|
+
next : "start"
|
252
|
+
} ],
|
253
|
+
"commentfollow" : [
|
254
|
+
{
|
255
|
+
token : "comment",
|
256
|
+
regex : ".*\\\\$",
|
257
|
+
next : "commentfollow"
|
258
|
+
}, {
|
259
|
+
token : "comment",
|
260
|
+
regex : '.+',
|
261
|
+
next : "start"
|
262
|
+
} ],
|
263
|
+
"splitlineStart" : [
|
264
|
+
{
|
265
|
+
token : "text",
|
266
|
+
regex : "^.",
|
267
|
+
next : "start"
|
268
|
+
}],
|
269
|
+
"variable" : [
|
270
|
+
{
|
271
|
+
token : "variable.instance", // variable xotcl with braces
|
272
|
+
regex : "(?:[:][:])?[a-zA-Z_\\d]+(?:(?:[:][:])?[a-zA-Z_\\d]+)?(?:[(][a-zA-Z_\\d]+[)])?",
|
273
|
+
next : "start"
|
274
|
+
}, {
|
275
|
+
token : "variable.instance", // variable tcl
|
276
|
+
regex : "[a-zA-Z_\\d]+(?:[(][a-zA-Z_\\d]+[)])?",
|
277
|
+
next : "start"
|
278
|
+
}, {
|
279
|
+
token : "variable.instance", // variable tcl with braces
|
280
|
+
regex : "{?[a-zA-Z_\\d]+}?",
|
281
|
+
next : "start"
|
282
|
+
}],
|
283
|
+
"qqstring" : [ {
|
284
|
+
token : "string", // multi line """ string end
|
285
|
+
regex : '(?:[^\\\\]|\\\\.)*?["]',
|
286
|
+
next : "start"
|
287
|
+
}, {
|
288
|
+
token : "string",
|
289
|
+
regex : '.+'
|
290
|
+
} ]
|
291
|
+
};
|
292
|
+
};
|
293
|
+
|
294
|
+
oop.inherits(TclHighlightRules, TextHighlightRules);
|
295
|
+
|
296
|
+
exports.TclHighlightRules = TclHighlightRules;
|
297
|
+
});
|
298
|
+
|
299
|
+
define('ace/mode/matching_brace_outdent', ['require', 'exports', 'module' , 'ace/range'], function(require, exports, module) {
|
300
|
+
|
301
|
+
|
302
|
+
var Range = require("../range").Range;
|
303
|
+
|
304
|
+
var MatchingBraceOutdent = function() {};
|
305
|
+
|
306
|
+
(function() {
|
307
|
+
|
308
|
+
this.checkOutdent = function(line, input) {
|
309
|
+
if (! /^\s+$/.test(line))
|
310
|
+
return false;
|
311
|
+
|
312
|
+
return /^\s*\}/.test(input);
|
313
|
+
};
|
314
|
+
|
315
|
+
this.autoOutdent = function(doc, row) {
|
316
|
+
var line = doc.getLine(row);
|
317
|
+
var match = line.match(/^(\s*\})/);
|
318
|
+
|
319
|
+
if (!match) return 0;
|
320
|
+
|
321
|
+
var column = match[1].length;
|
322
|
+
var openBracePos = doc.findMatchingBracket({row: row, column: column});
|
323
|
+
|
324
|
+
if (!openBracePos || openBracePos.row == row) return 0;
|
325
|
+
|
326
|
+
var indent = this.$getIndent(doc.getLine(openBracePos.row));
|
327
|
+
doc.replace(new Range(row, 0, row, column-1), indent);
|
328
|
+
};
|
329
|
+
|
330
|
+
this.$getIndent = function(line) {
|
331
|
+
var match = line.match(/^(\s+)/);
|
332
|
+
if (match) {
|
333
|
+
return match[1];
|
334
|
+
}
|
335
|
+
|
336
|
+
return "";
|
337
|
+
};
|
338
|
+
|
339
|
+
}).call(MatchingBraceOutdent.prototype);
|
340
|
+
|
341
|
+
exports.MatchingBraceOutdent = MatchingBraceOutdent;
|
342
|
+
});
|
@@ -0,0 +1,171 @@
|
|
1
|
+
/*
|
2
|
+
* tex.js
|
3
|
+
*
|
4
|
+
* Copyright (C) 2009-11 by RStudio, Inc.
|
5
|
+
*
|
6
|
+
* The Initial Developer of the Original Code is
|
7
|
+
* Ajax.org B.V.
|
8
|
+
* Portions created by the Initial Developer are Copyright (C) 2010
|
9
|
+
* the Initial Developer. All Rights Reserved.
|
10
|
+
*
|
11
|
+
* This program is licensed to you under the terms of version 3 of the
|
12
|
+
* GNU Affero General Public License. This program is distributed WITHOUT
|
13
|
+
* ANY EXPRESS OR IMPLIED WARRANTY, INCLUDING THOSE OF NON-INFRINGEMENT,
|
14
|
+
* MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Please refer to the
|
15
|
+
* AGPL (http://www.gnu.org/licenses/agpl-3.0.txt) for more details.
|
16
|
+
*
|
17
|
+
*/
|
18
|
+
define('ace/mode/tex', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text', 'ace/tokenizer', 'ace/mode/text_highlight_rules', 'ace/mode/tex_highlight_rules', 'ace/mode/matching_brace_outdent'], function(require, exports, module) {
|
19
|
+
|
20
|
+
|
21
|
+
var oop = require("../lib/oop");
|
22
|
+
var TextMode = require("./text").Mode;
|
23
|
+
var Tokenizer = require("../tokenizer").Tokenizer;
|
24
|
+
var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
|
25
|
+
var TexHighlightRules = require("./tex_highlight_rules").TexHighlightRules;
|
26
|
+
var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
|
27
|
+
|
28
|
+
var Mode = function(suppressHighlighting) {
|
29
|
+
if (suppressHighlighting)
|
30
|
+
this.$tokenizer = new Tokenizer(new TextHighlightRules().getRules());
|
31
|
+
else
|
32
|
+
this.$tokenizer = new Tokenizer(new TexHighlightRules().getRules());
|
33
|
+
this.$outdent = new MatchingBraceOutdent();
|
34
|
+
};
|
35
|
+
oop.inherits(Mode, TextMode);
|
36
|
+
|
37
|
+
(function() {
|
38
|
+
this.getNextLineIndent = function(state, line, tab) {
|
39
|
+
return this.$getIndent(line);
|
40
|
+
};
|
41
|
+
|
42
|
+
this.allowAutoInsert = function() {
|
43
|
+
return false;
|
44
|
+
};
|
45
|
+
}).call(Mode.prototype);
|
46
|
+
|
47
|
+
exports.Mode = Mode;
|
48
|
+
});
|
49
|
+
define('ace/mode/tex_highlight_rules', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/lang', 'ace/mode/text_highlight_rules'], function(require, exports, module) {
|
50
|
+
|
51
|
+
|
52
|
+
var oop = require("../lib/oop");
|
53
|
+
var lang = require("../lib/lang");
|
54
|
+
var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
|
55
|
+
|
56
|
+
var TexHighlightRules = function(textClass) {
|
57
|
+
|
58
|
+
if (!textClass)
|
59
|
+
textClass = "text";
|
60
|
+
|
61
|
+
this.$rules = {
|
62
|
+
"start" : [
|
63
|
+
{
|
64
|
+
token : "comment",
|
65
|
+
regex : "%.*$"
|
66
|
+
}, {
|
67
|
+
token : textClass, // non-command
|
68
|
+
regex : "\\\\[$&%#\\{\\}]"
|
69
|
+
}, {
|
70
|
+
token : "keyword", // command
|
71
|
+
regex : "\\\\(?:documentclass|usepackage|newcounter|setcounter|addtocounter|value|arabic|stepcounter|newenvironment|renewenvironment|ref|vref|eqref|pageref|label|cite[a-zA-Z]*|tag|begin|end|bibitem)\\b",
|
72
|
+
next : "nospell"
|
73
|
+
}, {
|
74
|
+
token : "keyword", // command
|
75
|
+
regex : "\\\\(?:[a-zA-z0-9]+|[^a-zA-z0-9])"
|
76
|
+
}, {
|
77
|
+
token : "paren.keyword.operator",
|
78
|
+
regex : "[[({]"
|
79
|
+
}, {
|
80
|
+
token : "paren.keyword.operator",
|
81
|
+
regex : "[\\])}]"
|
82
|
+
}, {
|
83
|
+
token : textClass,
|
84
|
+
regex : "\\s+"
|
85
|
+
}
|
86
|
+
],
|
87
|
+
"nospell" : [
|
88
|
+
{
|
89
|
+
token : "comment",
|
90
|
+
regex : "%.*$",
|
91
|
+
next : "start"
|
92
|
+
}, {
|
93
|
+
token : "nospell." + textClass, // non-command
|
94
|
+
regex : "\\\\[$&%#\\{\\}]"
|
95
|
+
}, {
|
96
|
+
token : "keyword", // command
|
97
|
+
regex : "\\\\(?:documentclass|usepackage|newcounter|setcounter|addtocounter|value|arabic|stepcounter|newenvironment|renewenvironment|ref|vref|eqref|pageref|label|cite[a-zA-Z]*|tag|begin|end|bibitem)\\b"
|
98
|
+
}, {
|
99
|
+
token : "keyword", // command
|
100
|
+
regex : "\\\\(?:[a-zA-z0-9]+|[^a-zA-z0-9])",
|
101
|
+
next : "start"
|
102
|
+
}, {
|
103
|
+
token : "paren.keyword.operator",
|
104
|
+
regex : "[[({]"
|
105
|
+
}, {
|
106
|
+
token : "paren.keyword.operator",
|
107
|
+
regex : "[\\])]"
|
108
|
+
}, {
|
109
|
+
token : "paren.keyword.operator",
|
110
|
+
regex : "}",
|
111
|
+
next : "start"
|
112
|
+
}, {
|
113
|
+
token : "nospell." + textClass,
|
114
|
+
regex : "\\s+"
|
115
|
+
}, {
|
116
|
+
token : "nospell." + textClass,
|
117
|
+
regex : "\\w+"
|
118
|
+
}
|
119
|
+
]
|
120
|
+
};
|
121
|
+
};
|
122
|
+
|
123
|
+
oop.inherits(TexHighlightRules, TextHighlightRules);
|
124
|
+
|
125
|
+
exports.TexHighlightRules = TexHighlightRules;
|
126
|
+
});
|
127
|
+
|
128
|
+
define('ace/mode/matching_brace_outdent', ['require', 'exports', 'module' , 'ace/range'], function(require, exports, module) {
|
129
|
+
|
130
|
+
|
131
|
+
var Range = require("../range").Range;
|
132
|
+
|
133
|
+
var MatchingBraceOutdent = function() {};
|
134
|
+
|
135
|
+
(function() {
|
136
|
+
|
137
|
+
this.checkOutdent = function(line, input) {
|
138
|
+
if (! /^\s+$/.test(line))
|
139
|
+
return false;
|
140
|
+
|
141
|
+
return /^\s*\}/.test(input);
|
142
|
+
};
|
143
|
+
|
144
|
+
this.autoOutdent = function(doc, row) {
|
145
|
+
var line = doc.getLine(row);
|
146
|
+
var match = line.match(/^(\s*\})/);
|
147
|
+
|
148
|
+
if (!match) return 0;
|
149
|
+
|
150
|
+
var column = match[1].length;
|
151
|
+
var openBracePos = doc.findMatchingBracket({row: row, column: column});
|
152
|
+
|
153
|
+
if (!openBracePos || openBracePos.row == row) return 0;
|
154
|
+
|
155
|
+
var indent = this.$getIndent(doc.getLine(openBracePos.row));
|
156
|
+
doc.replace(new Range(row, 0, row, column-1), indent);
|
157
|
+
};
|
158
|
+
|
159
|
+
this.$getIndent = function(line) {
|
160
|
+
var match = line.match(/^(\s+)/);
|
161
|
+
if (match) {
|
162
|
+
return match[1];
|
163
|
+
}
|
164
|
+
|
165
|
+
return "";
|
166
|
+
};
|
167
|
+
|
168
|
+
}).call(MatchingBraceOutdent.prototype);
|
169
|
+
|
170
|
+
exports.MatchingBraceOutdent = MatchingBraceOutdent;
|
171
|
+
});
|