Yotam
Yotam

Reputation: 10685

flyspell doesn't load with LaTeX file in emacs

Following this web page, I have edited my ~/.emacs file and added the line:

(add-hook 'LaTeX-mode-hook 'flyspell-mode)

However, flyspell doesn't start with LaTeX files. Why is that so?

Upvotes: 6

Views: 1150

Answers (2)

hpekristiansen
hpekristiansen

Reputation: 1070

I could not make this work:

(add-hook 'LaTeX-mode-hook 'flyspell-mode)   or
(add-hook 'latex-mode-hook 'flyspell-mode)

But then I found this:

(add-hook 'LaTeX-mode-hook 'turn-on-flyspell)

-and it is working.

Upvotes: 5

ataylor
ataylor

Reputation: 66069

Emacs is case-sensitive; the hook should be written as latex-mode-hook. Try this:

(add-hook 'latex-mode-hook 'flyspell-mode)

Upvotes: 4

Related Questions