1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-11-26 07:33:39 +00:00

org-e-latex: Fix table alignment for tables starting with a rule

* contrib/lisp/org-e-latex.el (org-e-latex-table--align-string): Fix
  table alignment for tables starting with a rule.
This commit is contained in:
Nicolas Goaziou 2012-05-06 20:10:21 +02:00
parent c2aac5f195
commit b5c0d7d2d1

View File

@ -2007,13 +2007,16 @@ a communication channel."
(let ((attr (mapconcat 'identity
(org-element-property :attr_latex table)
" ")))
(if (and attr (string-match "\\<align=\\(\\S-+\\)" attr))
(match-string 1 attr)
(if (string-match "\\<align=\\(\\S-+\\)" attr) (match-string 1 attr)
(let (alignment)
;; Extract column groups and alignment from first (non-rule)
;; row.
(org-element-map
(org-element-map table 'table-row 'identity info 'first-match)
(org-element-map
table 'table-row
(lambda (row)
(and (eq (org-element-property :type row) 'standard) row))
info 'first-match)
'table-cell
(lambda (cell)
(let ((borders (org-export-table-cell-borders cell info)))