0

I have a large table (with many columns), so that I decide to set its width = \paperwidth. I tried the following:

\documentclass{article}
\usepackage{graphicx}

\begin{document}
    \begin{table}[htb]
        \caption{something}\label{t:something}
        \centering  
        \noindent\resizebox{\paperwidth}{!}
        {
        \begin{tabular}{ccc}
            1 & 2 & 3 \\
            4 & 5 & 6 
        \end{tabular}
        }
    \end{table}
\end{document}

The problem is, the table is shifted to the right (portion to the left is empty, whereas part of the table at right side is cropped). My question is, how to set it to center?

hola
  • 4,026
  • 3
  • 35
  • 72
  • See https://tex.stackexchange.com/questions/16582/center-figure-that-is-wider-than-textwidth Edit: or https://tex.stackexchange.com/questions/39435/how-can-i-center-a-too-wide-table – Torbjørn T. Sep 23 '18 at 10:01
  • Eventually, none of the solutions in the original question [https://tex.stackexchange.com/questions/16582/center-figure-that-is-wider-than-textwidth] solves the problem. Requesting to reopen the question – hola Sep 23 '18 at 10:12
  • Surely \makebox[\textwidth][c]{\resizebox{\paperwidth}{!}{ ... }} works? – Torbjørn T. Sep 23 '18 at 10:18
  • @TorbjørnT. Not really. I tried that before posting the question – hola Sep 23 '18 at 10:21
  • What exactly did you try? That works perfectly fine for me. Alternatively, did you try the adjustbox method in https://tex.stackexchange.com/a/39436/? Edit 2: working example on Overleaf: https://v2.overleaf.com/read/rcxgcnxrcdsv – Torbjørn T. Sep 23 '18 at 10:23
  • @TorbjørnT. I tried the same as in the Overleaf example (didn't work). I am using llncs document class -- possibly that creates the problem I think. – hola Sep 23 '18 at 10:47
  • Then edit your question with an example that demonstrates \makebox not working. (It works fine also with llncs for me on Overleaf, see the link above again.) – Torbjørn T. Sep 23 '18 at 10:53

0 Answers0