Conflicts:
	Makefile.dryice.js
	build/demo/kitchen-sink/kitchen-sink-uncompressed.js
	build/kitchen-sink.html
	build/src/ace-noconflict.js
	build/src/ace.js
	demo/kitchen-sink/demo.js
This commit is contained in:
William Candillon 2012-03-31 10:00:21 +02:00
commit bdb21ff646
437 changed files with 65145 additions and 31979 deletions

View file

@ -40,7 +40,7 @@
* @param module a name for the payload
* @param payload a function to call with (require, exports, module) params
*/
(function() {
var ACE_NAMESPACE = "__ace_shadowed__";
@ -49,9 +49,6 @@ var global = (function() {
return this;
})();
if (typeof requirejs !== "undefined")
return;
var _define = function(module, deps, payload) {
if (typeof module !== 'string') {
if (_define.original)
@ -68,7 +65,7 @@ var _define = function(module, deps, payload) {
if (!_define.modules)
_define.modules = {};
_define.modules[module] = payload;
};
@ -92,11 +89,11 @@ var _require = function(parentId, module, callback) {
var payload = lookup(parentId, module);
if (!payload && _require.original)
return _require.original.apply(window, arguments);
if (callback) {
callback();
}
return payload;
}
else {
@ -115,13 +112,13 @@ var normalizeModule = function(parentId, moduleName) {
if (moduleName.charAt(0) == ".") {
var base = parentId.split("/").slice(0, -1).join("/");
moduleName = base + "/" + moduleName;
while(moduleName.indexOf(".") !== -1 && previous != moduleName) {
var previous = moduleName;
moduleName = moduleName.replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
}
}
return moduleName;
};
@ -141,19 +138,19 @@ var lookup = function(parentId, moduleName) {
if (typeof module === 'function') {
var exports = {};
var mod = {
id: moduleName,
id: moduleName,
uri: '',
exports: exports,
packaged: true
};
var req = function(module, callback) {
return _require(moduleName, module, callback);
};
var returnValue = module(req, exports, mod);
exports = returnValue || mod.exports;
// cache the resulting module object for next time
_define.modules[moduleName] = exports;
return exports;
@ -163,26 +160,45 @@ var lookup = function(parentId, moduleName) {
};
function exportAce(ns) {
if (typeof requirejs !== "undefined") {
var define = global.define;
global.define = function(id, deps, callback) {
if (typeof callback !== "function")
return define.apply(this, arguments);
return __ace_shadowed__.define(id, deps, function(require, exports, module) {
if (deps[2] == "module")
module.packaged = true;
return callback.apply(this, arguments);
});
};
global.define.packaged = true;
return;
}
var require = function(module, callback) {
return _require("", module, callback);
};
require.packaged = true;
var root = global;
if (ns) {
if (!global[ns])
global[ns] = {};
root = global[ns];
}
if (root.define)
_define.original = root.define;
root.define = _define;
if (root.require)
_require.original = root.require;
root.require = require;
}
@ -869,20 +885,9 @@ else {
}
exports.addMouseWheelListener = function(el, callback) {
var max = 0;
var factor = 8;
var listener = function(e) {
if (e.wheelDelta !== undefined) {
// some versions of Safari (e.g. 5.0.5) report insanely high
// scroll values. These browsers require a higher factor
if (Math.abs(e.wheelDeltaY) > max)
max = Math.abs(e.wheelDeltaY);
if (max > 5000)
var factor = 400;
else
var factor = 8;
if (e.wheelDeltaX !== undefined) {
e.wheelX = -e.wheelDeltaX / factor;
e.wheelY = -e.wheelDeltaY / factor;
@ -1446,7 +1451,7 @@ exports.hasCssString = function(id, doc) {
if (doc.createStyleSheet && (sheets = doc.styleSheets)) {
while (index < sheets.length)
if (sheets[index++].title === id) return true;
if (sheets[index++].owningElement.id === id) return true;
} else if ((sheets = doc.getElementsByTagName("style"))) {
while (index < sheets.length)
if (sheets[index++].id === id) return true;
@ -1467,7 +1472,7 @@ exports.importCssString = function importCssString(cssText, id, doc) {
style = doc.createStyleSheet();
style.cssText = cssText;
if (id)
style.title = id;
style.owningElement.id = id;
} else {
style = doc.createElementNS
? doc.createElementNS(XHTML_NS, "style")
@ -1613,8 +1618,7 @@ exports.getParentWindow = function(document) {
return document.defaultView || document.parentWindow;
};
});
/**
});/**
* based on code from:
*
* @license RequireJS text 0.25.0 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.
@ -1712,7 +1716,7 @@ exports.loadScript = function(path, callback) {
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.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/theme/textmate'], function(require, exports, module) {
__ace_shadowed__.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/config', 'ace/theme/textmate'], function(require, exports, module) {
"use strict";
require("./lib/fixoldbrowsers");
@ -1725,6 +1729,9 @@ var EditSession = require("./edit_session").EditSession;
var UndoManager = require("./undomanager").UndoManager;
var Renderer = require("./virtual_renderer").VirtualRenderer;
require("./worker/worker_client");
require("./config").init();
exports.edit = function(el) {
if (typeof(el) == "string") {
el = document.getElementById(el);
@ -1813,7 +1820,7 @@ __ace_shadowed__.define('ace/lib/regexp', ['require', 'exports', 'module' ], fun
RegExp.prototype.exec = function (str) {
var match = real.exec.apply(this, arguments),
name, r2;
if (match) {
if ( typeof(str) == 'string' && match) {
// Fix browsers whose `exec` methods don't consistently return `undefined` for
// nonparticipating capturing groups
if (!compliantExecNpcg && match.length > 1 && indexOf(match, "") > -1) {
@ -1878,7 +1885,8 @@ __ace_shadowed__.define('ace/lib/regexp', ['require', 'exports', 'module' ], fun
return -1;
};
});// vim: ts=4 sts=4 sw=4 expandtab
});
// vim: ts=4 sts=4 sw=4 expandtab
// -- kriskowal Kris Kowal Copyright (C) 2009-2011 MIT License
// -- tlrobinson Tom Robinson Copyright (C) 2009-2010 MIT License (Narwhal Project)
// -- dantman Daniel Friesen Copyright (C) 2010 XXX TODO License or CLA
@ -6057,11 +6065,13 @@ exports.commands = [{
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/edit_session', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/lang', 'ace/lib/event_emitter', 'ace/selection', 'ace/mode/text', 'ace/range', 'ace/document', 'ace/background_tokenizer', 'ace/edit_session/folding', 'ace/edit_session/bracket_match'], function(require, exports, module) {
__ace_shadowed__.define('ace/edit_session', ['require', 'exports', 'module' , 'ace/config', 'ace/lib/oop', 'ace/lib/lang', 'ace/lib/net', 'ace/lib/event_emitter', 'ace/selection', 'ace/mode/text', 'ace/range', 'ace/document', 'ace/background_tokenizer', 'ace/edit_session/folding', 'ace/edit_session/bracket_match'], function(require, exports, module) {
"use strict";
var config = require("./config");
var oop = require("./lib/oop");
var lang = require("./lib/lang");
var net = require("./lib/net");
var EventEmitter = require("./lib/event_emitter").EventEmitter;
var Selection = require("./selection").Selection;
var TextMode = require("./mode/text").Mode;
@ -6503,10 +6513,61 @@ var EditSession = function(text, mode) {
this._emit("tokenizerUpdate", e);
};
this.$modes = {};
this._loadMode = function(mode, callback) {
if (this.$modes[mode])
return callback(this.$modes[mode]);
var _self = this;
var module;
try {
module = require(mode);
} catch (e) {};
if (module)
return done(module);
fetch(function() {
require([mode], done);
});
function done(module) {
if (_self.$modes[mode])
return callback(_self.$modes[mode]);
_self.$modes[mode] = new module.Mode();
callback(_self.$modes[mode]);
}
function fetch(callback) {
if (!config.get("packaged"))
return callback();
var base = mode.split("/").pop();
var filename = config.get("modePath") + "/mode-" + base + config.get("suffix");
net.loadScript(filename, callback);
}
};
this.$mode = null;
this.$origMode = null;
this.setMode = function(mode) {
this.$origMode = mode;
// load on demand
if (typeof mode === "string") {
var _self = this;
this._loadMode(mode, function(module) {
if (_self.$origMode !== mode)
return;
_self.setMode(module);
});
return;
}
if (this.$mode === mode) return;
this.$mode = mode;
this.$stopWorker();
@ -7732,7 +7793,134 @@ require("./edit_session/bracket_match").BracketMatch.call(EditSession.prototype)
exports.EditSession = EditSession;
});
/* ***** BEGIN LICENSE BLOCK *****
/* vim:ts=4:sts=4:sw=4:
* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/config', ['require', 'exports', 'module' , 'ace/lib/lang'], function(require, exports, module) {
"no use strict";
var lang = require("./lib/lang");
var global = (function() {
return this;
})();
var options = {
packaged: false,
workerPath: "",
modePath: "",
themePath: "",
suffix: ".js"
};
exports.get = function(key) {
if (!options.hasOwnProperty(key))
throw new Error("Unknown confik key: " + key);
return options[key];
};
exports.set = function(key, value) {
if (!options.hasOwnProperty(key))
throw new Error("Unknown confik key: " + key);
options[key] = value;
};
exports.all = function() {
return lang.copyObject(options);
};
exports.init = function() {
options.packaged = require.packaged || module.packaged || (global.define && define.packaged);
if (!global.document)
return "";
var scriptOptions = {};
var scriptUrl = "";
var suffix;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var attributes = script.attributes;
for (var j=0, l=attributes.length; j < l; j++) {
var attr = attributes[j];
if (attr.name.indexOf("data-ace-") === 0) {
scriptOptions[deHyphenate(attr.name.replace(/^data-ace-/, ""))] = attr.value;
}
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace((-uncompressed)?(-noconflict)?\.js))(?:\?|$)/);
if (m) {
scriptUrl = m[1] || m[2];
suffix = m[3];
}
}
if (scriptUrl) {
scriptOptions.base = scriptOptions.base || scriptUrl;
scriptOptions.packaged = true;
}
scriptOptions.suffix = scriptOptions.suffix || suffix;
scriptOptions.workerPath = scriptOptions.workerPath || scriptOptions.base;
scriptOptions.modePath = scriptOptions.modePath || scriptOptions.base;
scriptOptions.themePath = scriptOptions.themePath || scriptOptions.base;
delete scriptOptions.base;
for (var key in scriptOptions)
if (typeof scriptOptions[key] !== "undefined")
exports.set(key, scriptOptions[key]);
};
function deHyphenate(str) {
return str.replace(/-(.)/g, function(m, m1) { return m1.toUpperCase(); });
}
});/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
@ -9437,7 +9625,7 @@ var Document = function(text) {
};
this.insert = function(position, text) {
if (text.length == 0)
if (!text || text.length === 0)
return position;
position = this.$clipPosition(position);
@ -12156,13 +12344,15 @@ exports.UndoManager = UndoManager;
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/virtual_renderer', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/dom', 'ace/lib/event', 'ace/lib/useragent', 'ace/layer/gutter', 'ace/layer/marker', 'ace/layer/text', 'ace/layer/cursor', 'ace/scrollbar', 'ace/renderloop', 'ace/lib/event_emitter', 'text!ace/css/editor.css'], function(require, exports, module) {
__ace_shadowed__.define('ace/virtual_renderer', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/dom', 'ace/lib/event', 'ace/lib/useragent', 'ace/config', 'ace/lib/net', 'ace/layer/gutter', 'ace/layer/marker', 'ace/layer/text', 'ace/layer/cursor', 'ace/scrollbar', 'ace/renderloop', 'ace/lib/event_emitter', 'text!ace/css/editor.css'], function(require, exports, module) {
"use strict";
var oop = require("./lib/oop");
var dom = require("./lib/dom");
var event = require("./lib/event");
var useragent = require("./lib/useragent");
var config = require("./config");
var net = require("./lib/net");
var GutterLayer = require("./layer/gutter").Gutter;
var MarkerLayer = require("./layer/marker").Marker;
var TextLayer = require("./layer/text").Text;
@ -12921,14 +13111,36 @@ var VirtualRenderer = function(container, theme) {
style.left = "-10000px";
};
this._loadTheme = function(name, callback) {
if (!config.get("packaged"))
return callback();
var base = name.split("/").pop();
var filename = config.get("themePath") + "/theme-" + base + config.get("suffix");
net.loadScript(filename, callback);
};
this.setTheme = function(theme) {
var _self = this;
this.$themeValue = theme;
if (!theme || typeof theme == "string") {
theme = theme || "ace/theme/textmate";
require([theme], function(theme) {
afterLoad(theme);
var moduleName = theme || "ace/theme/textmate";
var module;
try {
module = require(moduleName);
} catch (e) {};
if (module)
return afterLoad(module);
_self._loadTheme(moduleName, function() {
require([theme], function(module) {
if (_self.$themeValue !== theme)
return;
afterLoad(module);
});
});
} else {
afterLoad(theme);
@ -14600,6 +14812,172 @@ __ace_shadowed__.define("text!ace/css/editor.css", [], "@import url(//fonts.goog
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter', 'ace/config'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var config = require("../config");
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (config.get("packaged")) {
this.$worker = new Worker(config.get("workerPath") + "/" + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+/, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/textmate', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
"use strict";
@ -14644,6 +15022,7 @@ exports.cssText = ".ace-tm .ace_editor {\
color: rgb(191, 191, 191);\
}\
\
.ace-tm .ace_line .ace_storage,\
.ace-tm .ace_line .ace_keyword {\
color: blue;\
}\

View file

@ -916,13 +916,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -420,13 +420,3 @@ var MatchingParensOutdent = function() {};
exports.MatchingParensOutdent = MatchingParensOutdent;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -603,202 +603,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -1334,6 +1334,14 @@ var JavaScriptHighlightRules = function() {
+ unicode.packages.Mn + unicode.packages.Mc
+ unicode.packages.Nd
+ unicode.packages.Pc + "\\$_]*\\b";
var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
"u[0-9a-fA-F]{4}|" + // unicode
"[0-2][0-7]{0,2}|" + // oct
"3[0-6][0-7]?|" + // oct
"37[0-7]?|" + // oct
"[4-7][0-7]?|" + //oct
".)";
// regexp must not have capturing parentheses. Use (?:) instead.
// regexps are ordered -> the first match is used
@ -1351,21 +1359,13 @@ var JavaScriptHighlightRules = function() {
regex : "\\/\\*",
next : "comment"
}, {
token : "string", // single line
regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
token : "string",
regex : "'",
next : "qstring"
}, {
token : "string", // multi line string start
merge : true,
regex : '["].*\\\\$',
next : "qqstring"
}, {
token : "string", // single line
regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
}, {
token : "string", // multi line string start
merge : true,
regex : "['].*\\\\$",
next : "qstring"
token : "string",
regex : '"',
next : "qqstring"
}, {
token : "constant.numeric", // hex
regex : "0[xX][0-9a-fA-F]+\\b"
@ -1373,8 +1373,8 @@ var JavaScriptHighlightRules = function() {
token : "constant.numeric", // float
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
}, {
token : ["keyword.definition", "text", "entity.name.function"],
regex : "(function)(\\s+)(" + identifierRe + ")"
token : ["storage.type", "text", "entity.name.function", "text", "paren.lparen", "variable.parameter", "paren.rparen"],
regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()(.*?)(\\))"
}, {
token : "constant.language.boolean",
regex : "(?:true|false)\\b"
@ -1382,6 +1382,19 @@ var JavaScriptHighlightRules = function() {
token : "keyword",
regex : "(?:" + kwBeforeRe + ")\\b",
next : "regex_allowed"
}, {
token : "support.function",
regex : "\\b(?:s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\\b(?=\\()"
}, {
token : "support.function.dom",
regex : "\\b(?:s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName)|ById)|Attribute(?:Node)?)|blur)\\b(?=\\()"
}, {
token : "support.function.constant",
regex : "\\b(?:s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\\b"
}, {
token : ["punctuation.operator", "support.function.firebug"],
regex : "(\\.)(warn|info|log|error|time|timeEnd|assert)\\b"
}, {
token : function(value) {
if (globals.hasOwnProperty(value))
@ -1389,7 +1402,7 @@ var JavaScriptHighlightRules = function() {
else if (deprecated.hasOwnProperty(value))
return "invalid.deprecated";
else if (definitions.hasOwnProperty(value))
return "keyword.definition";
return "storage.type";
else if (keywords.hasOwnProperty(value))
return "keyword";
else if (buildinConstants.hasOwnProperty(value))
@ -1530,24 +1543,28 @@ var JavaScriptHighlightRules = function() {
],
"qqstring" : [
{
token : "string",
regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : '[^"\\\\]+'
}, {
token : "string",
regex : '"',
next : "start"
}
],
"qstring" : [
{
token : "string",
regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : "[^'\\\\]+"
}, {
token : "string",
regex : "'",
next : "start"
}
]
};
@ -1736,195 +1753,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
@ -2531,13 +2359,3 @@ oop.inherits(ColdfusionHighlightRules, TextHighlightRules);
exports.ColdfusionHighlightRules = ColdfusionHighlightRules;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -766,13 +766,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -454,195 +454,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
@ -851,13 +662,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -286,6 +286,14 @@ var JavaScriptHighlightRules = function() {
+ unicode.packages.Mn + unicode.packages.Mc
+ unicode.packages.Nd
+ unicode.packages.Pc + "\\$_]*\\b";
var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
"u[0-9a-fA-F]{4}|" + // unicode
"[0-2][0-7]{0,2}|" + // oct
"3[0-6][0-7]?|" + // oct
"37[0-7]?|" + // oct
"[4-7][0-7]?|" + //oct
".)";
// regexp must not have capturing parentheses. Use (?:) instead.
// regexps are ordered -> the first match is used
@ -303,21 +311,13 @@ var JavaScriptHighlightRules = function() {
regex : "\\/\\*",
next : "comment"
}, {
token : "string", // single line
regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
token : "string",
regex : "'",
next : "qstring"
}, {
token : "string", // multi line string start
merge : true,
regex : '["].*\\\\$',
next : "qqstring"
}, {
token : "string", // single line
regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
}, {
token : "string", // multi line string start
merge : true,
regex : "['].*\\\\$",
next : "qstring"
token : "string",
regex : '"',
next : "qqstring"
}, {
token : "constant.numeric", // hex
regex : "0[xX][0-9a-fA-F]+\\b"
@ -325,8 +325,8 @@ var JavaScriptHighlightRules = function() {
token : "constant.numeric", // float
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
}, {
token : ["keyword.definition", "text", "entity.name.function"],
regex : "(function)(\\s+)(" + identifierRe + ")"
token : ["storage.type", "text", "entity.name.function", "text", "paren.lparen", "variable.parameter", "paren.rparen"],
regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()(.*?)(\\))"
}, {
token : "constant.language.boolean",
regex : "(?:true|false)\\b"
@ -334,6 +334,19 @@ var JavaScriptHighlightRules = function() {
token : "keyword",
regex : "(?:" + kwBeforeRe + ")\\b",
next : "regex_allowed"
}, {
token : "support.function",
regex : "\\b(?:s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\\b(?=\\()"
}, {
token : "support.function.dom",
regex : "\\b(?:s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName)|ById)|Attribute(?:Node)?)|blur)\\b(?=\\()"
}, {
token : "support.function.constant",
regex : "\\b(?:s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\\b"
}, {
token : ["punctuation.operator", "support.function.firebug"],
regex : "(\\.)(warn|info|log|error|time|timeEnd|assert)\\b"
}, {
token : function(value) {
if (globals.hasOwnProperty(value))
@ -341,7 +354,7 @@ var JavaScriptHighlightRules = function() {
else if (deprecated.hasOwnProperty(value))
return "invalid.deprecated";
else if (definitions.hasOwnProperty(value))
return "keyword.definition";
return "storage.type";
else if (keywords.hasOwnProperty(value))
return "keyword";
else if (buildinConstants.hasOwnProperty(value))
@ -482,24 +495,28 @@ var JavaScriptHighlightRules = function() {
],
"qqstring" : [
{
token : "string",
regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : '[^"\\\\]+'
}, {
token : "string",
regex : '"',
next : "start"
}
],
"qstring" : [
{
token : "string",
regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : "[^'\\\\]+"
}, {
token : "string",
regex : "'",
next : "start"
}
]
};
@ -688,195 +705,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* vim:ts=4:sts=4:sw=4:
* ***** BEGIN LICENSE BLOCK *****
@ -1450,13 +1278,3 @@ oop.inherits(GroovyHighlightRules, TextHighlightRules);
exports.GroovyHighlightRules = GroovyHighlightRules;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -766,13 +766,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -345,6 +345,14 @@ var JavaScriptHighlightRules = function() {
+ unicode.packages.Mn + unicode.packages.Mc
+ unicode.packages.Nd
+ unicode.packages.Pc + "\\$_]*\\b";
var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
"u[0-9a-fA-F]{4}|" + // unicode
"[0-2][0-7]{0,2}|" + // oct
"3[0-6][0-7]?|" + // oct
"37[0-7]?|" + // oct
"[4-7][0-7]?|" + //oct
".)";
// regexp must not have capturing parentheses. Use (?:) instead.
// regexps are ordered -> the first match is used
@ -362,21 +370,13 @@ var JavaScriptHighlightRules = function() {
regex : "\\/\\*",
next : "comment"
}, {
token : "string", // single line
regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
token : "string",
regex : "'",
next : "qstring"
}, {
token : "string", // multi line string start
merge : true,
regex : '["].*\\\\$',
next : "qqstring"
}, {
token : "string", // single line
regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
}, {
token : "string", // multi line string start
merge : true,
regex : "['].*\\\\$",
next : "qstring"
token : "string",
regex : '"',
next : "qqstring"
}, {
token : "constant.numeric", // hex
regex : "0[xX][0-9a-fA-F]+\\b"
@ -384,8 +384,8 @@ var JavaScriptHighlightRules = function() {
token : "constant.numeric", // float
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
}, {
token : ["keyword.definition", "text", "entity.name.function"],
regex : "(function)(\\s+)(" + identifierRe + ")"
token : ["storage.type", "text", "entity.name.function", "text", "paren.lparen", "variable.parameter", "paren.rparen"],
regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()(.*?)(\\))"
}, {
token : "constant.language.boolean",
regex : "(?:true|false)\\b"
@ -393,6 +393,19 @@ var JavaScriptHighlightRules = function() {
token : "keyword",
regex : "(?:" + kwBeforeRe + ")\\b",
next : "regex_allowed"
}, {
token : "support.function",
regex : "\\b(?:s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\\b(?=\\()"
}, {
token : "support.function.dom",
regex : "\\b(?:s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName)|ById)|Attribute(?:Node)?)|blur)\\b(?=\\()"
}, {
token : "support.function.constant",
regex : "\\b(?:s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\\b"
}, {
token : ["punctuation.operator", "support.function.firebug"],
regex : "(\\.)(warn|info|log|error|time|timeEnd|assert)\\b"
}, {
token : function(value) {
if (globals.hasOwnProperty(value))
@ -400,7 +413,7 @@ var JavaScriptHighlightRules = function() {
else if (deprecated.hasOwnProperty(value))
return "invalid.deprecated";
else if (definitions.hasOwnProperty(value))
return "keyword.definition";
return "storage.type";
else if (keywords.hasOwnProperty(value))
return "keyword";
else if (buildinConstants.hasOwnProperty(value))
@ -541,24 +554,28 @@ var JavaScriptHighlightRules = function() {
],
"qqstring" : [
{
token : "string",
regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : '[^"\\\\]+'
}, {
token : "string",
regex : '"',
next : "start"
}
],
"qstring" : [
{
token : "string",
regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : "[^'\\\\]+"
}, {
token : "string",
regex : "'",
next : "start"
}
]
};
@ -747,195 +764,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* vim:ts=4:sts=4:sw=4:
* ***** BEGIN LICENSE BLOCK *****
@ -2546,13 +2374,4 @@ oop.inherits(FoldMode, BaseFoldMode);
}).call(FoldMode.prototype);
});;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();
});

View file

@ -287,6 +287,14 @@ var JavaScriptHighlightRules = function() {
+ unicode.packages.Mn + unicode.packages.Mc
+ unicode.packages.Nd
+ unicode.packages.Pc + "\\$_]*\\b";
var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
"u[0-9a-fA-F]{4}|" + // unicode
"[0-2][0-7]{0,2}|" + // oct
"3[0-6][0-7]?|" + // oct
"37[0-7]?|" + // oct
"[4-7][0-7]?|" + //oct
".)";
// regexp must not have capturing parentheses. Use (?:) instead.
// regexps are ordered -> the first match is used
@ -304,21 +312,13 @@ var JavaScriptHighlightRules = function() {
regex : "\\/\\*",
next : "comment"
}, {
token : "string", // single line
regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
token : "string",
regex : "'",
next : "qstring"
}, {
token : "string", // multi line string start
merge : true,
regex : '["].*\\\\$',
next : "qqstring"
}, {
token : "string", // single line
regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
}, {
token : "string", // multi line string start
merge : true,
regex : "['].*\\\\$",
next : "qstring"
token : "string",
regex : '"',
next : "qqstring"
}, {
token : "constant.numeric", // hex
regex : "0[xX][0-9a-fA-F]+\\b"
@ -326,8 +326,8 @@ var JavaScriptHighlightRules = function() {
token : "constant.numeric", // float
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
}, {
token : ["keyword.definition", "text", "entity.name.function"],
regex : "(function)(\\s+)(" + identifierRe + ")"
token : ["storage.type", "text", "entity.name.function", "text", "paren.lparen", "variable.parameter", "paren.rparen"],
regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()(.*?)(\\))"
}, {
token : "constant.language.boolean",
regex : "(?:true|false)\\b"
@ -335,6 +335,19 @@ var JavaScriptHighlightRules = function() {
token : "keyword",
regex : "(?:" + kwBeforeRe + ")\\b",
next : "regex_allowed"
}, {
token : "support.function",
regex : "\\b(?:s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\\b(?=\\()"
}, {
token : "support.function.dom",
regex : "\\b(?:s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName)|ById)|Attribute(?:Node)?)|blur)\\b(?=\\()"
}, {
token : "support.function.constant",
regex : "\\b(?:s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\\b"
}, {
token : ["punctuation.operator", "support.function.firebug"],
regex : "(\\.)(warn|info|log|error|time|timeEnd|assert)\\b"
}, {
token : function(value) {
if (globals.hasOwnProperty(value))
@ -342,7 +355,7 @@ var JavaScriptHighlightRules = function() {
else if (deprecated.hasOwnProperty(value))
return "invalid.deprecated";
else if (definitions.hasOwnProperty(value))
return "keyword.definition";
return "storage.type";
else if (keywords.hasOwnProperty(value))
return "keyword";
else if (buildinConstants.hasOwnProperty(value))
@ -483,24 +496,28 @@ var JavaScriptHighlightRules = function() {
],
"qqstring" : [
{
token : "string",
regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : '[^"\\\\]+'
}, {
token : "string",
regex : '"',
next : "start"
}
],
"qstring" : [
{
token : "string",
regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : "[^'\\\\]+"
}, {
token : "string",
regex : "'",
next : "start"
}
]
};
@ -689,195 +706,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* vim:ts=4:sts=4:sw=4:
* ***** BEGIN LICENSE BLOCK *****
@ -1452,13 +1280,3 @@ oop.inherits(JavaHighlightRules, TextHighlightRules);
exports.JavaHighlightRules = JavaHighlightRules;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -262,6 +262,14 @@ var JavaScriptHighlightRules = function() {
+ unicode.packages.Mn + unicode.packages.Mc
+ unicode.packages.Nd
+ unicode.packages.Pc + "\\$_]*\\b";
var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
"u[0-9a-fA-F]{4}|" + // unicode
"[0-2][0-7]{0,2}|" + // oct
"3[0-6][0-7]?|" + // oct
"37[0-7]?|" + // oct
"[4-7][0-7]?|" + //oct
".)";
// regexp must not have capturing parentheses. Use (?:) instead.
// regexps are ordered -> the first match is used
@ -279,21 +287,13 @@ var JavaScriptHighlightRules = function() {
regex : "\\/\\*",
next : "comment"
}, {
token : "string", // single line
regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
token : "string",
regex : "'",
next : "qstring"
}, {
token : "string", // multi line string start
merge : true,
regex : '["].*\\\\$',
next : "qqstring"
}, {
token : "string", // single line
regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
}, {
token : "string", // multi line string start
merge : true,
regex : "['].*\\\\$",
next : "qstring"
token : "string",
regex : '"',
next : "qqstring"
}, {
token : "constant.numeric", // hex
regex : "0[xX][0-9a-fA-F]+\\b"
@ -301,8 +301,8 @@ var JavaScriptHighlightRules = function() {
token : "constant.numeric", // float
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
}, {
token : ["keyword.definition", "text", "entity.name.function"],
regex : "(function)(\\s+)(" + identifierRe + ")"
token : ["storage.type", "text", "entity.name.function", "text", "paren.lparen", "variable.parameter", "paren.rparen"],
regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()(.*?)(\\))"
}, {
token : "constant.language.boolean",
regex : "(?:true|false)\\b"
@ -310,6 +310,19 @@ var JavaScriptHighlightRules = function() {
token : "keyword",
regex : "(?:" + kwBeforeRe + ")\\b",
next : "regex_allowed"
}, {
token : "support.function",
regex : "\\b(?:s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\\b(?=\\()"
}, {
token : "support.function.dom",
regex : "\\b(?:s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName)|ById)|Attribute(?:Node)?)|blur)\\b(?=\\()"
}, {
token : "support.function.constant",
regex : "\\b(?:s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\\b"
}, {
token : ["punctuation.operator", "support.function.firebug"],
regex : "(\\.)(warn|info|log|error|time|timeEnd|assert)\\b"
}, {
token : function(value) {
if (globals.hasOwnProperty(value))
@ -317,7 +330,7 @@ var JavaScriptHighlightRules = function() {
else if (deprecated.hasOwnProperty(value))
return "invalid.deprecated";
else if (definitions.hasOwnProperty(value))
return "keyword.definition";
return "storage.type";
else if (keywords.hasOwnProperty(value))
return "keyword";
else if (buildinConstants.hasOwnProperty(value))
@ -458,24 +471,28 @@ var JavaScriptHighlightRules = function() {
],
"qqstring" : [
{
token : "string",
regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : '[^"\\\\]+'
}, {
token : "string",
regex : '"',
next : "start"
}
],
"qstring" : [
{
token : "string",
regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : "[^'\\\\]+"
}, {
token : "string",
regex : "'",
next : "start"
}
]
};
@ -664,195 +681,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* vim:ts=4:sts=4:sw=4:
* ***** BEGIN LICENSE BLOCK *****
@ -1283,13 +1111,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/mode/json', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text', 'ace/tokenizer', 'ace/mode/json_highlight_rules', 'ace/mode/matching_brace_outdent', 'ace/mode/behaviour/cstyle', 'ace/mode/folding/cstyle'], function(require, exports, module) {
__ace_shadowed__.define('ace/mode/json', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text', 'ace/tokenizer', 'ace/mode/json_highlight_rules', 'ace/mode/matching_brace_outdent', 'ace/mode/behaviour/cstyle', 'ace/mode/folding/cstyle', 'ace/worker/worker_client'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
@ -45,6 +45,7 @@ var HighlightRules = require("./json_highlight_rules").JsonHighlightRules;
var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
var CStyleFoldMode = require("./folding/cstyle").FoldMode;
var WorkerClient = require("../worker/worker_client").WorkerClient;
var Mode = function() {
this.$tokenizer = new Tokenizer(new HighlightRules().getRules());
@ -76,7 +77,23 @@ oop.inherits(Mode, TextMode);
this.autoOutdent = function(state, doc, row) {
this.$outdent.autoOutdent(doc, row);
};
this.createWorker = function(session) {
var worker = new WorkerClient(["ace"], "worker-json.js", "ace/mode/json_worker", "JsonWorker");
worker.attachToDocument(session.getDocument());
worker.on("error", function(e) {
session.setAnnotations([e.data]);
});
worker.on("ok", function() {
session.clearAnnotations();
});
return worker;
};
}).call(Mode.prototype);
exports.Mode = Mode;
@ -677,13 +694,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -93,13 +93,3 @@ oop.inherits(LatexHighlightRules, TextHighlightRules);
exports.LatexHighlightRules = LatexHighlightRules;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -521,13 +521,3 @@ oop.inherits(LuaHighlightRules, TextHighlightRules);
exports.LuaHighlightRules = LuaHighlightRules;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -342,6 +342,14 @@ var JavaScriptHighlightRules = function() {
+ unicode.packages.Mn + unicode.packages.Mc
+ unicode.packages.Nd
+ unicode.packages.Pc + "\\$_]*\\b";
var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
"u[0-9a-fA-F]{4}|" + // unicode
"[0-2][0-7]{0,2}|" + // oct
"3[0-6][0-7]?|" + // oct
"37[0-7]?|" + // oct
"[4-7][0-7]?|" + //oct
".)";
// regexp must not have capturing parentheses. Use (?:) instead.
// regexps are ordered -> the first match is used
@ -359,21 +367,13 @@ var JavaScriptHighlightRules = function() {
regex : "\\/\\*",
next : "comment"
}, {
token : "string", // single line
regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
token : "string",
regex : "'",
next : "qstring"
}, {
token : "string", // multi line string start
merge : true,
regex : '["].*\\\\$',
next : "qqstring"
}, {
token : "string", // single line
regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
}, {
token : "string", // multi line string start
merge : true,
regex : "['].*\\\\$",
next : "qstring"
token : "string",
regex : '"',
next : "qqstring"
}, {
token : "constant.numeric", // hex
regex : "0[xX][0-9a-fA-F]+\\b"
@ -381,8 +381,8 @@ var JavaScriptHighlightRules = function() {
token : "constant.numeric", // float
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
}, {
token : ["keyword.definition", "text", "entity.name.function"],
regex : "(function)(\\s+)(" + identifierRe + ")"
token : ["storage.type", "text", "entity.name.function", "text", "paren.lparen", "variable.parameter", "paren.rparen"],
regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()(.*?)(\\))"
}, {
token : "constant.language.boolean",
regex : "(?:true|false)\\b"
@ -390,6 +390,19 @@ var JavaScriptHighlightRules = function() {
token : "keyword",
regex : "(?:" + kwBeforeRe + ")\\b",
next : "regex_allowed"
}, {
token : "support.function",
regex : "\\b(?:s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\\b(?=\\()"
}, {
token : "support.function.dom",
regex : "\\b(?:s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName)|ById)|Attribute(?:Node)?)|blur)\\b(?=\\()"
}, {
token : "support.function.constant",
regex : "\\b(?:s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\\b"
}, {
token : ["punctuation.operator", "support.function.firebug"],
regex : "(\\.)(warn|info|log|error|time|timeEnd|assert)\\b"
}, {
token : function(value) {
if (globals.hasOwnProperty(value))
@ -397,7 +410,7 @@ var JavaScriptHighlightRules = function() {
else if (deprecated.hasOwnProperty(value))
return "invalid.deprecated";
else if (definitions.hasOwnProperty(value))
return "keyword.definition";
return "storage.type";
else if (keywords.hasOwnProperty(value))
return "keyword";
else if (buildinConstants.hasOwnProperty(value))
@ -538,24 +551,28 @@ var JavaScriptHighlightRules = function() {
],
"qqstring" : [
{
token : "string",
regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : '[^"\\\\]+'
}, {
token : "string",
regex : '"',
next : "start"
}
],
"qstring" : [
{
token : "string",
regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : "[^'\\\\]+"
}, {
token : "string",
regex : "'",
next : "start"
}
]
};
@ -744,195 +761,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* vim:ts=4:sts=4:sw=4:
* ***** BEGIN LICENSE BLOCK *****
@ -2988,13 +2816,4 @@ var MarkdownHighlightRules = function() {
oop.inherits(MarkdownHighlightRules, TextHighlightRules);
exports.MarkdownHighlightRules = MarkdownHighlightRules;
});;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();
});

View file

@ -537,13 +537,3 @@ var MatchingBraceOutdent = function() {};
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -571,13 +571,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -1105,13 +1105,3 @@ oop.inherits(PythonHighlightRules, TextHighlightRules);
exports.PythonHighlightRules = PythonHighlightRules;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -1882,13 +1882,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -704,13 +704,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -504,13 +504,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -389,13 +389,3 @@ var MatchingBraceOutdent = function() {};
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -904,13 +904,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -287,6 +287,14 @@ var JavaScriptHighlightRules = function() {
+ unicode.packages.Mn + unicode.packages.Mc
+ unicode.packages.Nd
+ unicode.packages.Pc + "\\$_]*\\b";
var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
"u[0-9a-fA-F]{4}|" + // unicode
"[0-2][0-7]{0,2}|" + // oct
"3[0-6][0-7]?|" + // oct
"37[0-7]?|" + // oct
"[4-7][0-7]?|" + //oct
".)";
// regexp must not have capturing parentheses. Use (?:) instead.
// regexps are ordered -> the first match is used
@ -304,21 +312,13 @@ var JavaScriptHighlightRules = function() {
regex : "\\/\\*",
next : "comment"
}, {
token : "string", // single line
regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
token : "string",
regex : "'",
next : "qstring"
}, {
token : "string", // multi line string start
merge : true,
regex : '["].*\\\\$',
next : "qqstring"
}, {
token : "string", // single line
regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
}, {
token : "string", // multi line string start
merge : true,
regex : "['].*\\\\$",
next : "qstring"
token : "string",
regex : '"',
next : "qqstring"
}, {
token : "constant.numeric", // hex
regex : "0[xX][0-9a-fA-F]+\\b"
@ -326,8 +326,8 @@ var JavaScriptHighlightRules = function() {
token : "constant.numeric", // float
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
}, {
token : ["keyword.definition", "text", "entity.name.function"],
regex : "(function)(\\s+)(" + identifierRe + ")"
token : ["storage.type", "text", "entity.name.function", "text", "paren.lparen", "variable.parameter", "paren.rparen"],
regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()(.*?)(\\))"
}, {
token : "constant.language.boolean",
regex : "(?:true|false)\\b"
@ -335,6 +335,19 @@ var JavaScriptHighlightRules = function() {
token : "keyword",
regex : "(?:" + kwBeforeRe + ")\\b",
next : "regex_allowed"
}, {
token : "support.function",
regex : "\\b(?:s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\\b(?=\\()"
}, {
token : "support.function.dom",
regex : "\\b(?:s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName)|ById)|Attribute(?:Node)?)|blur)\\b(?=\\()"
}, {
token : "support.function.constant",
regex : "\\b(?:s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\\b"
}, {
token : ["punctuation.operator", "support.function.firebug"],
regex : "(\\.)(warn|info|log|error|time|timeEnd|assert)\\b"
}, {
token : function(value) {
if (globals.hasOwnProperty(value))
@ -342,7 +355,7 @@ var JavaScriptHighlightRules = function() {
else if (deprecated.hasOwnProperty(value))
return "invalid.deprecated";
else if (definitions.hasOwnProperty(value))
return "keyword.definition";
return "storage.type";
else if (keywords.hasOwnProperty(value))
return "keyword";
else if (buildinConstants.hasOwnProperty(value))
@ -483,24 +496,28 @@ var JavaScriptHighlightRules = function() {
],
"qqstring" : [
{
token : "string",
regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : '[^"\\\\]+'
}, {
token : "string",
regex : '"',
next : "start"
}
],
"qstring" : [
{
token : "string",
regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : "[^'\\\\]+"
}, {
token : "string",
regex : "'",
next : "start"
}
]
};
@ -689,195 +706,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* vim:ts=4:sts=4:sw=4:
* ***** BEGIN LICENSE BLOCK *****
@ -1452,13 +1280,3 @@ oop.inherits(ScalaHighlightRules, TextHighlightRules);
exports.ScalaHighlightRules = ScalaHighlightRules;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -676,13 +676,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -0,0 +1,268 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Rich Healey <richo AT psych0tik DOT net>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/mode/sh', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/mode/text', 'ace/tokenizer', 'ace/mode/sh_highlight_rules', 'ace/range'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var TextMode = require("./text").Mode;
var Tokenizer = require("../tokenizer").Tokenizer;
var ShHighlightRules = require("./sh_highlight_rules").ShHighlightRules;
var Range = require("../range").Range;
var Mode = function() {
this.$tokenizer = new Tokenizer(new ShHighlightRules().getRules());
};
oop.inherits(Mode, TextMode);
(function() {
this.toggleCommentLines = function(state, doc, startRow, endRow) {
var outdent = true;
var re = /^(\s*)#/;
for (var i=startRow; i<= endRow; i++) {
if (!re.test(doc.getLine(i))) {
outdent = false;
break;
}
}
if (outdent) {
var deleteRange = new Range(0, 0, 0, 0);
for (var i=startRow; i<= endRow; i++)
{
var line = doc.getLine(i);
var m = line.match(re);
deleteRange.start.row = i;
deleteRange.end.row = i;
deleteRange.end.column = m[0].length;
doc.replace(deleteRange, m[1]);
}
}
else {
doc.indentRows(startRow, endRow, "#");
}
};
this.getNextLineIndent = function(state, line, tab) {
var indent = this.$getIndent(line);
var tokenizedLine = this.$tokenizer.getLineTokens(line, state);
var tokens = tokenizedLine.tokens;
if (tokens.length && tokens[tokens.length-1].type == "comment") {
return indent;
}
if (state == "start") {
var match = line.match(/^.*[\{\(\[\:]\s*$/);
if (match) {
indent += tab;
}
}
return indent;
};
var outdents = {
"pass": 1,
"return": 1,
"raise": 1,
"break": 1,
"continue": 1
};
this.checkOutdent = function(state, line, input) {
if (input !== "\r\n" && input !== "\r" && input !== "\n")
return false;
var tokens = this.$tokenizer.getLineTokens(line.trim(), state).tokens;
if (!tokens)
return false;
// ignore trailing comments
do {
var last = tokens.pop();
} while (last && (last.type == "comment" || (last.type == "text" && last.value.match(/^\s+$/))));
if (!last)
return false;
return (last.type == "keyword" && outdents[last.value]);
};
this.autoOutdent = function(state, doc, row) {
// outdenting in sh is slightly different because it always applies
// to the next line and only of a new line is inserted
row += 1;
var indent = this.$getIndent(doc.getLine(row));
var tab = doc.getTabString();
if (indent.slice(-tab.length) == tab)
doc.remove(new Range(row, indent.length-tab.length, row, indent.length));
};
}).call(Mode.prototype);
exports.Mode = Mode;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Rich Healey <richo AT psych0tik DOT net>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK *****
*/
__ace_shadowed__.define('ace/mode/sh_highlight_rules', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/lang', 'ace/mode/text_highlight_rules'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var lang = require("../lib/lang");
var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
var ShHighlightRules = function() {
var reservedKeywords = lang.arrayToMap(
('!|{|}|case|do|done|elif|else|'+
'esac|fi|for|if|in|then|until|while|'+
'&|;'
).split('|')
);
var languageConstructs = lang.arrayToMap(
// TODO
('echo|exit|eval|source|[|]|test|'+
'true|false|read'
).split('|')
);
var builtinVariables = lang.arrayToMap(
// TODO
('$?|$$|$!|$SHLVL').split('|')
);
var integer = "(?:(?:[1-9]\\d*)|(?:0))";
// var integer = "(?:" + decimalInteger + ")";
var fraction = "(?:\\.\\d+)";
var intPart = "(?:\\d+)";
var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + ")";
var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
this.$rules = {
"start" : [ {
token : "comment",
regex : "#.*$"
}, {
token : "string", // " string
regex : '"(?:[^\\\\]|\\\\.)*?"'
}, {
token : "string", // ' string
regex : "'(?:[^\\\\]|\\\\.)*?'"
}, {
token : "constant.numeric", // float
regex : floatNumber
}, {
token : "constant.numeric", // integer
regex : integer + "\\b"
}, {
token : function(value) {
if (reservedKeywords.hasOwnProperty(value))
return "keyword";
else if (languageConstructs.hasOwnProperty(value))
return "constant.language";
else if (builtinVariables.hasOwnProperty(value))
return "support.function";
else if (value == "debugger")
return "invalid.deprecated";
else
return "identifier";
},
regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
}, {
token : "keyword.operator",
regex : "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|~|<|>|<=|=>|=|!="
}, {
token : "lparen.paren",
regex : "[\\[\\(\\{]"
}, {
token : "paren.rparen",
regex : "[\\]\\)\\}]"
}, {
token : "text",
regex : "\\s+"
} ]
};
};
oop.inherits(ShHighlightRules, TextHighlightRules);
exports.ShHighlightRules = ShHighlightRules;
});

View file

@ -157,13 +157,3 @@ oop.inherits(SqlHighlightRules, TextHighlightRules);
exports.SqlHighlightRules = SqlHighlightRules;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -1341,6 +1341,14 @@ var JavaScriptHighlightRules = function() {
+ unicode.packages.Mn + unicode.packages.Mc
+ unicode.packages.Nd
+ unicode.packages.Pc + "\\$_]*\\b";
var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
"u[0-9a-fA-F]{4}|" + // unicode
"[0-2][0-7]{0,2}|" + // oct
"3[0-6][0-7]?|" + // oct
"37[0-7]?|" + // oct
"[4-7][0-7]?|" + //oct
".)";
// regexp must not have capturing parentheses. Use (?:) instead.
// regexps are ordered -> the first match is used
@ -1358,21 +1366,13 @@ var JavaScriptHighlightRules = function() {
regex : "\\/\\*",
next : "comment"
}, {
token : "string", // single line
regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
token : "string",
regex : "'",
next : "qstring"
}, {
token : "string", // multi line string start
merge : true,
regex : '["].*\\\\$',
next : "qqstring"
}, {
token : "string", // single line
regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
}, {
token : "string", // multi line string start
merge : true,
regex : "['].*\\\\$",
next : "qstring"
token : "string",
regex : '"',
next : "qqstring"
}, {
token : "constant.numeric", // hex
regex : "0[xX][0-9a-fA-F]+\\b"
@ -1380,8 +1380,8 @@ var JavaScriptHighlightRules = function() {
token : "constant.numeric", // float
regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
}, {
token : ["keyword.definition", "text", "entity.name.function"],
regex : "(function)(\\s+)(" + identifierRe + ")"
token : ["storage.type", "text", "entity.name.function", "text", "paren.lparen", "variable.parameter", "paren.rparen"],
regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()(.*?)(\\))"
}, {
token : "constant.language.boolean",
regex : "(?:true|false)\\b"
@ -1389,6 +1389,19 @@ var JavaScriptHighlightRules = function() {
token : "keyword",
regex : "(?:" + kwBeforeRe + ")\\b",
next : "regex_allowed"
}, {
token : "support.function",
regex : "\\b(?:s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\\b(?=\\()"
}, {
token : "support.function.dom",
regex : "\\b(?:s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName)|ById)|Attribute(?:Node)?)|blur)\\b(?=\\()"
}, {
token : "support.function.constant",
regex : "\\b(?:s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\\b"
}, {
token : ["punctuation.operator", "support.function.firebug"],
regex : "(\\.)(warn|info|log|error|time|timeEnd|assert)\\b"
}, {
token : function(value) {
if (globals.hasOwnProperty(value))
@ -1396,7 +1409,7 @@ var JavaScriptHighlightRules = function() {
else if (deprecated.hasOwnProperty(value))
return "invalid.deprecated";
else if (definitions.hasOwnProperty(value))
return "keyword.definition";
return "storage.type";
else if (keywords.hasOwnProperty(value))
return "keyword";
else if (buildinConstants.hasOwnProperty(value))
@ -1537,24 +1550,28 @@ var JavaScriptHighlightRules = function() {
],
"qqstring" : [
{
token : "string",
regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : '[^"\\\\]+'
}, {
token : "string",
regex : '"',
next : "start"
}
],
"qstring" : [
{
token : "string",
regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
next : "start"
token : "constant.language.escape",
regex : escapedRe
}, {
token : "string",
merge : true,
regex : '.+'
regex : "[^'\\\\]+"
}, {
token : "string",
regex : "'",
next : "start"
}
]
};
@ -1743,195 +1760,6 @@ var MatchingBraceOutdent = function() {};
}).call(MatchingBraceOutdent.prototype);
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/worker/worker_client', ['require', 'exports', 'module' , 'ace/lib/oop', 'ace/lib/event_emitter'], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var EventEmitter = require("../lib/event_emitter").EventEmitter;
var WorkerClient = function(topLevelNamespaces, packagedJs, mod, classname) {
this.changeListener = this.changeListener.bind(this);
if (module.packaged) {
var base = this.$guessBasePath();
this.$worker = new Worker(base + packagedJs);
}
else {
var workerUrl = this.$normalizePath(require.nameToUrl("ace/worker/worker", null, "_"));
this.$worker = new Worker(workerUrl);
var tlns = {};
for (var i=0; i<topLevelNamespaces.length; i++) {
var ns = topLevelNamespaces[i];
var path = this.$normalizePath(require.nameToUrl(ns, null, "_").replace(/.js$/, ""));
tlns[ns] = path;
}
}
this.$worker.postMessage({
init : true,
tlns: tlns,
module: mod,
classname: classname
});
this.callbackId = 1;
this.callbacks = {};
var _self = this;
this.$worker.onerror = function(e) {
window.console && console.log && console.log(e);
throw e;
};
this.$worker.onmessage = function(e) {
var msg = e.data;
switch(msg.type) {
case "log":
window.console && console.log && console.log(msg.data);
break;
case "event":
_self._emit(msg.name, {data: msg.data});
break;
case "call":
var callback = _self.callbacks[msg.id];
if (callback) {
callback(msg.data);
delete _self.callbacks[msg.id];
}
break;
}
};
};
(function(){
oop.implement(this, EventEmitter);
this.$normalizePath = function(path) {
path = path.replace(/^[a-z]+:\/\/[^\/]+\//, ""); // Remove domain name and rebuild it
path = location.protocol + "//" + location.host
// paths starting with a slash are relative to the root (host)
+ (path.charAt(0) == "/" ? "" : location.pathname.replace(/\/[^\/]*$/, ""))
+ "/" + path.replace(/^[\/]+/, "");
return path;
};
this.$guessBasePath = function() {
if (require.aceBaseUrl)
return require.aceBaseUrl;
var scripts = document.getElementsByTagName("script");
for (var i=0; i<scripts.length; i++) {
var script = scripts[i];
var base = script.getAttribute("data-ace-base");
if (base)
return base.replace(/\/*$/, "/");
var src = script.src || script.getAttribute("src");
if (!src) {
continue;
}
var m = src.match(/^(?:(.*\/)ace\.js|(.*\/)ace(-uncompressed)?(-noconflict)?\.js)(?:\?|$)/);
if (m)
return m[1] || m[2];
}
return "";
};
this.terminate = function() {
this._emit("terminate", {});
this.$worker.terminate();
this.$worker = null;
this.$doc.removeEventListener("change", this.changeListener);
this.$doc = null;
};
this.send = function(cmd, args) {
this.$worker.postMessage({command: cmd, args: args});
};
this.call = function(cmd, args, callback) {
if (callback) {
var id = this.callbackId++;
this.callbacks[id] = callback;
args.push(id);
}
this.send(cmd, args);
};
this.emit = function(event, data) {
try {
// firefox refuses to clone objects which have function properties
// TODO: cleanup event
this.$worker.postMessage({event: event, data: {data: data.data}});
}
catch(ex) {}
};
this.attachToDocument = function(doc) {
if(this.$doc)
this.terminate();
this.$doc = doc;
this.call("setValue", [doc.getValue()]);
doc.on("change", this.changeListener);
};
this.changeListener = function(e) {
e.range = {
start: e.data.range.start,
end: e.data.range.end
};
this.emit("change", e);
};
}).call(WorkerClient.prototype);
exports.WorkerClient = WorkerClient;
});
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
@ -2185,13 +2013,4 @@ oop.inherits(FoldMode, BaseFoldMode);
}).call(FoldMode.prototype);
});;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();
});

View file

View file

@ -252,13 +252,3 @@ var MatchingBraceOutdent = function() {};
exports.MatchingBraceOutdent = MatchingBraceOutdent;
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -999,13 +999,3 @@ var FoldMode = exports.FoldMode = function() {};
}).call(FoldMode.prototype);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/chrome', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/chrome', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.cssClass = "ace-chrome";
exports.cssText = ".ace-chrome .ace_editor {\
@ -79,15 +79,11 @@ exports.cssText = ".ace-chrome .ace_editor {\
border-left: 0px;\
border-bottom: 1px solid black;\
}\
\
\
.ace-chrome .ace_line .ace_invisible {\
color: rgb(191, 191, 191);\
}\
\
.ace-chrome .ace_line .ace_keyword {\
color: blue;\
}\
\
.ace-chrome .ace_line .ace_constant.ace_buildin {\
color: rgb(88, 72, 246);\
}\
@ -121,14 +117,14 @@ exports.cssText = ".ace-chrome .ace_editor {\
color: rgb(109, 121, 222);\
}\
\
.ace-chrome .ace_variable.ace_parameter {\
font-style:italic;\
color:#FD971F;\
}\
.ace-chrome .ace_line .ace_keyword.ace_operator {\
color: rgb(104, 118, 135);\
}\
\
.ace-chrome .ace_line .ace_string {\
color: #1919a6;\
}\
\
.ace-chrome .ace_line .ace_comment {\
color: #236e24;\
}\
@ -195,6 +191,8 @@ exports.cssText = ".ace-chrome .ace_editor {\
border: 1px solid rgb(200, 200, 250);\
}\
\
.ace-chrome .ace_storage,\
.ace-chrome .ace_line .ace_keyword,\
.ace-chrome .ace_meta.ace_tag {\
color: rgb(147, 15, 128);\
}\
@ -203,6 +201,7 @@ exports.cssText = ".ace-chrome .ace_editor {\
color: rgb(255, 0, 0)\
}\
\
.ace-chrome .ace_line .ace_string,\
.ace-chrome .ace_entity.ace_other.ace_attribute-name{\
color: #994409;\
}";
@ -211,13 +210,3 @@ var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/clouds', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/clouds', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = false;
exports.cssClass = "ace-clouds";
@ -130,6 +130,10 @@ exports.cssText = "\
color:#C52727;\
}\
\
.ace-clouds .ace_storage {\
color:#C52727;\
}\
\
.ace-clouds .ace_string {\
color:#5D90CD;\
}\
@ -146,17 +150,6 @@ exports.cssText = "\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/clouds_midnight', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/clouds_midnight', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-clouds-midnight";
@ -131,6 +131,10 @@ background-color:#E92E2E;\
color:#E92E2E;\
}\
\
.ace-clouds-midnight .ace_storage {\
color:#E92E2E;\
}\
\
.ace-clouds-midnight .ace_string {\
color:#5D90CD;\
}\
@ -147,17 +151,6 @@ background-color:#E92E2E;\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/cobalt', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/cobalt', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-cobalt";
@ -127,6 +127,10 @@ background-color:#800F00;\
color:#FFB054;\
}\
\
.ace-cobalt .ace_storage {\
color:#FFEE80;\
}\
\
.ace-cobalt .ace_string.ace_regexp {\
color:#80FFC2;\
}\
@ -161,16 +165,6 @@ background-color:#001221;\
background-color:#130D26;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/crimson_editor', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/crimson_editor', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = false;
exports.cssText = ".ace-crimson-editor .ace_editor {\
border: 2px solid rgb(159, 159, 159);\
@ -196,13 +196,3 @@ exports.cssClass = "ace-crimson-editor";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/dawn', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/dawn', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = false;
exports.cssClass = "ace-dawn";
@ -135,6 +135,11 @@ color:#B52A1D;\
color:#693A17;\
}\
\
.ace-dawn .ace_storage {\
font-style:italic;\
color:#A71D5D;\
}\
\
.ace-dawn .ace_string {\
color:#0B6125;\
}\
@ -164,16 +169,6 @@ color:#5A525F;\
color:#693A17;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,202 +35,193 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/dreamweaver', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/dreamweaver', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = false;
exports.cssClass = "ace-tm";
exports.cssText = ".ace-tm .ace_editor {\
exports.cssClass = "ace-dreamweaver";
exports.cssText = ".ace-dreamweaver .ace_editor {\
border: 2px solid rgb(159, 159, 159);\
}\
\
.ace-tm .ace_editor.ace_focus {\
.ace-dreamweaver .ace_editor.ace_focus {\
border: 2px solid #327fbd;\
}\
\
.ace-tm .ace_gutter {\
.ace-dreamweaver .ace_gutter {\
background: #e8e8e8;\
color: #333;\
}\
\
.ace-tm .ace_print_margin {\
.ace-dreamweaver .ace_print_margin {\
width: 1px;\
background: #e8e8e8;\
}\
\
.ace-tm .ace_fold {\
.ace-dreamweaver .ace_fold {\
background-color: #00F;\
}\
\
.ace-tm .ace_text-layer {\
.ace-dreamweaver .ace_text-layer {\
cursor: text;\
}\
\
.ace-tm .ace_cursor {\
.ace-dreamweaver .ace_cursor {\
border-left: 2px solid black;\
}\
\
.ace-tm .ace_cursor.ace_overwrite {\
.ace-dreamweaver .ace_cursor.ace_overwrite {\
border-left: 0px;\
border-bottom: 1px solid black;\
}\
\
.ace-tm .ace_line .ace_invisible {\
.ace-dreamweaver .ace_line .ace_invisible {\
color: rgb(191, 191, 191);\
}\
\
.ace-tm .ace_line .ace_keyword {\
.ace-dreamweaver .ace_line .ace_storage,\
.ace-dreamweaver .ace_line .ace_keyword {\
color: blue;\
}\
\
.ace-tm .ace_line .ace_constant.ace_buildin {\
.ace-dreamweaver .ace_line .ace_constant.ace_buildin {\
color: rgb(88, 72, 246);\
}\
\
.ace-tm .ace_line .ace_constant.ace_language {\
.ace-dreamweaver .ace_line .ace_constant.ace_language {\
color: rgb(88, 92, 246);\
}\
\
.ace-tm .ace_line .ace_constant.ace_library {\
.ace-dreamweaver .ace_line .ace_constant.ace_library {\
color: rgb(6, 150, 14);\
}\
\
.ace-tm .ace_line .ace_invalid {\
.ace-dreamweaver .ace_line .ace_invalid {\
background-color: rgb(153, 0, 0);\
color: white;\
}\
\
.ace-tm .ace_line .ace_support.ace_function {\
.ace-dreamweaver .ace_line .ace_support.ace_function {\
color: rgb(60, 76, 114);\
}\
\
.ace-tm .ace_line .ace_support.ace_constant {\
.ace-dreamweaver .ace_line .ace_support.ace_constant {\
color: rgb(6, 150, 14);\
}\
\
.ace-tm .ace_line .ace_support.ace_type,\
.ace-tm .ace_line .ace_support.ace_class {\
.ace-dreamweaver .ace_line .ace_support.ace_type,\
.ace-dreamweaver .ace_line .ace_support.ace_class {\
color: #009;\
}\
\
.ace-tm .ace_line .ace_support.ace_php_tag {\
.ace-dreamweaver .ace_line .ace_support.ace_php_tag {\
color: #f00;\
}\
\
.ace-tm .ace_line .ace_keyword.ace_operator {\
.ace-dreamweaver .ace_line .ace_keyword.ace_operator {\
color: rgb(104, 118, 135);\
}\
\
.ace-tm .ace_line .ace_string {\
.ace-dreamweaver .ace_line .ace_string {\
color: #00F;\
}\
\
.ace-tm .ace_line .ace_comment {\
.ace-dreamweaver .ace_line .ace_comment {\
color: rgb(76, 136, 107);\
}\
\
.ace-tm .ace_line .ace_comment.ace_doc {\
.ace-dreamweaver .ace_line .ace_comment.ace_doc {\
color: rgb(0, 102, 255);\
}\
\
.ace-tm .ace_line .ace_comment.ace_doc.ace_tag {\
.ace-dreamweaver .ace_line .ace_comment.ace_doc.ace_tag {\
color: rgb(128, 159, 191);\
}\
\
.ace-tm .ace_line .ace_constant.ace_numeric {\
.ace-dreamweaver .ace_line .ace_constant.ace_numeric {\
color: rgb(0, 0, 205);\
}\
\
.ace-tm .ace_line .ace_variable {\
.ace-dreamweaver .ace_line .ace_variable {\
color: #06F\
}\
\
.ace-tm .ace_line .ace_xml_pe {\
.ace-dreamweaver .ace_line .ace_xml_pe {\
color: rgb(104, 104, 91);\
}\
\
.ace-tm .ace_entity.ace_name.ace_function {\
.ace-dreamweaver .ace_entity.ace_name.ace_function {\
color: #00F;\
}\
\
.ace-tm .ace_markup.ace_markupine {\
.ace-dreamweaver .ace_markup.ace_markupine {\
text-decoration:underline;\
}\
\
.ace-tm .ace_markup.ace_heading {\
.ace-dreamweaver .ace_markup.ace_heading {\
color: rgb(12, 7, 255);\
}\
\
.ace-tm .ace_markup.ace_list {\
.ace-dreamweaver .ace_markup.ace_list {\
color:rgb(185, 6, 144);\
}\
\
.ace-tm .ace_marker-layer .ace_selection {\
.ace-dreamweaver .ace_marker-layer .ace_selection {\
background: rgb(181, 213, 255);\
}\
\
.ace-tm .ace_marker-layer .ace_step {\
.ace-dreamweaver .ace_marker-layer .ace_step {\
background: rgb(252, 255, 0);\
}\
\
.ace-tm .ace_marker-layer .ace_stack {\
.ace-dreamweaver .ace_marker-layer .ace_stack {\
background: rgb(164, 229, 101);\
}\
\
.ace-tm .ace_marker-layer .ace_bracket {\
.ace-dreamweaver .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 {\
.ace-dreamweaver .ace_marker-layer .ace_active_line {\
background: rgba(0, 0, 0, 0.07);\
}\
\
.ace-tm .ace_marker-layer .ace_selected_word {\
.ace-dreamweaver .ace_marker-layer .ace_selected_word {\
background: rgb(250, 250, 255);\
border: 1px solid rgb(200, 200, 250);\
}\
\
.ace-tm .ace_meta.ace_tag {\
.ace-dreamweaver .ace_meta.ace_tag {\
color:#009;\
}\
\
.ace-tm .ace_meta.ace_tag.ace_anchor {\
.ace-dreamweaver .ace_meta.ace_tag.ace_anchor {\
color:#060;\
}\
\
.ace-tm .ace_meta.ace_tag.ace_form {\
.ace-dreamweaver .ace_meta.ace_tag.ace_form {\
color:#F90;\
}\
\
.ace-tm .ace_meta.ace_tag.ace_image {\
.ace-dreamweaver .ace_meta.ace_tag.ace_image {\
color:#909;\
}\
\
.ace-tm .ace_meta.ace_tag.ace_script {\
.ace-dreamweaver .ace_meta.ace_tag.ace_script {\
color:#900;\
}\
\
.ace-tm .ace_meta.ace_tag.ace_style {\
.ace-dreamweaver .ace_meta.ace_tag.ace_style {\
color:#909;\
}\
\
.ace-tm .ace_meta.ace_tag.ace_table {\
.ace-dreamweaver .ace_meta.ace_tag.ace_table {\
color:#099;\
}\
\
.ace-tm .ace_string.ace_regex {\
.ace-dreamweaver .ace_string.ace_regex {\
color: rgb(255, 0, 0)\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/eclipse', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/eclipse', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
"use strict";
exports.isDark = false;
@ -70,7 +70,9 @@ exports.cssText = ".ace-eclipse .ace_editor {\
border-left: 1px solid black;\
}\
\
.ace-eclipse .ace_line .ace_keyword, .ace-eclipse .ace_line .ace_variable {\
.ace-eclipse .ace_line .ace_storage,\
.ace-eclipse .ace_line .ace_keyword,\
.ace-eclipse .ace_line .ace_variable {\
color: rgb(127, 0, 85);\
}\
\
@ -143,13 +145,3 @@ exports.cssClass = "ace-eclipse";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/idle_fingers', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/idle_fingers', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-idle-fingers";
@ -123,6 +123,10 @@ background-color:#FF0000;\
color:#B83426;\
}\
\
.ace-idle-fingers .ace_variable.ace_parameter {\
font-style:italic;\
}\
\
.ace-idle-fingers .ace_string {\
color:#A5C261;\
}\
@ -153,16 +157,6 @@ color:#BC9458;\
background-color:#FFF980; \
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/kr_theme', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/kr_theme', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-kr-theme";
@ -127,6 +127,10 @@ background-color:#A41300;\
color:#85873A;\
}\
\
.ace-kr-theme .ace_storage {\
color:#FFEE80;\
}\
\
.ace-kr-theme .ace_string.ace_regexp {\
color:rgba(125, 255, 192, 0.65);\
}\
@ -156,16 +160,6 @@ color:#706D5B;\
background-color:#0F0040;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -19,7 +19,7 @@
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Michael Schwartz <mr.pants AT gmail DOT com>
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/merbivore', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/merbivore', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-merbivore";
@ -135,6 +135,10 @@ background-color:#990000;\
color:#FC6F09;\
}\
\
.ace-merbivore .ace_storage {\
color:#FC6F09;\
}\
\
.ace-merbivore .ace_string {\
color:#8DFF0A;\
}\
@ -156,16 +160,6 @@ color:#AD2EA4;\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -19,7 +19,7 @@
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Michael Schwartz <mr.pants AT gmail DOT com>
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/merbivore_soft', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/merbivore_soft', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-merbivore-soft";
@ -136,6 +136,10 @@ background-color:#FE3838;\
border-color: #E6E1DC;\
}\
\
.ace-merbivore-soft .ace_storage {\
color:#FC803A;\
}\
\
.ace-merbivore-soft .ace_string {\
color:#8EC65F;\
}\
@ -162,16 +166,6 @@ color:#AC4BB8;\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/mono_industrial', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/mono_industrial', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-mono-industrial";
@ -131,6 +131,14 @@ background-color:rgba(153, 0, 0, 0.68);\
color:#588E60;\
}\
\
.ace-mono-industrial .ace_storage {\
color:#C23B00;\
}\
\
.ace-mono-industrial .ace_variable.ace_parameter {\
color:#648BD2;\
}\
\
.ace-mono-industrial .ace_comment {\
color:#666C68;\
background-color:#151C19;\
@ -156,16 +164,6 @@ background-color:#151C19;\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/monokai', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/monokai', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-monokai";
@ -132,6 +132,20 @@ background-color:#AE81FF;\
color:#66D9EF;\
}\
\
.ace-monokai .ace_storage {\
color:#F92672;\
}\
\
.ace-monokai .ace_storage.ace_type {\
font-style:italic;\
color:#66D9EF;\
}\
\
.ace-monokai .ace_variable.ace_parameter {\
font-style:italic;\
color:#FD971F;\
}\
\
.ace-monokai .ace_string {\
color:#E6DB74;\
}\
@ -152,16 +166,6 @@ background-color:#AE81FF;\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -19,7 +19,7 @@
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* André Fiedler <fiedler dot andre a t gmail dot com>
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/pastel_on_dark', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/pastel_on_dark', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-pastel-on-dark";
@ -174,16 +174,6 @@ color:#D2A8A1;\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/solarized_dark', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/solarized_dark', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-solarized-dark";
@ -122,6 +122,10 @@ exports.cssText = "\
color:#268BD2;\
}\
\
.ace-solarized-dark .ace_storage {\
color:#93A1A1;\
}\
\
.ace-solarized-dark .ace_string {\
color:#2AA198;\
}\
@ -151,16 +155,6 @@ color:#657B83;\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/solarized_light', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/solarized_light', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = false;
exports.cssClass = "ace-solarized-light";
@ -122,6 +122,10 @@ exports.cssText = "\
color:#268BD2;\
}\
\
.ace-solarized-light .ace_storage {\
color:#073642;\
}\
\
.ace-solarized-light .ace_string {\
color:#2AA198;\
}\
@ -150,16 +154,6 @@ exports.cssText = "\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -1,210 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Ajax.org Code Editor (ACE).
*
* The Initial Developer of the Original Code is
* Ajax.org B.V.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/textmate', ['require', 'exports', 'module' ], function(require, exports, module) {
"use strict";
exports.isDark = false;
exports.cssClass = "ace-tm";
exports.cssText = ".ace-tm .ace_editor {\
border: 2px solid rgb(159, 159, 159);\
}\
\
.ace-tm .ace_editor.ace_focus {\
border: 2px solid #327fbd;\
}\
\
.ace-tm .ace_gutter {\
background: #e8e8e8;\
color: #333;\
}\
\
.ace-tm .ace_print_margin {\
width: 1px;\
background: #e8e8e8;\
}\
\
.ace-tm .ace_fold {\
background-color: #6B72E6;\
}\
\
.ace-tm .ace_text-layer {\
cursor: text;\
}\
\
.ace-tm .ace_cursor {\
border-left: 2px solid black;\
}\
\
.ace-tm .ace_cursor.ace_overwrite {\
border-left: 0px;\
border-bottom: 1px solid black;\
}\
\
.ace-tm .ace_line .ace_invisible {\
color: rgb(191, 191, 191);\
}\
\
.ace-tm .ace_line .ace_keyword {\
color: blue;\
}\
\
.ace-tm .ace_line .ace_constant.ace_buildin {\
color: rgb(88, 72, 246);\
}\
\
.ace-tm .ace_line .ace_constant.ace_language {\
color: rgb(88, 92, 246);\
}\
\
.ace-tm .ace_line .ace_constant.ace_library {\
color: rgb(6, 150, 14);\
}\
\
.ace-tm .ace_line .ace_invalid {\
background-color: rgb(153, 0, 0);\
color: white;\
}\
\
.ace-tm .ace_line .ace_support.ace_function {\
color: rgb(60, 76, 114);\
}\
\
.ace-tm .ace_line .ace_support.ace_constant {\
color: rgb(6, 150, 14);\
}\
\
.ace-tm .ace_line .ace_support.ace_type,\
.ace-tm .ace_line .ace_support.ace_class {\
color: rgb(109, 121, 222);\
}\
\
.ace-tm .ace_line .ace_keyword.ace_operator {\
color: rgb(104, 118, 135);\
}\
\
.ace-tm .ace_line .ace_string {\
color: rgb(3, 106, 7);\
}\
\
.ace-tm .ace_line .ace_comment {\
color: rgb(76, 136, 107);\
}\
\
.ace-tm .ace_line .ace_comment.ace_doc {\
color: rgb(0, 102, 255);\
}\
\
.ace-tm .ace_line .ace_comment.ace_doc.ace_tag {\
color: rgb(128, 159, 191);\
}\
\
.ace-tm .ace_line .ace_constant.ace_numeric {\
color: rgb(0, 0, 205);\
}\
\
.ace-tm .ace_line .ace_variable {\
color: rgb(49, 132, 149);\
}\
\
.ace-tm .ace_line .ace_xml_pe {\
color: rgb(104, 104, 91);\
}\
\
.ace-tm .ace_entity.ace_name.ace_function {\
color: #0000A2;\
}\
\
.ace-tm .ace_markup.ace_markupine {\
text-decoration:underline;\
}\
\
.ace-tm .ace_markup.ace_heading {\
color: rgb(12, 7, 255);\
}\
\
.ace-tm .ace_markup.ace_list {\
color:rgb(185, 6, 144);\
}\
\
.ace-tm .ace_marker-layer .ace_selection {\
background: rgb(181, 213, 255);\
}\
\
.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_marker-layer .ace_selected_word {\
background: rgb(250, 250, 255);\
border: 1px solid rgb(200, 200, 250);\
}\
\
.ace-tm .ace_meta.ace_tag {\
color:rgb(28, 2, 255);\
}\
\
.ace-tm .ace_string.ace_regex {\
color: rgb(255, 0, 0)\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/tomorrow', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/tomorrow', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = false;
exports.cssClass = "ace-tomorrow";
@ -136,6 +136,18 @@ background-color:#8959A8;\
color:#4271AE;\
}\
\
.ace-tomorrow .ace_storage {\
color:#8959A8;\
}\
\
.ace-tomorrow .ace_storage.ace_type {\
color:#8959A8;\
}\
\
.ace-tomorrow .ace_variable.ace_parameter {\
color:#F5871F;\
}\
\
.ace-tomorrow .ace_string {\
color:#718C00;\
}\
@ -172,16 +184,6 @@ background-color:#8959A8;\
color:#718C00;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/tomorrow_night', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/tomorrow_night', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-tomorrow-night";
@ -136,6 +136,18 @@ background-color:#B798BF;\
color:#81A2BE;\
}\
\
.ace-tomorrow-night .ace_storage {\
color:#B294BB;\
}\
\
.ace-tomorrow-night .ace_storage.ace_type {\
color:#B294BB;\
}\
\
.ace-tomorrow-night .ace_variable.ace_parameter {\
color:#DE935F;\
}\
\
.ace-tomorrow-night .ace_string {\
color:#B5BD68;\
}\
@ -172,16 +184,6 @@ background-color:#B798BF;\
color:#B5BD68;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/tomorrow_night_blue', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/tomorrow_night_blue', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-tomorrow-night-blue";
@ -136,6 +136,18 @@ background-color:#EBBBFF;\
color:#BBDAFF;\
}\
\
.ace-tomorrow-night-blue .ace_storage {\
color:#EBBBFF;\
}\
\
.ace-tomorrow-night-blue .ace_storage.ace_type {\
color:#EBBBFF;\
}\
\
.ace-tomorrow-night-blue .ace_variable.ace_parameter {\
color:#FFC58F;\
}\
\
.ace-tomorrow-night-blue .ace_string {\
color:#D1F1A9;\
}\
@ -172,16 +184,6 @@ background-color:#EBBBFF;\
color:#D1F1A9;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/tomorrow_night_bright', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/tomorrow_night_bright', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-tomorrow-night-bright";
@ -136,6 +136,18 @@ background-color:#B798BF;\
color:#7AA6DA;\
}\
\
.ace-tomorrow-night-bright .ace_storage {\
color:#C397D8;\
}\
\
.ace-tomorrow-night-bright .ace_storage.ace_type {\
color:#C397D8;\
}\
\
.ace-tomorrow-night-bright .ace_variable.ace_parameter {\
color:#E78C45;\
}\
\
.ace-tomorrow-night-bright .ace_string {\
color:#B9CA4A;\
}\
@ -172,16 +184,6 @@ background-color:#B798BF;\
color:#B9CA4A;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/tomorrow_night_eighties', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/tomorrow_night_eighties', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-tomorrow-night-eighties";
@ -136,6 +136,18 @@ background-color:#CC99CC;\
color:#6699CC;\
}\
\
.ace-tomorrow-night-eighties .ace_storage {\
color:#CC99CC;\
}\
\
.ace-tomorrow-night-eighties .ace_storage.ace_type {\
color:#CC99CC;\
}\
\
.ace-tomorrow-night-eighties .ace_variable.ace_parameter {\
color:#F99157;\
}\
\
.ace-tomorrow-night-eighties .ace_string {\
color:#99CC99;\
}\
@ -168,16 +180,6 @@ background-color:#CC99CC;\
color:#99CC99;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/twilight', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/twilight', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-twilight";
@ -133,6 +133,10 @@ color:#D2A8A1;\
color:#DAD085;\
}\
\
.ace-twilight .ace_storage {\
color:#F9EE98;\
}\
\
.ace-twilight .ace_string {\
color:#8F9D6A;\
}\
@ -174,16 +178,6 @@ color:#5F5A60;\
color:#F9EE98;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();

View file

@ -19,7 +19,7 @@
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Michael Schwartz <mr.pants AT gmail DOT com>
* Fabian Jakobs <fabian AT ajax DOT org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
@ -35,7 +35,7 @@
*
* ***** END LICENSE BLOCK ***** */
__ace_shadowed__.define('ace/theme/vibrant_ink', ['require', 'exports', 'module' ], function(require, exports, module) {
__ace_shadowed__.define('ace/theme/vibrant_ink', ['require', 'exports', 'module' , 'ace/lib/dom'], function(require, exports, module) {
exports.isDark = true;
exports.cssClass = "ace-vibrant-ink";
@ -132,6 +132,10 @@ background-color:#000000;\
color:#FFCC00;\
}\
\
.ace-vibrant-ink .ace_variable.ace_parameter {\
font-style:italic;\
}\
\
.ace-vibrant-ink .ace_string {\
color:#66FF00;\
}\
@ -157,16 +161,6 @@ color:#99CC99;\
text-decoration:underline;\
}";
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
var dom = require("../lib/dom");
dom.importCssString(exports.cssText, exports.cssClass);
});
;
(function() {
__ace_shadowed__.require(["ace/ext/textarea"], function(a) {
if (!window.__ace_shadowed__)
window.__ace_shadowed__ = {};
for (var key in a) if (a.hasOwnProperty(key))
__ace_shadowed__[key] = a[key];
});
})();