jquery-ace-rails 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (205) hide show
  1. data/README.md +36 -0
  2. data/lib/jquery-ace-rails.rb +5 -0
  3. data/lib/jquery-ace-rails/engine.rb +4 -0
  4. data/lib/jquery-ace-rails/version.rb +3 -0
  5. data/vendor/assets/javascripts/jquery-ace/jquery-ace.coffee +126 -0
  6. data/vendor/assets/javascripts/jquery-ace/jquery-ace.js +195 -0
  7. data/vendor/assets/javascripts/jquery-ace/jquery-ace.min.js +1 -0
  8. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/ace.js +11 -0
  9. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/ext-static_highlight.js +1 -0
  10. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/ext-textarea.js +1 -0
  11. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/keybinding-emacs.js +1 -0
  12. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/keybinding-vim.js +1 -0
  13. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-abap.js +1 -0
  14. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-asciidoc.js +1 -0
  15. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-c9search.js +1 -0
  16. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-c_cpp.js +1 -0
  17. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-clojure.js +1 -0
  18. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-coffee.js +1 -0
  19. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-coldfusion.js +1 -0
  20. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-csharp.js +1 -0
  21. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-css.js +1 -0
  22. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-dart.js +1 -0
  23. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-diff.js +1 -0
  24. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-dot.js +1 -0
  25. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-glsl.js +1 -0
  26. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-golang.js +1 -0
  27. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-groovy.js +1 -0
  28. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-haml.js +1 -0
  29. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-haxe.js +1 -0
  30. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-html.js +1 -0
  31. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-jade.js +1 -0
  32. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-java.js +1 -0
  33. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-javascript.js +1 -0
  34. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-json.js +1 -0
  35. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-jsp.js +1 -0
  36. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-jsx.js +1 -0
  37. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-latex.js +1 -0
  38. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-less.js +1 -0
  39. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-liquid.js +1 -0
  40. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-lisp.js +1 -0
  41. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-lua.js +1 -0
  42. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-luapage.js +1 -0
  43. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-lucene.js +1 -0
  44. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-makefile.js +1 -0
  45. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-markdown.js +1 -0
  46. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-objectivec.js +1 -0
  47. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-ocaml.js +1 -0
  48. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-perl.js +1 -0
  49. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-pgsql.js +1 -0
  50. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-php.js +1 -0
  51. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-powershell.js +1 -0
  52. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-python.js +1 -0
  53. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-r.js +1 -0
  54. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-rdoc.js +1 -0
  55. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-rhtml.js +1 -0
  56. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-ruby.js +1 -0
  57. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-scad.js +1 -0
  58. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-scala.js +1 -0
  59. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-scss.js +1 -0
  60. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-sh.js +1 -0
  61. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-sql.js +1 -0
  62. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-stylus.js +1 -0
  63. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-svg.js +1 -0
  64. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-tcl.js +1 -0
  65. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-tex.js +1 -0
  66. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-text.js +0 -0
  67. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-textile.js +1 -0
  68. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-typescript.js +1 -0
  69. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-xml.js +1 -0
  70. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-xquery.js +1 -0
  71. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/mode-yaml.js +1 -0
  72. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-ambiance.js +1 -0
  73. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-chaos.js +1 -0
  74. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-chrome.js +1 -0
  75. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-clouds.js +1 -0
  76. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-clouds_midnight.js +1 -0
  77. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-cobalt.js +1 -0
  78. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-crimson_editor.js +1 -0
  79. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-dawn.js +1 -0
  80. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-dreamweaver.js +1 -0
  81. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-eclipse.js +1 -0
  82. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-github.js +1 -0
  83. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-idle_fingers.js +1 -0
  84. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-kr.js +1 -0
  85. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-merbivore.js +1 -0
  86. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-merbivore_soft.js +1 -0
  87. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-mono_industrial.js +1 -0
  88. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-monokai.js +1 -0
  89. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-pastel_on_dark.js +1 -0
  90. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-solarized_dark.js +1 -0
  91. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-solarized_light.js +1 -0
  92. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-textmate.js +1 -0
  93. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow.js +1 -0
  94. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow_night.js +1 -0
  95. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow_night_blue.js +1 -0
  96. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow_night_bright.js +1 -0
  97. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-tomorrow_night_eighties.js +1 -0
  98. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-twilight.js +1 -0
  99. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-vibrant_ink.js +1 -0
  100. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/theme-xcode.js +1 -0
  101. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-coffee.js +1 -0
  102. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-css.js +1 -0
  103. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-javascript.js +1 -0
  104. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-json.js +1 -0
  105. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src-min-noconflict/worker-xquery.js +1 -0
  106. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/ace.js +14262 -0
  107. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/ext-static_highlight.js +96 -0
  108. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/ext-textarea.js +591 -0
  109. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/keybinding-emacs.js +364 -0
  110. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/keybinding-vim.js +1646 -0
  111. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-abap.js +259 -0
  112. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-asciidoc.js +372 -0
  113. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-c9search.js +187 -0
  114. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-c_cpp.js +765 -0
  115. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-clojure.js +325 -0
  116. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-coffee.js +520 -0
  117. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-coldfusion.js +1725 -0
  118. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-csharp.js +605 -0
  119. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-css.js +680 -0
  120. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-dart.js +279 -0
  121. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-diff.js +163 -0
  122. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-dot.js +348 -0
  123. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-glsl.js +838 -0
  124. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-golang.js +660 -0
  125. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-groovy.js +1082 -0
  126. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-haml.js +440 -0
  127. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-haxe.js +610 -0
  128. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-html.js +1850 -0
  129. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-jade.js +2035 -0
  130. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-java.js +1041 -0
  131. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-javascript.js +921 -0
  132. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-json.js +574 -0
  133. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-jsp.js +1371 -0
  134. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-jsx.js +635 -0
  135. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-latex.js +217 -0
  136. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-less.js +394 -0
  137. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-liquid.js +921 -0
  138. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-lisp.js +142 -0
  139. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-lua.js +609 -0
  140. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-luapage.js +2463 -0
  141. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-lucene.js +64 -0
  142. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-makefile.js +314 -0
  143. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-markdown.js +2228 -0
  144. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-objectivec.js +655 -0
  145. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-ocaml.js +448 -0
  146. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-perl.js +319 -0
  147. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-pgsql.js +928 -0
  148. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-php.js +2299 -0
  149. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-powershell.js +611 -0
  150. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-python.js +290 -0
  151. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-r.js +410 -0
  152. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-rdoc.js +189 -0
  153. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-rhtml.js +2138 -0
  154. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-ruby.js +410 -0
  155. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-scad.js +698 -0
  156. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-scala.js +1070 -0
  157. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-scss.js +416 -0
  158. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-sh.js +232 -0
  159. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-sql.js +145 -0
  160. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-stylus.js +474 -0
  161. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-svg.js +1490 -0
  162. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-tcl.js +342 -0
  163. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-tex.js +171 -0
  164. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-text.js +0 -0
  165. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-textile.js +175 -0
  166. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-typescript.js +1011 -0
  167. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-xml.js +792 -0
  168. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-xquery.js +676 -0
  169. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/mode-yaml.js +298 -0
  170. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-ambiance.js +202 -0
  171. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-chaos.js +167 -0
  172. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-chrome.js +161 -0
  173. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-clouds.js +135 -0
  174. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-clouds_midnight.js +136 -0
  175. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-cobalt.js +150 -0
  176. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-crimson_editor.js +154 -0
  177. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-dawn.js +146 -0
  178. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-dreamweaver.js +173 -0
  179. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-eclipse.js +122 -0
  180. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-github.js +136 -0
  181. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-idle_fingers.js +136 -0
  182. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-kr.js +143 -0
  183. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-merbivore.js +135 -0
  184. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-merbivore_soft.js +136 -0
  185. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-mono_industrial.js +148 -0
  186. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-monokai.js +140 -0
  187. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-pastel_on_dark.js +148 -0
  188. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-solarized_dark.js +128 -0
  189. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-solarized_light.js +131 -0
  190. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-textmate.js +163 -0
  191. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow.js +147 -0
  192. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow_night.js +147 -0
  193. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow_night_blue.js +145 -0
  194. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow_night_bright.js +147 -0
  195. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-tomorrow_night_eighties.js +144 -0
  196. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-twilight.js +147 -0
  197. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-vibrant_ink.js +131 -0
  198. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/theme-xcode.js +125 -0
  199. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-coffee.js +6985 -0
  200. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-css.js +7741 -0
  201. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-javascript.js +6387 -0
  202. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-json.js +2228 -0
  203. data/vendor/assets/javascripts/jquery-ace/vendor/ace-build/src/worker-xquery.js +21719 -0
  204. data/vendor/assets/javascripts/jquery-ace/vendor/jquery-1.8.3.min.js +2 -0
  205. metadata +249 -0
