After I updated Aquamacs, using Alt-q
(in the Auto-Fill minor mode) to fill paragraphs when editing a LaTeX document results in each line being broken at the first occurrence of the LaTeX maths closing delimiter, \)
. (Well, almost! See the example below for the one exception.)
Version information: Aquamacs 3.2 GNU Emacs 24.4.51.2
.
Question
How do I tell Aquamacs/Emacs/Auto-Fill mode not to break lines at the first \)
that it sees on a line, but to actually fill in the paragraph as it used to do before the update?
Steps to reproduce this behaviour
Help -> Diagnose and report bug -> Start Aquamacs without customizations
to get a "pristine" Aquamacs window.- Open a file named
testemacs.tex
and paste the Lorem Ipsum text, twice to make two paragraphs. - Add small maths expressions delimited by the LaTeX delimiters
\(
and\)
, at random places in the second paragraph. Leave the first paragraph as it is. - Type
Alt-x auto-fill-mode
to enable Auto-Fill mode. - Go to each paragraph and type
Alt-q
to invoke thefill-paragraph
function. - Observe the difference! See the screenshot below:
As you can see, everywhere except on the very last line, fill-paragraph
breaks the line at the first closing delimiter \)
that it sees. This makes the paragraph look really ugly, and defeats the whole purpose of filling-in paragraphs. How can I get rid of this behaviour?
Modes
Please see the screenshot below for the modes in operation: