6

How can I make a nested multicolumn table span all its underlying columns such that 1 2 3 do not look squashed together but are rather distributed equally over the 2 cells?

\begin{tabular}{ c c }
  something long & here too \\
  \multicolumn{2}{c}{\begin{tabular}{ l c r } 1 2 3\end{tabular}} \\
\end{tabular}
6

You could simply insert \hfill for stretching:

\begin{tabular}{ c c }
  something long & here too \\
  \multicolumn{2}{c}{1 \hfill 2 \hfill 3} \\
\end{tabular}

table

or use it also at beginning and end, if necessary use \hspace*{\fill} instead:

\begin{tabular}{ c c }
  something long & here too \\
  \multicolumn{2}{c}{\hfill 1\hfill 2\hfill 3\hspace*{\fill}} \\
\end{tabular}

table

If you really wish to nest tables, you could use tabularx inside with X columns. For this you would need to know the cell width.

  • And how can one know the cell width? – leo Apr 2 '12 at 23:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.