@@ -0,0 +1,142 @@
1
+ /* ***** BEGIN LICENSE BLOCK *****
2
+ * Distributed under the BSD license:
3
+ *
4
+ * Copyright (c) 2012, 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
+ *
30
+ * Contributor(s):
31
+ *
32
+ *
33
+ *
34
+ * ***** END LICENSE BLOCK ***** */
35
+
36
+ define('ace/mode/lisp', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text', 'ace/tokenizer', 'ace/mode/lisp_highlight_rules'], function(require, exports, module) {
37
+
38
+
39
+ var oop = require("../lib/oop");
40
+ var TextMode = require("./text").Mode;
41
+ var Tokenizer = require("../tokenizer").Tokenizer;
42
+ var LispHighlightRules = require("./lisp_highlight_rules").LispHighlightRules;
43
+
44
+ var Mode = function() {
45
+ var highlighter = new LispHighlightRules();
46
+
47
+ this.$tokenizer = new Tokenizer(highlighter.getRules());
48
+ };
49
+ oop.inherits(Mode, TextMode);
50
+
51
+ (function() {
52
+ }).call(Mode.prototype);
53
+
54
+ exports.Mode = Mode;
55
+ });
56
+
57
+
58
+ define('ace/mode/lisp_highlight_rules', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text_highlight_rules'], function(require, exports, module) {
59
+
60
+
61
+ var oop = require("../lib/oop");
62
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
63
+
64
+ var LispHighlightRules = function() {
65
+ var keywordControl = "case|do|let|loop|if|else|when";
66
+ var keywordOperator = "eq|neq|and|or";
67
+ var constantLanguage = "null|nil";
68
+ var supportFunctions = "cons|car|cdr|cond|lambda|format|setq|setf|quote|eval|append|list|listp|memberp|t|load|progn";
69
+
70
+ var keywordMapper = this.createKeywordMapper({
71
+ "keyword.control": keywordControl,
72
+ "keyword.operator": keywordOperator,
73
+ "constant.language": constantLanguage,
74
+ "support.function": supportFunctions
75
+ }, "identifier", true);
76
+
77
+ this.$rules =
78
+ {
79
+ "start": [
80
+ {
81
+ token : "comment",
82
+ regex : ";.*$"
83
+ },
84
+ {
85
+ "token": ["storage.type.function-type.lisp", "text", "entity.name.function.lisp"],
86
+ "regex": "(?:\\b(?:(defun|defmethod|defmacro))\\b)(\\s+)((?:\\w|\\-|\\!|\\?)*)"
87
+ },
88
+ {
89
+ "token": ["punctuation.definition.constant.character.lisp", "constant.character.lisp"],
90
+ "regex": "(#)((?:\\w|[\\\\+-=<>'\"&#])+)"
91
+ },
92
+ {
93
+ "token": ["punctuation.definition.variable.lisp", "variable.other.global.lisp", "punctuation.definition.variable.lisp"],
94
+ "regex": "(\\*)(\\S*)(\\*)"
95
+ },
96
+ {
97
+ "token" : "constant.numeric", // hex
98
+ "regex" : "0[xX][0-9a-fA-F]+(?:L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
99
+ },
100
+ {
101
+ "token" : "constant.numeric", // float
102
+ "regex" : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?(?:L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
103
+ },
104
+ {
105
+ "token" : keywordMapper,
106
+ "regex" : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
107
+ },
108
+ {
109
+ "token" : "string",
110
+ "regex" : '"(?=.)',
111
+ "next" : "qqstring"
112
+ }
113
+ ],
114
+ "qqstring": [
115
+ {
116
+ "token": "constant.character.escape.lisp",
117
+ "regex": "\\\\."
118
+ },
119
+ {
120
+ "token" : "string",
121
+ "regex" : '[^"\\\\]+',
122
+ "merge" : true
123
+ }, {
124
+ "token" : "string",
125
+ "regex" : "\\\\$",
126
+ "next" : "qqstring",
127
+ "merge" : true
128
+ }, {
129
+ "token" : "string",
130
+ "regex" : '"|$',
131
+ "next" : "start",
132
+ "merge" : true
133
+ }
134
+ ]
135
+ }
136
+
137
+ };
138
+
139
+ oop.inherits(LispHighlightRules, TextHighlightRules);
140
+
141
+ exports.LispHighlightRules = LispHighlightRules;
142
+ });
@@ -0,0 +1,609 @@
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/lua', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text', 'ace/tokenizer', 'ace/mode/lua_highlight_rules', 'ace/mode/folding/lua', '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 LuaHighlightRules = require("./lua_highlight_rules").LuaHighlightRules;
38
+ var LuaFoldMode = require("./folding/lua").FoldMode;
39
+ var Range = require("../range").Range;
40
+
41
+ var Mode = function() {
42
+ this.$tokenizer = new Tokenizer(new LuaHighlightRules().getRules());
43
+ this.foldingRules = new LuaFoldMode();
44
+ };
45
+ oop.inherits(Mode, TextMode);
46
+
47
+ (function() {
48
+ var indentKeywords = {
49
+ "function": 1,
50
+ "then": 1,
51
+ "do": 1,
52
+ "else": 1,
53
+ "elseif": 1,
54
+ "repeat": 1,
55
+ "end": -1,
56
+ "until": -1
57
+ };
58
+ var outdentKeywords = [
59
+ "else",
60
+ "elseif",
61
+ "end",
62
+ "until"
63
+ ];
64
+
65
+ function getNetIndentLevel(tokens) {
66
+ var level = 0;
67
+ for (var i in tokens){
68
+ var token = tokens[i];
69
+ if (token.type == "keyword") {
70
+ if (token.value in indentKeywords) {
71
+ level += indentKeywords[token.value];
72
+ }
73
+ } else if (token.type == "paren.lparen") {
74
+ level ++;
75
+ } else if (token.type == "paren.rparen") {
76
+ level --;
77
+ }
78
+ }
79
+ if (level < 0) {
80
+ return -1;
81
+ } else if (level > 0) {
82
+ return 1;
83
+ } else {
84
+ return 0;
85
+ }
86
+ }
87
+
88
+ this.getNextLineIndent = function(state, line, tab) {
89
+ var indent = this.$getIndent(line);
90
+ var level = 0;
91
+
92
+ var tokenizedLine = this.$tokenizer.getLineTokens(line, state);
93
+ var tokens = tokenizedLine.tokens;
94
+
95
+ if (state == "start") {
96
+ level = getNetIndentLevel(tokens);
97
+ }
98
+ if (level > 0) {
99
+ return indent + tab;
100
+ } else if (level < 0 && indent.substr(indent.length - tab.length) == tab) {
101
+ if (!this.checkOutdent(state, line, "\n")) {
102
+ return indent.substr(0, indent.length - tab.length);
103
+ }
104
+ }
105
+ return indent;
106
+ };
107
+
108
+ this.checkOutdent = function(state, line, input) {
109
+ if (input != "\n" && input != "\r" && input != "\r\n")
110
+ return false;
111
+
112
+ if (line.match(/^\s*[\)\}\]]$/))
113
+ return true;
114
+
115
+ var tokens = this.$tokenizer.getLineTokens(line.trim(), state).tokens;
116
+
117
+ if (!tokens || !tokens.length)
118
+ return false;
119
+
120
+ return (tokens[0].type == "keyword" && outdentKeywords.indexOf(tokens[0].value) != -1);
121
+ };
122
+
123
+ this.autoOutdent = function(state, session, row) {
124
+ var prevLine = session.getLine(row - 1);
125
+ var prevIndent = this.$getIndent(prevLine).length;
126
+ var prevTokens = this.$tokenizer.getLineTokens(prevLine, "start").tokens;
127
+ var tabLength = session.getTabString().length;
128
+ var expectedIndent = prevIndent + tabLength * getNetIndentLevel(prevTokens);
129
+ var curIndent = this.$getIndent(session.getLine(row)).length;
130
+ if (curIndent < expectedIndent) {
131
+ return;
132
+ }
133
+ session.outdentRows(new Range(row, 0, row + 2, 0));
134
+ };
135
+
136
+ }).call(Mode.prototype);
137
+
138
+ exports.Mode = Mode;
139
+ });
140
+
141
+ define('ace/mode/lua_highlight_rules', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text_highlight_rules'], function(require, exports, module) {
142
+
143
+
144
+ var oop = require("../lib/oop");
145
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
146
+
147
+ var LuaHighlightRules = function() {
148
+
149
+ var keywords = (
150
+ "break|do|else|elseif|end|for|function|if|in|local|repeat|"+
151
+ "return|then|until|while|or|and|not"
152
+ );
153
+
154
+ var builtinConstants = ("true|false|nil|_G|_VERSION");
155
+
156
+ var functions = (
157
+ "string|xpcall|package|tostring|print|os|unpack|require|"+
158
+ "getfenv|setmetatable|next|assert|tonumber|io|rawequal|"+
159
+ "collectgarbage|getmetatable|module|rawset|math|debug|"+
160
+ "pcall|table|newproxy|type|coroutine|_G|select|gcinfo|"+
161
+ "pairs|rawget|loadstring|ipairs|_VERSION|dofile|setfenv|"+
162
+ "load|error|loadfile|"+
163
+
164
+ "sub|upper|len|gfind|rep|find|match|char|dump|gmatch|"+
165
+ "reverse|byte|format|gsub|lower|preload|loadlib|loaded|"+
166
+ "loaders|cpath|config|path|seeall|exit|setlocale|date|"+
167
+ "getenv|difftime|remove|time|clock|tmpname|rename|execute|"+
168
+ "lines|write|close|flush|open|output|type|read|stderr|"+
169
+ "stdin|input|stdout|popen|tmpfile|log|max|acos|huge|"+
170
+ "ldexp|pi|cos|tanh|pow|deg|tan|cosh|sinh|random|randomseed|"+
171
+ "frexp|ceil|floor|rad|abs|sqrt|modf|asin|min|mod|fmod|log10|"+
172
+ "atan2|exp|sin|atan|getupvalue|debug|sethook|getmetatable|"+
173
+ "gethook|setmetatable|setlocal|traceback|setfenv|getinfo|"+
174
+ "setupvalue|getlocal|getregistry|getfenv|setn|insert|getn|"+
175
+ "foreachi|maxn|foreach|concat|sort|remove|resume|yield|"+
176
+ "status|wrap|create|running|"+
177
+ "__add|__sub|__mod|__unm|__concat|__lt|__index|__call|__gc|__metatable|"+
178
+ "__mul|__div|__pow|__len|__eq|__le|__newindex|__tostring|__mode|__tonumber"
179
+ );
180
+
181
+ var stdLibaries = ("string|package|os|io|math|debug|table|coroutine");
182
+
183
+ var futureReserved = "";
184
+
185
+ var deprecatedIn5152 = ("setn|foreach|foreachi|gcinfo|log10|maxn");
186
+
187
+ var keywordMapper = this.createKeywordMapper({
188
+ "keyword": keywords,
189
+ "support.function": functions,
190
+ "invalid.deprecated": deprecatedIn5152,
191
+ "constant.library": stdLibaries,
192
+ "constant.language": builtinConstants,
193
+ "invalid.illegal": futureReserved,
194
+ "variable.language": "this"
195
+ }, "identifier");
196
+
197
+ var strPre = "";
198
+
199
+ var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
200
+ var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
201
+ var integer = "(?:" + decimalInteger + "|" + hexInteger + ")";
202
+
203
+ var fraction = "(?:\\.\\d+)";
204
+ var intPart = "(?:\\d+)";
205
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
206
+ var floatNumber = "(?:" + pointFloat + ")";
207
+
208
+ var comment_stack = [];
209
+
210
+ this.$rules = {
211
+ "start" :
212
+ [{
213
+ token : "comment", // --[[ comment
214
+ regex : strPre + '\\-\\-\\[\\[.*\\]\\]'
215
+ }, {
216
+ token : "comment", // --[=[ comment
217
+ regex : strPre + '\\-\\-\\[\\=\\[.*\\]\\=\\]'
218
+ }, {
219
+ token : "comment", // --[==[ comment
220
+ regex : strPre + '\\-\\-\\[\\={2}\\[.*\\]\\={2}\\]'
221
+ }, {
222
+ token : "comment", // --[===[ comment
223
+ regex : strPre + '\\-\\-\\[\\={3}\\[.*\\]\\={3}\\]'
224
+ }, {
225
+ token : "comment", // --[====[ comment
226
+ regex : strPre + '\\-\\-\\[\\={4}\\[.*\\]\\={4}\\]'
227
+ }, {
228
+ token : "comment", // --[====+[ comment
229
+ regex : strPre + '\\-\\-\\[\\={5}\\=*\\[.*\\]\\={5}\\=*\\]'
230
+ },
231
+ {
232
+ token : "comment", // --[[ comment
233
+ regex : strPre + '\\-\\-\\[\\[.*$',
234
+ next : "qcomment"
235
+ }, {
236
+ token : "comment", // --[=[ comment
237
+ regex : strPre + '\\-\\-\\[\\=\\[.*$',
238
+ next : "qcomment1"
239
+ }, {
240
+ token : "comment", // --[==[ comment
241
+ regex : strPre + '\\-\\-\\[\\={2}\\[.*$',
242
+ next : "qcomment2"
243
+ }, {
244
+ token : "comment", // --[===[ comment
245
+ regex : strPre + '\\-\\-\\[\\={3}\\[.*$',
246
+ next : "qcomment3"
247
+ }, {
248
+ token : "comment", // --[====[ comment
249
+ regex : strPre + '\\-\\-\\[\\={4}\\[.*$',
250
+ next : "qcomment4"
251
+ }, {
252
+ token : function(value){ // --[====+[ comment
253
+ var pattern = /\-\-\[(\=+)\[/, match;
254
+ if ((match = pattern.exec(value)) != null && (match = match[1]) != undefined)
255
+ comment_stack.push(match.length);
256
+
257
+ return "comment";
258
+ },
259
+ regex : strPre + '\\-\\-\\[\\={5}\\=*\\[.*$',
260
+ next : "qcomment5"
261
+ },
262
+ {
263
+ token : "comment",
264
+ regex : "\\-\\-.*$"
265
+ },
266
+ {
267
+ token : "string", // [[ string
268
+ regex : strPre + '\\[\\[.*\\]\\]'
269
+ }, {
270
+ token : "string", // [=[ string
271
+ regex : strPre + '\\[\\=\\[.*\\]\\=\\]'
272
+ }, {
273
+ token : "string", // [==[ string
274
+ regex : strPre + '\\[\\={2}\\[.*\\]\\={2}\\]'
275
+ }, {
276
+ token : "string", // [===[ string
277
+ regex : strPre + '\\[\\={3}\\[.*\\]\\={3}\\]'
278
+ }, {
279
+ token : "string", // [====[ string
280
+ regex : strPre + '\\[\\={4}\\[.*\\]\\={4}\\]'
281
+ }, {
282
+ token : "string", // [====+[ string
283
+ regex : strPre + '\\[\\={5}\\=*\\[.*\\]\\={5}\\=*\\]'
284
+ },
285
+ {
286
+ token : "string", // [[ string
287
+ regex : strPre + '\\[\\[.*$',
288
+ next : "qstring"
289
+ }, {
290
+ token : "string", // [=[ string
291
+ regex : strPre + '\\[\\=\\[.*$',
292
+ next : "qstring1"
293
+ }, {
294
+ token : "string", // [==[ string
295
+ regex : strPre + '\\[\\={2}\\[.*$',
296
+ next : "qstring2"
297
+ }, {
298
+ token : "string", // [===[ string
299
+ regex : strPre + '\\[\\={3}\\[.*$',
300
+ next : "qstring3"
301
+ }, {
302
+ token : "string", // [====[ string
303
+ regex : strPre + '\\[\\={4}\\[.*$',
304
+ next : "qstring4"
305
+ }, {
306
+ token : function(value){ // --[====+[ string
307
+ var pattern = /\[(\=+)\[/, match;
308
+ if ((match = pattern.exec(value)) != null && (match = match[1]) != undefined)
309
+ comment_stack.push(match.length);
310
+
311
+ return "string";
312
+ },
313
+ regex : strPre + '\\[\\={5}\\=*\\[.*$',
314
+ next : "qstring5"
315
+ },
316
+
317
+ {
318
+ token : "string", // " string
319
+ regex : strPre + '"(?:[^\\\\]|\\\\.)*?"'
320
+ }, {
321
+ token : "string", // ' string
322
+ regex : strPre + "'(?:[^\\\\]|\\\\.)*?'"
323
+ }, {
324
+ token : "constant.numeric", // float
325
+ regex : floatNumber
326
+ }, {
327
+ token : "constant.numeric", // integer
328
+ regex : integer + "\\b"
329
+ }, {
330
+ token : keywordMapper,
331
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
332
+ }, {
333
+ token : "keyword.operator",
334
+ regex : "\\+|\\-|\\*|\\/|%|\\#|\\^|~|<|>|<=|=>|==|~=|=|\\:|\\.\\.\\.|\\.\\."
335
+ }, {
336
+ token : "paren.lparen",
337
+ regex : "[\\[\\(\\{]"
338
+ }, {
339
+ token : "paren.rparen",
340
+ regex : "[\\]\\)\\}]"
341
+ }, {
342
+ token : "text",
343
+ regex : "\\s+"
344
+ } ],
345
+
346
+ "qcomment": [ {
347
+ token : "comment",
348
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\]",
349
+ next : "start"
350
+ }, {
351
+ token : "comment",
352
+ regex : '.+'
353
+ } ],
354
+ "qcomment1": [ {
355
+ token : "comment",
356
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\=\\]",
357
+ next : "start"
358
+ }, {
359
+ token : "comment",
360
+ regex : '.+'
361
+ } ],
362
+ "qcomment2": [ {
363
+ token : "comment",
364
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\={2}\\]",
365
+ next : "start"
366
+ }, {
367
+ token : "comment",
368
+ regex : '.+'
369
+ } ],
370
+ "qcomment3": [ {
371
+ token : "comment",
372
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\={3}\\]",
373
+ next : "start"
374
+ }, {
375
+ token : "comment",
376
+ regex : '.+'
377
+ } ],
378
+ "qcomment4": [ {
379
+ token : "comment",
380
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\={4}\\]",
381
+ next : "start"
382
+ }, {
383
+ token : "comment",
384
+ regex : '.+'
385
+ } ],
386
+ "qcomment5": [ {
387
+ token : function(value){
388
+ var pattern = /\](\=+)\]/, rule = this.rules.qcomment5[0], match;
389
+ rule.next = "start";
390
+ if ((match = pattern.exec(value)) != null && (match = match[1]) != undefined){
391
+ var found = match.length, expected;
392
+ if ((expected = comment_stack.pop()) != found){
393
+ comment_stack.push(expected);
394
+ rule.next = "qcomment5";
395
+ }
396
+ }
397
+
398
+ return "comment";
399
+ },
400
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\={5}\\=*\\]",
401
+ next : "start"
402
+ }, {
403
+ token : "comment",
404
+ regex : '.+'
405
+ } ],
406
+
407
+ "qstring": [ {
408
+ token : "string",
409
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\]",
410
+ next : "start"
411
+ }, {
412
+ token : "string",
413
+ regex : '.+'
414
+ } ],
415
+ "qstring1": [ {
416
+ token : "string",
417
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\=\\]",
418
+ next : "start"
419
+ }, {
420
+ token : "string",
421
+ regex : '.+'
422
+ } ],
423
+ "qstring2": [ {
424
+ token : "string",
425
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\={2}\\]",
426
+ next : "start"
427
+ }, {
428
+ token : "string",
429
+ regex : '.+'
430
+ } ],
431
+ "qstring3": [ {
432
+ token : "string",
433
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\={3}\\]",
434
+ next : "start"
435
+ }, {
436
+ token : "string",
437
+ regex : '.+'
438
+ } ],
439
+ "qstring4": [ {
440
+ token : "string",
441
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\={4}\\]",
442
+ next : "start"
443
+ }, {
444
+ token : "string",
445
+ regex : '.+'
446
+ } ],
447
+ "qstring5": [ {
448
+ token : function(value){
449
+ var pattern = /\](\=+)\]/, rule = this.rules.qstring5[0], match;
450
+ rule.next = "start";
451
+ if ((match = pattern.exec(value)) != null && (match = match[1]) != undefined){
452
+ var found = match.length, expected;
453
+ if ((expected = comment_stack.pop()) != found){
454
+ comment_stack.push(expected);
455
+ rule.next = "qstring5";
456
+ }
457
+ }
458
+
459
+ return "string";
460
+ },
461
+ regex : "(?:[^\\\\]|\\\\.)*?\\]\\={5}\\=*\\]",
462
+ next : "start"
463
+ }, {
464
+ token : "string",
465
+ regex : '.+'
466
+ } ]
467
+
468
+ };
469
+
470
+ }
471
+
472
+ oop.inherits(LuaHighlightRules, TextHighlightRules);
473
+
474
+ exports.LuaHighlightRules = LuaHighlightRules;
475
+ });
476
+
477
+ define('ace/mode/folding/lua', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/folding/fold_mode', 'ace/range', 'ace/token_iterator'], function(require, exports, module) {
478
+
479
+
480
+ var oop = require("../../lib/oop");
481
+ var BaseFoldMode = require("./fold_mode").FoldMode;
482
+ var Range = require("../../range").Range;
483
+ var TokenIterator = require("../../token_iterator").TokenIterator;
484
+
485
+
486
+ var FoldMode = exports.FoldMode = function() {};
487
+
488
+ oop.inherits(FoldMode, BaseFoldMode);
489
+
490
+ (function() {
491
+
492
+ this.foldingStartMarker = /\b(function|then|do|repeat)\b|{\s*$|(\[=*\[)/;
493
+ this.foldingStopMarker = /\bend\b|^\s*}|\]=*\]/;
494
+
495
+ this.getFoldWidget = function(session, foldStyle, row) {
496
+ var line = session.getLine(row);
497
+ var isStart = this.foldingStartMarker.test(line);
498
+ var isEnd = this.foldingStopMarker.test(line);
499
+
500
+ if (isStart && !isEnd) {
501
+ var match = line.match(this.foldingStartMarker);
502
+ if (match[1] == "then" && /\belseif\b/.test(line))
503
+ return;
504
+ if (match[1]) {
505
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
506
+ return "start";
507
+ } else if (match[2]) {
508
+ var type = session.bgTokenizer.getState(row) || "";
509
+ if (type.indexOf("comment") != -1 || type.indexOf("string") != -1)
510
+ return "start";
511
+ } else {
512
+ return "start";
513
+ }
514
+ }
515
+ if (foldStyle != "markbeginend" || !isEnd || isStart && isEnd)
516
+ return "";
517
+
518
+ var match = line.match(this.foldingStopMarker);
519
+ if (match[0] === "end") {
520
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
521
+ return "end";
522
+ } else if (match[0][0] === "]") {
523
+ var type = session.bgTokenizer.getState(row - 1) || "";
524
+ if (type.indexOf("comment") != -1 || type.indexOf("string") != -1)
525
+ return "end";
526
+ } else
527
+ return "end";
528
+ };
529
+
530
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
531
+ var line = session.doc.getLine(row);
532
+ var match = this.foldingStartMarker.exec(line);
533
+ if (match) {
534
+ if (match[1])
535
+ return this.luaBlock(session, row, match.index + 1);
536
+
537
+ if (match[2])
538
+ return session.getCommentFoldRange(row, match.index + 1);
539
+
540
+ return this.openingBracketBlock(session, "{", row, match.index);
541
+ }
542
+
543
+ var match = this.foldingStopMarker.exec(line);
544
+ if (match) {
545
+ if (match[0] === "end") {
546
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
547
+ return this.luaBlock(session, row, match.index + 1);
548
+ }
549
+
550
+ if (match[0][0] === "]")
551
+ return session.getCommentFoldRange(row, match.index + 1);
552
+
553
+ return this.closingBracketBlock(session, "}", row, match.index + match[0].length);
554
+ }
555
+ };
556
+
557
+ this.luaBlock = function(session, row, column) {
558
+ var stream = new TokenIterator(session, row, column);
559
+ var indentKeywords = {
560
+ "function": 1,
561
+ "do": 1,
562
+ "then": 1,
563
+ "elseif": -1,
564
+ "end": -1,
565
+ "repeat": 1,
566
+ "until": -1,
567
+ };
568
+
569
+ var token = stream.getCurrentToken();
570
+ if (!token || token.type != "keyword")
571
+ return;
572
+
573
+ var val = token.value;
574
+ var stack = [val];
575
+ var dir = indentKeywords[val];
576
+
577
+ if (!dir)
578
+ return;
579
+
580
+ var startColumn = dir === -1 ? stream.getCurrentTokenColumn() : session.getLine(row).length;
581
+ var startRow = row;
582
+
583
+ stream.step = dir === -1 ? stream.stepBackward : stream.stepForward;
584
+ while(token = stream.step()) {
585
+ if (token.type !== "keyword")
586
+ continue;
587
+ var level = dir * indentKeywords[token.value];
588
+
589
+ if (level > 0) {
590
+ stack.unshift(token.value);
591
+ } else if (level <= 0) {
592
+ stack.shift();
593
+ if (!stack.length && token.value != "elseif")
594
+ break;
595
+ if (level === 0)
596
+ stack.unshift(token.value);
597
+ }
598
+ }
599
+
600
+ var row = stream.getCurrentTokenRow();
601
+ if (dir === -1)
602
+ return new Range(row, session.getLine(row).length, startRow, startColumn);
603
+ else
604
+ return new Range(startRow, startColumn, row, stream.getCurrentTokenColumn());
605
+ };
606
+
607
+ }).call(FoldMode.prototype);
608
+
609
+ });