From: Reiner Steib Date: Tue, 30 May 2006 18:37:15 +0000 (+0000) Subject: * textmodes/flyspell.el (turn-on-flyspell, turn-off-flyspell): New X-Git-Tag: emacs-pretest-22.0.90~2173 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=2809db3399d9807158abefef67677f51b825d361;p=emacs.git * textmodes/flyspell.el (turn-on-flyspell, turn-off-flyspell): New functions. * textmodes/text-mode.el (text-mode-hook): Use turn-on-flyspell. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 675087bc16c..bd2821c2a3f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2006-05-30 Reiner Steib + + * textmodes/flyspell.el (turn-on-flyspell, turn-off-flyspell): New + functions. + + * textmodes/text-mode.el (text-mode-hook): Use turn-on-flyspell. + 2006-05-30 Carsten Dominik * textmodes/org.el: (org-agenda-highlight-todo): Make sure regexp diff --git a/lisp/textmodes/flyspell.el b/lisp/textmodes/flyspell.el index c20ecef31e0..23f4756f4a7 100644 --- a/lisp/textmodes/flyspell.el +++ b/lisp/textmodes/flyspell.el @@ -486,6 +486,18 @@ in your .emacs file. (flyspell-mode-on) (flyspell-mode-off))) +;;;###autoload +(defun turn-on-flyspell () + "Unconditionally turn on Flyspell mode." + (flyspell-mode 1)) + +;;;###autoload +(defun turn-off-flyspell () + "Unconditionally turn off Flyspell mode." + (flyspell-mode -1)) + +(custom-add-option 'text-mode-hook 'turn-on-flyspell) + ;;*---------------------------------------------------------------------*/ ;;* flyspell-buffers ... */ ;;* ------------------------------------------------------------- */ diff --git a/lisp/textmodes/text-mode.el b/lisp/textmodes/text-mode.el index a4b67057676..9263c48f18b 100644 --- a/lisp/textmodes/text-mode.el +++ b/lisp/textmodes/text-mode.el @@ -33,7 +33,7 @@ (defcustom text-mode-hook nil "Normal hook run when entering Text mode and many related modes." :type 'hook - :options '(turn-on-auto-fill flyspell-mode) + :options '(turn-on-auto-fill turn-on-flyspell) :group 'data) (defvar text-mode-variant nil