org-e-ascii: Fix column width with cells containing an object not exported
* EXPERIMENTAL/org-e-ascii.el (org-e-ascii-table): width may be wrong when some object is removed from a cell during export
This commit is contained in:
parent
d426d0f030
commit
f07929f5f1
|
@ -1626,20 +1626,20 @@ CONTENTS is nil. INFO is a plist holding contextual information."
|
||||||
(alignment (plist-get table-info :alignment))
|
(alignment (plist-get table-info :alignment))
|
||||||
(clean-table (org-export-clean-table raw-table special-col-p))
|
(clean-table (org-export-clean-table raw-table special-col-p))
|
||||||
;; Change table into lisp, much like
|
;; Change table into lisp, much like
|
||||||
;; `org-table-to-lisp', being more careful about keeping
|
;; `org-table-to-lisp', though cells are parsed and
|
||||||
;; the exact length of cells, for alignment purpose.
|
;; transcoded along the way.
|
||||||
;; Cells are parsed and transcoded along the way.
|
|
||||||
(lisp-table
|
(lisp-table
|
||||||
(mapcar
|
(mapcar
|
||||||
(lambda (line)
|
(lambda (line)
|
||||||
(if (string-match org-table-hline-regexp line) 'hline
|
(if (string-match org-table-hline-regexp line) 'hline
|
||||||
(mapcar
|
(mapcar
|
||||||
(lambda (cell)
|
(lambda (cell)
|
||||||
|
(org-trim
|
||||||
(org-export-secondary-string
|
(org-export-secondary-string
|
||||||
(org-element-parse-secondary-string
|
(org-element-parse-secondary-string
|
||||||
cell
|
cell
|
||||||
(cdr (assq 'item org-element-string-restrictions)))
|
(cdr (assq 'item org-element-string-restrictions)))
|
||||||
'e-ascii info))
|
'e-ascii info)))
|
||||||
(org-split-string (org-trim line) "\\s-?|\\s-?"))))
|
(org-split-string (org-trim line) "\\s-?|\\s-?"))))
|
||||||
(org-split-string clean-table "[ \t]*\n[ \t]*")))
|
(org-split-string clean-table "[ \t]*\n[ \t]*")))
|
||||||
;; Compute real column widths.
|
;; Compute real column widths.
|
||||||
|
|
Loading…
Reference in New Issue