General ⇒ Tables with narrower margins
Tables with narrower margins
Hi,
I am writing my thesis using the book document class. I am quite pleased with the text's width, but I find it quite narrow for tables. Is there any way to for the table to start from the left sooner than the text?
I am writing my thesis using the book document class. I am quite pleased with the text's width, but I find it quite narrow for tables. Is there any way to for the table to start from the left sooner than the text?
NEW: TikZ book now 40% off at Amazon.com for a short time.

Tables with narrower margins
You can simply put a \hspace command with a negative length right before the tabular environment or, with the help of the @{} descriptor, in the tabular mandatory argument. For example,
or
Code: Select all
\hspace{-3cm}
\begin{tabular}{column descriptors}
(tabular stuff)
\end{tabular}
Code: Select all
\begin{tabular}{@{\hspace{-2cm}}column descriptors}
(tabular stuff)
\end{tabular}
The CTAN lion is an artwork by Duane Bibby. Courtesy of www.ctan.org.
- localghost
- Site Moderator
- Posts: 9202
- Joined: Fri Feb 02, 2007 12:06 pm
Tables with narrower margins
You can use a trick to get centered tables hanging into the margins on both sides.JoKo wrote:Hi,
I am writing my thesis using the book document class. I am quite pleased with the text's width, but I find it quite narrow for tables. Is there any way to for the table to start from the left sooner than the text?
Code: Select all
\begin{table}[!ht]
\makebox[\textwidth]{%
\begin{tabular}{*{15}{c}}
...
\end{tabular}
}
\caption{Table with excess width}\label{tab:widetab}
\end{table}
Best regards and welcome to the board
Thorsten¹
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10
Tables with narrower margins
Thanks a lot for your help. The first example didn't produce the expected results. The second one is producing the format I wanted except for the lines ( \toprule and \hline ). I would be also glad to know the function of @ .Juanjo wrote:You can simply put a \hspace command with a negative length right before the tabular environment or, with the help of the @{} descriptor, in the tabular mandatory argument. For example,orCode: Select all
\hspace{-3cm} \begin{tabular}{column descriptors} (tabular stuff) \end{tabular}
Code: Select all
\begin{tabular}{@{\hspace{-2cm}}column descriptors} (tabular stuff) \end{tabular}
At first, I was trying to do something similar using minipage and then the table inside. Unfortunately, neither of those methods produced the wanted result...localghost wrote:You can use a trick to get centered tables hanging into the margins on both sides.JoKo wrote:Hi,
I am writing my thesis using the book document class. I am quite pleased with the text's width, but I find it quite narrow for tables. Is there any way to for the table to start from the left sooner than the text?But I think this is a very poor result. You should think about increasing the text width with geometry. Tables that exactly fit the text width are produced with tabularx. The documentations will show you how to get things work.Code: Select all
\begin{table}[!ht] \makebox[\textwidth]{% \begin{tabular}{*{15}{c}} ... \end{tabular} } \caption{Table with excess width}\label{tab:widetab} \end{table}
Best regards and welcome to the board
Thorsten¹
Thanks for your hospitality!
JoKo
Tables with narrower margins
Hi,
as localghost has mentioned, the result is really poor (from a typographic standpoint). However, the changepage package provides an easy solution:
as localghost has mentioned, the result is really poor (from a typographic standpoint). However, the changepage package provides an easy solution:
Code: Select all
\documentclass{article}
\usepackage{changepage}
\usepackage{lipsum}%just to genearte some text
\begin{document}
\lipsum[1]
\begin{table}[!ht]
\begin{adjustwidth}{-2.4cm}{}
\begin{tabular}{*{14}{c}}
text & text & text & text & text & text & text & text & text & text & text & text & text & text
\end{tabular}
\caption{Table with excess width}\label{tab:widetab}
\end{adjustwidth}
\end{table}
\lipsum[1]
\end{document}
1,1,2,3,5,8,13,21,34,55,89,144,233,...
Re: Tables with narrower margins
Thanks a lot, gmedina!
This produces exactly the output I really wanted!
This produces exactly the output I really wanted!
-
- Posts: 3
- Joined: Wed May 16, 2012 9:58 am
Re: Tables with narrower margins
Thanks gmedina !
Working and looking great.
Amine
Working and looking great.
Amine