Skip to content

Commit

Permalink
lisp/ox-latex.el: indentation, small refactor
Browse files Browse the repository at this point in the history
* lisp/ox-latex.el (org-latex-table-cell): indentation, parenthesis
convention, combining 2 `let' blocks.
  • Loading branch information
danielfleischer committed Jun 27, 2022
1 parent 9193cf6 commit 036939b
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions lisp/ox-latex.el
Original file line number Diff line number Diff line change
Expand Up @@ -3930,11 +3930,10 @@ This function assumes TABLE has `org' as its `:type' property and
"Transcode a TABLE-CELL element from Org to LaTeX.
CONTENTS is the cell contents. INFO is a plist used as
a communication channel."
(let (
(type (org-export-read-attribute :attr_latex (org-export-get-parent-table table-cell) :mode))
)
(concat
(let ((scientific-format (plist-get info :latex-table-scientific-notation)))
(let ((type (org-export-read-attribute
:attr_latex (org-export-get-parent-table table-cell) :mode))
(scientific-format (plist-get info :latex-table-scientific-notation)))
(concat
(if (and contents
scientific-format
(string-match orgtbl-exp-regexp contents))
Expand All @@ -3943,11 +3942,9 @@ a communication channel."
(format scientific-format
(match-string 1 contents)
(match-string 2 contents))
contents))
(when (org-export-get-next-element table-cell info)
(if (string= type "tabbing")
" \\> " " & ")
))))
contents)
(when (org-export-get-next-element table-cell info)
(if (string= type "tabbing") " \\> " " & ")))))


;;;; Table Row
Expand Down

0 comments on commit 036939b

Please sign in to comment.