public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
* Converting nested tables | Forbidden control sequence error
@ 2022-07-19 17:25 Richard Huntsinger
  0 siblings, 0 replies; only message in thread
From: Richard Huntsinger @ 2022-07-19 17:25 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 2127 bytes --]



Here below are codes for two latex tables (generated by pandoc with a lua 
filter).  The first table renders perfectly.  The second nested table 
throws an error.  Can you help diagnose the problem?

THE LUA FILTER:
function RawBlock (raw)
  if raw.format:match 'html' then
    return pandoc.read(raw.text, 'html').blocks
  end
end

THE ERROR MESSAGE:
Runaway argument?
\global \advance \c@LT@chunks \@ne \global \LT@rows \z@ \setbox \z@ \vbox 
\ETC.
! Forbidden control sequence found while scanning use of \LT@nofcols.
<inserted text>
\par
l.176 \begin{longtable}[]{@{}rrr@{}} 

TABLE 1:
\begin{longtable}[]{@{}rrr@{}}
\caption{This is a Caption}\tabularnewline
\toprule
a & b & c \\
\midrule
\endfirsthead
\toprule
a & b & c \\
\midrule
\endhead
1 & 10 & 100 \\
2 & 20 & 200 \\
3 & 30 & 300 \\
\bottomrule
\end{longtable} 

TABLE 2 (a table of 2 tables):
\begin{longtable}[]{@{}
  >{\raggedright\arraybackslash}p{(\columnwidth - 2\tabcolsep) * 
\real{0.5000}}
  >{\raggedright\arraybackslash}p{(\columnwidth - 2\tabcolsep) * 
\real{0.5000}}@{}}
\toprule
\endhead
\begin{minipage}[t]{\linewidth}\raggedright
\begin{longtable}[]{@{}rrr@{}}
\caption{\textbf{This is a Caption}}\tabularnewline
\toprule
a & b & c \\
\midrule
\endfirsthead
\toprule
a & b & c \\
\midrule
\endhead
1 & 10 & 100 \\
2 & 20 & 200 \\
3 & 30 & 300 \\
\bottomrule
\end{longtable}
\end{minipage} & \begin{minipage}[t]{\linewidth}\raggedright
\begin{longtable}[]{@{}rrr@{}}
\caption{\textbf{This is Another Caption}}\tabularnewline
\toprule
a & b & c \\
\midrule
\endfirsthead
\toprule
a & b & c \\
\midrule
\endhead
2 & 20 & 200 \\
4 & 40 & 400 \\
6 & 60 & 600 \\
\bottomrule
\end{longtable}
\end{minipage} \\
\bottomrule
\end{longtable}

 

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/6bde11a6-701b-4ceb-8664-0f7348bd4b4fn%40googlegroups.com.

[-- Attachment #1.2: Type: text/html, Size: 2880 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-07-19 17:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-19 17:25 Converting nested tables | Forbidden control sequence error Richard Huntsinger

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 NNTP newsgroup(s).