25

How can i set the minimum width of a table? I want to have a series of tables that are all the same width?

22

I would use the tabularx package. An argument to the tabularx environment specifies the table width, X columns share the available space.

A simple example:

\usepackage{tabularx}

\begin{tabularx}{.8\textwidth}{lXXr}
left column & text & text & right column
\end{tabularx}

See also:

3
  • @user1709076 It's setting the table width depending on the text width, as 80% of the current text width. – Stefan Kottwitz Oct 19 '19 at 13:18
  • is there any way to set the width of the table in inches? – user1709076 Oct 19 '19 at 13:22
  • 1
    @user1709076 Sure, such as \begin{tabularx}{4in}{lXXr} – Stefan Kottwitz Oct 19 '19 at 13:27
11

Use a tabular* environment, with @{\extracolsep{\fill}}, as in

\begin{tabular*}{.5\linewidth}{@{\extracolsep{\fill}}ccc}
  One& Two& Three\\
  Four& Five& Six
\end{tabular*}

(where you replace .5\linewidth with something wide enough for all of the tables).

0

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.