3

I have predictive, auctex installed. I want predictive mode to work with my .tex files but I keep getting a warning of:

Warning (emacs): Predictive major-mode setup function predictive-setup-latex failed; latex-mode support disabled

after trying to turn on predictive mode with M-x predictive-mode when a .tex file is open.

I've found this issue here,

https://superuser.com/questions/326431/why-is-emacs-predictive-mode-not-working-for-latex-documents

https://tex.stackexchange.com/questions/26109/emacs-predictive-mode-does-not-work-for-latex-documents

But both are inconclusive to me as I know predictive mode has successfully installed, its being managed by el-get.

Usually I debug with emacs --debug-init, but this is happening long after the .emacs is loaded.

2
  • 1
    Maybe (debug-on-entry 'predictive-setup-latex) might help
    – Vamsi
    Commented Sep 23, 2014 at 23:51
  • While that doesn't directly help me, thank you for providing that tip, didn't know about debug on entry.
    – c-o-d
    Commented Sep 23, 2014 at 23:59

1 Answer 1

2

After digging some more, I found the solution. Thank you Vamsi for the debug-on-entry tip.

I was getting the error because the predictive/latex wasn't on the load path. I assumed that el-get would take care of all the proper loading but it doesn't since predictive/latex, predictive/texinfo aren't really needed for all predictive use-cases. So the solution is to simply add them to the load-path.

The easiest and kludgiest solution is to add to your .emacs:

(add-to-list 'load-path "~/.emacs.d/el-get/predictive/latex")
(add-to-list 'load-path "~/.emacs.d/el-get/predictive/texinfo")

This answer of course assumes you are using el-get like I am.

1
  • 1
    I've added a pull request to fix this issue for el-get.
    – xuhdev
    Commented Dec 1, 2014 at 4:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.