diff --git a/README.md b/README.md index 1673665..8cf07f2 100644 --- a/README.md +++ b/README.md @@ -250,8 +250,7 @@ personal config with the following bit of code: If you're not fond of spellchecking on the fly: ```lisp -(add-hook 'text-mode-hook 'turn-off-flyspell t) -(add-hook 'prog-mode-hook 'turn-off-flyspell t) +(setq prelude-flyspell nil) ``` ### Prelude Modules diff --git a/prelude/prelude-editor.el b/prelude/prelude-editor.el index 18c7432..fa0e009 100644 --- a/prelude/prelude-editor.el +++ b/prelude/prelude-editor.el @@ -49,7 +49,12 @@ :group 'prelude) (defcustom prelude-whitespace nil - "Non-nil values enable Prelude's whitespace visualisation." + "Non-nil values enable Prelude's whitespace visualization." + :type 'boolean + :group 'prelude) + +(defcustom prelude-flyspell t + "Non-nil values enable Prelude's flyspell support." :type 'boolean :group 'prelude) @@ -209,7 +214,7 @@ ispell-extra-args '("--sug-mode=ultra")) (autoload 'flyspell-mode "flyspell" "On-the-fly spelling checker." t) -(when (executable-find ispell-program-name) +(when (and prelude-flyspell (executable-find ispell-program-name)) (add-hook 'message-mode-hook 'flyspell-mode) (add-hook 'text-mode-hook 'flyspell-mode))