On Mon, 14 Jan 2008, Tim Connors wrote: > Bugger. I was premature. When I do the following: > (autoload 'flyspell-mode-on "flyspell" "On-the-fly ispell." t) > (add-hook 'TeX-mode-hook 'flyspell-mode-on) ; encompases LaTeX-mode as > well > (add-hook 'text-mode-hook 'flyspell-mode-on) > (add-hook 'html-mode-hook 'flyspell-mode-on) > (add-hook 'mail-hook 'flyspell-mode-on) > (add-hook 'message-hook 'flyspell-mode-on) > (add-hook 'flyspell-mode-hook 'flyspell-buffer) > > (I don't simply use 'flyspell-mode because it is a toggle, and some modes > encompass other modes and you end up with flyspell being turned on then > off immediately. It's easier for my brain if I add the hook to the modes > I want explicitly rather than trying to work out which mode is a parent of > which other mode)
And for future reference when testing, some modes like message-mode if defined as such: ;(add-hook 'TeX-mode-hook 'flyspell-mode) ; encompases LaTeX-mode as well (add-hook 'text-mode-hook 'flyspell-mode) (add-hook 'html-mode-hook 'flyspell-mode) ;(add-hook 'mail-hook 'flyspell-mode) ;(add-hook 'message-hook 'flyspell-mode) will happily go into flyspell-mode, but will not execute the flyspell-mode-hook, or executes it at the wrong time, so it doesn't pre-check the buffer - it only checks and highlights bad spelling once you move over the questionable text. Forcing it on with flyspell-mode-on, for all wanted modes, seems to be the guaranteed way of making the hook execute, and making sure the mode truly is turned on. -- TimC "Meddle not in the affairs of cats, for they are subtle, and will piss on your computer." - Jeff Wilder -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]