Malabarba / latex-extra

A series of usability improvements for Emacs latex-mode.
GNU General Public License v3.0
69 stars 14 forks source link

Auto-fill doesn't always recognize math mode #2

Closed SiameseCat closed 10 years ago

SiameseCat commented 10 years ago

latex/auto-fill-function doesn't recognize when point is in basic math mode (i.e. LaTeX code like \[ \sqrt{x} \]). I think texmathp can be used to recognize if point is inside math mode.

Malabarba commented 10 years ago

Thanks for the tip, this function will be a huge help.

I'll get to it as soon as I have time. But it will be trivial to implement so it should be up by tomorrow or sunday.

Malabarba commented 10 years ago

Just pushed a fix for this. You can download it now or wait a few hours for it to come up on Melpa.

You can use the latex/should-auto-fill-$ variable to define whether simple inline math gets autofilled. Every other type of math won't be autofilled.