[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Orgmode] Verse construct generates invalid LaTeX code
From: |
Antti Kaihola |
Subject: |
[Orgmode] Verse construct generates invalid LaTeX code |
Date: |
Thu, 24 Sep 2009 13:10:32 +0300 |
Here's an example file:
-----------------------------versetest.org
Test case for verse bug
#+BEGIN_VERSE
This is
the first stanza.
This is
the second stanza.
#+END_VERSE
-----------------------------versetest.org
It generates the following LaTeX code with the C-c C-e L command
(excerpt with line numbers added):
-----------------------------versetest.tex
22: \begin{verse}
23: This is\\
24: the first stanza.\\
25: \\
26: This is\\
27: the second stanza.\\
28: \end{verse}
-----------------------------versetest.tex
When compiled with pdflatex, it causes this error:
-----------------------------pdflatex output
! LaTeX Error: There's no line here to end.
See the LaTeX manual or LaTeX Companion for explanation.
Type H <return> for immediate help.
...
l.25 \\
-----------------------------pdflatex output
Org-mode probably instructs pdflatex to ignore errors since C-c C-e d
compiles the .org file just fine, just without any break between
the stanzas.
Edition 1.6 of the LaTeX2e documentation states:
Separate the lines of each stanza with \\, and use one or more blank
lines to separate the stanzas,
so the correct LaTeX output would be:
-----------------------------corrected versetest.tex
22: \begin{verse}
23: This is\\
24: the first stanza.
25:
26: This is\\
27: the second stanza.
28: \end{verse}
-----------------------------corrected versetest.tex
- [Orgmode] Verse construct generates invalid LaTeX code,
Antti Kaihola <=