SpellChecker/spell-checker.js
Summary
No overview generated for 'SpellChecker/spell-checker.js'
HTMLArea.Config.prototype.SpellChecker = { 'backend': 'php', 'personalFilesDir' : '', 'defaultDictionary' : 'en_GB' };
function SpellChecker(editor) {
this.editor = editor;
var cfg = editor.config;
var bl = SpellChecker.btnList;
var self = this;
var id = "SC-spell-check";
cfg.registerButton(id, this._lc("Spell-check"), editor.imgURL("spell-check.gif", "SpellChecker"), false,
function(editor, id) {
self.buttonPress(editor, id);
});
var done = false;
for(var i = 0; i < cfg.toolbar.length; i++)
{
if(cfg.toolbar[i].contains('htmlmode'))
{
var j = cfg.toolbar[i].indexOf('htmlmode');
cfg.toolbar[i].splice(j,0,id);
done = true;
break;
}
}
if(!done)
{
cfg.toolbar[0].push(id);
}
};
SpellChecker._pluginInfo = {
name : "SpellChecker",
version : "1.0",
developer : "Mihai Bazon",
developer_url : "http://dynarch.com/mishoo/",
c_owner : "Mihai Bazon",
sponsor : "American Bible Society",
sponsor_url : "http://www.americanbible.org",
license : "htmlArea"
};
SpellChecker.prototype._lc = function(string) {
return HTMLArea._lc(string, 'SpellChecker');
}
SpellChecker.btnList = [
null, // separator
["spell-check"]
];
SpellChecker.prototype.buttonPress = function(editor, id) {
switch (id) {
case "SC-spell-check":
SpellChecker.editor = editor;
SpellChecker.init = true;
var uiurl = _editor_url + "plugins/SpellChecker/spell-check-ui.html";
var win;
if (HTMLArea.is_ie) {
win = window.open(uiurl, "SC_spell_checker",
"toolbar=no,location=no,directories=no,status=no,menubar=no," +
"scrollbars=no,resizable=yes,width=600,height=450");
} else {
win = window.open(uiurl, "SC_spell_checker",
"toolbar=no,menubar=no,personalbar=no,width=600,height=450," +
"scrollbars=no,resizable=yes");
}
win.focus();
break;
}
};
SpellChecker.editor = null;
Documentation generated by
JSDoc on Mon Jun 13 20:27:40 2005