summaryrefslogtreecommitdiff
path: root/common/content/editor.js
diff options
context:
space:
mode:
authorKris Maglione <maglione.k@gmail.com>2011-08-06 08:47:36 -0400
committerKris Maglione <maglione.k@gmail.com>2011-08-06 08:47:36 -0400
commitd828a53b7a045a993650b661a2170edaea3a5214 (patch)
tree774d530d8270e09f53036baf981bb969a393ea78 /common/content/editor.js
parent4958d6854f805ddd4743bee08813b2f117fcd528 (diff)
downloadpentadactyl-d828a53b7a045a993650b661a2170edaea3a5214.tar.gz
Add 'spelllang'. Closes issue #530.
Diffstat (limited to 'common/content/editor.js')
-rw-r--r--common/content/editor.js15
1 files changed, 15 insertions, 0 deletions
diff --git a/common/content/editor.js b/common/content/editor.js
index 25b2de84..007679db 100644
--- a/common/content/editor.js
+++ b/common/content/editor.js
@@ -855,6 +855,21 @@ var Editor = Module("editor", {
options.add(["insertmode", "im"],
"Enter Insert mode rather than Text Edit mode when focusing text areas",
"boolean", true);
+
+ options.add(["spelllang", "spl"],
+ "The language used by the spell checker",
+ "string", config.locale,
+ {
+ initValue: function () {},
+ getter: function getter() services.spell.dictionary || "",
+ setter: function setter(val) { services.spell.dictionary = val; },
+ completer: function completer(context) {
+ let res = {};
+ services.spell.getDictionaryList(res, {});
+ context.completions = res.value;
+ context.keys = { text: util.identity, description: util.identity };
+ }
+ });
}
});