ox-latex: Fix user-defined align string in matrices
* lisp/ox-latex.el (org-latex--align-string): Change signature. Center all cells in matrices, yet preserve user-defined align string. (org-latex--math-table): Apply signature change. Reported-by: Phil Regier <phil.regier@gmail.com> <http://permalink.gmane.org/gmane.emacs.orgmode/112873>
This commit is contained in:
parent
4dde26f086
commit
7839fb891b
|
@ -3312,9 +3312,12 @@ This function assumes TABLE has `org' as its `:type' property and
|
|||
;; Environment. Also treat special cases.
|
||||
(cond ((member env '("array" "tabular"))
|
||||
;; Make sure cells are always centered while preserving
|
||||
;; vertical separators.
|
||||
(let ((align (replace-regexp-in-string
|
||||
"[lr]" "c" (org-latex--align-string table info))))
|
||||
;; vertical separators, unless user provided a special
|
||||
;; align string.
|
||||
(let ((align
|
||||
(or (org-export-read-attribute :attr_latex table :align)
|
||||
(replace-regexp-in-string
|
||||
"[lr]" "c" (org-latex--align-string table info)))))
|
||||
(format "\\begin{%s}{%s}\n%s\\end{%s}" env align contents env)))
|
||||
((assoc env org-latex-table-matrix-macros)
|
||||
(format "\\%s%s{\n%s}"
|
||||
|
|
Loading…
Reference in New Issue