Hi,

When exporting headings to LaTeX lists, I can see extra vertical blank spaces
if the headings directly starts with a sub-heading or a list. It does not
happen if you have text in your heading (before the sub-heading or the list).

Here's my ECM:

--8<---------------cut here---------------start------------->8---
#+OPTIONS:   H:2 num:t toc:nil

* Level 1

** Level 2

*** Level 3

**** A

- A1
- A2
- A3

**** B

- B1
- B2
- B3
--8<---------------cut here---------------end--------------->8---

When exporting this example to LaTeX, you can see that there's extra space
between:

- Level 3 and A
- A and A1
- B and B1

This happens beacause the LaTeX export adds and extra line break (\\) after
each \item in addition to the newline (\n). I thus propose the following patch
which fixes the problem:

--8<---------------cut here---------------start------------->8---
index 764a48d..706bb4a 100644
--- a/lisp/org-latex.el
+++ b/lisp/org-latex.el
@@ -1234,7 +1234,7 @@ numbered sections and lower levels as unnumbered 
sections."
                 (delete-region (point-at-bol 0) (point))
               (insert (format "\\begin{%s}\n"
                               (symbol-name org-export-latex-low-levels))))
-            (insert (format "\n\\item %s\\\\\n%s%%"
+            (insert (format "\n\\item %s\n%s%%"
                             heading
                             (if label (format "\\label{%s}" label) "")))
             (insert (org-export-latex-content content))
--8<---------------cut here---------------end--------------->8---

If you don't see any problem with this fix, could you apply it?

Thanks a lot,
 Francesco Pizzolante

Reply via email to