emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug: org-element does not recognize table.el tables [9.4 (release_9.4-53-g23f941 @ /home/nick/elisp/org-mode/lisp/)]
@ 2020-12-17 21:12 Nick Dokos
  2020-12-20 17:15 ` Bastien
  2020-12-22 11:45 ` Nicolas Goaziou
  0 siblings, 2 replies; 9+ messages in thread
From: Nick Dokos @ 2020-12-17 21:12 UTC (permalink / raw)
  To: emacs-orgmode


Consider an Org mode file with a table.el table (which I made by
first constructing an Org mode table and then usind `C-c ~' to convert it):


--8<---------------cut here---------------start------------->8---
* table.el table


  +----+----+----+
  |  a |  b |  c |
  +----+----+----+
  |  1 |  2 |  3 |
  +----+----+----+
  |  4 |  5 |  6 |
  +----+----+----+
  |  7 |  8 |  9 |
  +----+----+----+
  | 10 | 11 | 12 |
  +----+----+----+
--8<---------------cut here---------------end--------------->8---

Trying to export to LaTeX produces pretty mangled output.

It turns out that when in
 `org-latex-table', (org-element-property :type table) returns `org', so
 it thinks it's an Org mode table and calls `org-latex--org-table' to
 process it, producing output like this:

--8<---------------cut here---------------start------------->8---
\sout{----}----\sout{----}
\begin{center}
\begin{tabular}{lll}
a & b & c\\
\end{tabular}
\end{center}
\sout{----}----\sout{----}
\begin{center}
\begin{tabular}{rrr}
1 & 2 & 3\\
\end{tabular}
\end{center}
\sout{----}----\sout{----}

...

\begin{center}
\begin{tabular}{rrr}
10 & 11 & 12\\
\end{tabular}
\end{center}
\sout{----}----\sout{----}
--8<---------------cut here---------------end--------------->8---


Evaluating `(org-element-at-point)' returns `(paragraph ...)' all along
the top line and `(table (.... :type org ....))' when the cursor is at
the beginning of the `a b c' line.


Emacs  : GNU Emacs 28.0.50 (build 3, x86_64-pc-linux-gnu, GTK+ Version 3.24.13, cairo version 1.16.0)
 of 2020-10-30
Package: Org mode version 9.4 (release_9.4-53-g23f941 @ /home/nick/elisp/org-mode/lisp/)

-- 
Nick




^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2021-01-04 21:27 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-12-17 21:12 Bug: org-element does not recognize table.el tables [9.4 (release_9.4-53-g23f941 @ /home/nick/elisp/org-mode/lisp/)] Nick Dokos
2020-12-20 17:15 ` Bastien
2020-12-21  7:49   ` Jean Louis
2020-12-21  9:12     ` Bastien
2020-12-21 21:10   ` Nick Dokos
2020-12-22  5:04     ` Tom Gillespie
2020-12-22 14:55   ` Nick Dokos
2020-12-22 11:45 ` Nicolas Goaziou
2021-01-04 21:26   ` Nick Dokos

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).