Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am looking for a two-column solution: The left column contains one table, the right column several tables. I was thinking of using parboxes as follows:

\parbox[t]{2cm}{\vspace{0pt}
\begin{tabular}{ccc}
x & x & x\\
x & x & x\\
x & x & x\\
x & x & x\\
x & x & x
\end{tabular}}
\hfill 
\parbox[t]{2cm}{\vspace{0pt}
\begin{tabular}{ccc}
x & x & x\\
x & x & x
\end{tabular}\\[1em]
\begin{tabular}{ccc}
x & x & x 
\end{tabular}}

But this creates a nasty space between whatever comes before the two columns. Without \vspace{0pt}, the two first tables in both columns are not top-aligned. I am looking for a top-aligned solution without the extra space before the two columns.

share|improve this question
    
I can't see the image. –  Gonzalo Medina Mar 21 '11 at 17:35
    
I'm able to see the image. Could you make a complete compilable example out of it, please. –  Martin Scharrer Mar 21 '11 at 17:44
    
Similar question: Help aligning tables. –  Martin Scharrer Mar 21 '11 at 17:48

1 Answer 1

up vote 3 down vote accepted

Suppress the \vspace{0pt} commands and use the optional argument to control the position of the tabulars:

\documentclass{article}

\begin{document}

text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text

\noindent\parbox[t]{2cm}{%
  \begin{tabular}[t]{ccc}
    x & x & x\\
    x & x & x\\
    x & x & x\\
    x & x & x\\
    x & x & x
  \end{tabular}
}\hfill
\parbox[t]{2cm}{%
  \begin{tabular}[t]{ccc}
    x & x & x\\
    x & x & x
  \end{tabular}\\[1em]
  \begin{tabular}{ccc}
    x & x & x 
  \end{tabular}
}

\end{document}

enter image description here

share|improve this answer
    
You can also use parent tabulars instead of \parbox like shown in Help aligning tables. Then you do not need to specify the width of the content. –  Martin Scharrer Mar 21 '11 at 17:50

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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