GNU bug report logs -
#20296
11.88.3; LaTeX-fill-paragraph gives unexpected result
Previous Next
Reported by: jfbu <jfbu <at> free.fr>
Date: Fri, 10 Apr 2015 20:33:02 UTC
Severity: normal
Found in version 11.88.3
Done: Arash Esbati <arash <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Le 10 avr. 2015 à 23:38, Tassilo Horn <tsdh <at> gnu.org> a écrit :
> jfbu <jfbu <at> free.fr> writes:
>
>> I do not understand the behavior of LaTeX-fill-paragraph. It keeps
>> annoying me with partially filled paragraphs.
>>
>> Sample .tex file illustrating the problem:
>>
>> -------------
>> \documentclass{article}
>>
>> \begin{document}
>> % Sample paragraph
>>
>> Without the separation axiom this does not work, for example let $V$ be an
>> infinite dimensional Banach space and let $X = V\cup\{*\}$, and let's declare
>> open the standard open $U\subset V$ as well as $X$ itself. This defines a
>> topology. The space is globally compact in the sense of coverings, but it
>> is not locally compact. Fortunately, it is not separated.
>>
>> % Applying M-q (LaTeX-fill-paragraph) to the paragraph above we get:
>>
>> Without the separation axiom this does not work, for example let $V$ be an
>> infinite dimensional Banach space and let $X =
>> V\cup\{*\}$, and let's declare open the standard open $U\subset V$ as well as
>> $X$ itself. This defines a topology. The space is globally compact in the sense
>> of coverings, but it is not locally compact. Fortunately, it is not separated.
>>
>> % fill-column is 78
>> \end{document}
>> -------------
>
> With a fresh emacs running AUCTeX 11.88.3 with no configurations, the
> paragraph above is filled to
>
> --8<---------------cut here---------------start------------->8---
> Without the separation axiom this does not work, for example let $V$ be an
> infinite dimensional Banach space and let $X = V\cup\{*\}$, and let's declare
> open the standard open $U\subset V$ as well as $X$ itself. This defines a
> topology. The space is globally compact in the sense of coverings, but it is
> not locally compact. Fortunately, it is not separated.
> --8<---------------cut here---------------end--------------->8---
>
> here when fill-column is 78. That looks correct to me. So maybe
> something in your configs causes the bad filling.
>
> Bye,
> Tassilo
Hi Tassilo,
thanks for having looked into this.
I have identified the bad config (sorry for not having done it earlier).
Turns out I have
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
; ...
'(LaTeX-verbatim-macros-with-delims nil)
;...
)
in my custom file
If I comment the LaTeX-verbatim-macros-with-delims setting, the problem
disappears.
(I obtained that via a dichotomy search on both my custom and init files,
that was full of suspense and the final result is a surprise)
As it stands the effect is:
LaTeX-verbatim-macros-with-delims is a variable defined in `latex.el'.
Its value is nil
Original value was ("verb" "verb*")
As I don't master elisp I must have done an error, and assigning nil
value to this variable is not the correct way to remove "verb" and "verb*"
from it.
The rationale for me is that sometimes I redefine the \verb macro to
allow line breaks in the source and also in the dvi/pdf output, thus I don't
care about fill-paragraph not breaking \verb|...| things.
Here is a more complete excerpt with possibly relevant lines:
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(Info-additional-directory-list (quote ("/sw/share/info")))
'(LaTeX-indent-environment-list
(quote
(("verbatim" current-indentation)
("verbatim*" current-indentation)
("everbatim" current-indentation)
("everbatim*" current-indentation)
("array")
("displaymath")
("eqnarray")
("eqnarray*")
("equation")
("equation*")
("picture")
("tabbing")
("table")
("table*")
("tabular")
("tabular*"))))
'(LaTeX-verbatim-environments (quote ("verbatim" "verbatim*" "everbatim" "everbatim*")))
;;BAD
'(LaTeX-verbatim-macros-with-delims nil)
;;ENDBAD
'(TeX-auto-save nil)
'(TeX-close-quote "»")
'(TeX-command "etex")
;
; <many more lines>
)
For my current context, commenting out the bad line is enough of a fix
but I would like to understand better why the bad line is bad.
Sorry again for not having looked for a bad config before posting the
bug report (I should have posted the bug report to myself only first)
best
Jean-François
This bug report was last modified 1 year and 84 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.