lvjr / tabularray

Typeset tabulars and arrays with LaTeX3
https://ctan.org/pkg/tabularray
247 stars 22 forks source link

Nested Tables are much slower to compile and have other issues. #376

Closed taylorh140 closed 1 year ago

taylorh140 commented 1 year ago

I noticed that once I complete a simple table (with static width) it takes noticeably longer to compile it within another tblr than say nesting in a tabular

I also found that under some conditions like a nested table spanning multiple rows, sometimes the table fails to be drawn altogether.

and it wouldn't be such a bummer except that this library is leaps and bounds easier to use than any others (nice job).

muzimuzhi commented 1 year ago

I also found that under some conditions like a nested table spanning multiple rows, sometimes the table fails to be drawn altogether.

concrete example?

taylorh140 commented 1 year ago

so below i have a 8 nested tables I hid them inside commands here.

the following works:

\begin{tblr}{width=\linewidth,colspec={X[c]X[c]X[c]},row{3}={font=\bfseries, bg=azure9}}
Connector 0 & \SetCell[c=2]{c}  AI Mux Configuration\\ 
\adjustbox{valign=t}{\ConTblA} & \SetCell[c=2]{c} {\MuxTblA \\ \MuxTblB \\ \MuxTblC \\ \MuxTblD} \\
Connector 1 & Connector 2 & Connector 3 \\
\ConTblB    & \ConTblC    & \ConTblD \\
\end{tblr} 

However when i try swapping positions of the four nested tables:

\begin{tblr}{width=\linewidth,colspec={X[c]X[c]X[c]},row{3}={font=\bfseries, bg=azure9}}
Connector 0 & \SetCell[c=2]{c}  AI Mux Configuration\\ 
\SetCell[c=2]{c} {\MuxTblA \\ \MuxTblB \\ \MuxTblC \\ \MuxTblD} & \adjustbox{valign=t}{\ConTblA} \\
Connector 1 & Connector 2 & Connector 3 \\
\ConTblB    & \ConTblC    & \ConTblD \\
\end{tblr} 

\ConTblA fails to render. It would take me a bit more time to get a mwe probably.

lvjr commented 1 year ago

You were missing an & after \SetCell[c=2]{c} {...} (see chapter 1 of the manual). For running speed, other issues exist.