mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2025-01-05 11:45:52 +00:00
Export: Fix bug with LaTeX export of tables.
The special first column in some tables was not removed for LaTeX export. This bug was probably introduces recently, while trying to fix problems with special characters in LaTeX tables. Export is now working again properly. Reported by Giovanni Ridolfi.
This commit is contained in:
parent
a4244d5783
commit
fee4492f57
@ -1,3 +1,12 @@
|
||||
2009-01-17 Carsten Dominik <carsten.dominik@gmail.com>
|
||||
|
||||
* org-export-latex.el (org-export-latex-tables): Call
|
||||
`org-table-clean-before-export' with the new optional argument.
|
||||
|
||||
* org-exp.el (org-table-clean-before-export): New optional
|
||||
parameter MAYBE-QUOTED, allows for quoted characters like \# in
|
||||
first column.
|
||||
|
||||
2009-01-16 Carsten Dominik <carsten.dominik@gmail.com>
|
||||
|
||||
* org-plot.el (org-plot/gnuplot): Fix text-ind parameter for
|
||||
|
@ -4151,14 +4151,18 @@ lang=\"%s\" xml:lang=\"%s\">
|
||||
(push html-table-tag html))
|
||||
(concat (mapconcat 'identity html "\n") "\n")))
|
||||
|
||||
(defun org-table-clean-before-export (lines)
|
||||
(defun org-table-clean-before-export (lines &optional maybe-quoted)
|
||||
"Check if the table has a marking column.
|
||||
If yes remove the column and the special lines."
|
||||
(setq org-table-colgroup-info nil)
|
||||
(if (memq nil
|
||||
(mapcar
|
||||
(lambda (x) (or (string-match "^[ \t]*|-" x)
|
||||
(string-match "^[ \t]*| *\\([#!$*_^ /]\\) *|" x)))
|
||||
(string-match
|
||||
(if maybe-quoted
|
||||
"^[ \t]*| *\\\\?\\([\#!$*_^ /]\\) *|"
|
||||
"^[ \t]*| *\\([\#!$*_^ /]\\) *|")
|
||||
x)))
|
||||
lines))
|
||||
(progn
|
||||
(setq org-table-clean-did-remove-column nil)
|
||||
|
@ -1072,7 +1072,7 @@ The conversion is made depending of STRING-BEFORE and STRING-AFTER."
|
||||
(setq lines (split-string raw-table "\n" t))
|
||||
(apply 'delete-region (list beg end))
|
||||
(when org-export-table-remove-special-lines
|
||||
(setq lines (org-table-clean-before-export lines)))
|
||||
(setq lines (org-table-clean-before-export lines 'maybe-quoted)))
|
||||
;; make a formatting string to reflect aligment
|
||||
(setq olines lines)
|
||||
(while (and (not line-fmt) (setq line (pop olines)))
|
||||
|
Loading…
Reference in New Issue
Block a user