[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] LaTeX export of headings to lists
From: |
Francesco Pizzolante |
Subject: |
[O] LaTeX export of headings to lists |
Date: |
Fri, 27 May 2011 08:30:45 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (windows-nt) |
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
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [O] LaTeX export of headings to lists,
Francesco Pizzolante <=