2

I have a large table that I want to put sideways. Also to fit it on one page I want to reduce the page margins. One solution to change the margins is to redefine them with \newgeometry (followed by \restoregeometry) as described here: change page borders for sidewaystable

\documentclass[usegeometry,DIV=10,headsepline,footsepline,captions=tableabove]{scrbook}
\usepackage{rotating}
\usepackage{tabu}
\usepackage{geometry}
\geometry{showframe}
\usepackage{blindtext}


\begin{document}
\chapter{Test}
\blindtext[9]

\newgeometry{margin=.9cm}
\begin{sidewaystable}
    \thispagestyle{empty}
    \caption{A Table}
    \begin{tabu} to \linewidth {|X|c|c|c|}
        \blindtext & sample & sample & sample \\
        \blindtext & sample & sample & sample \\
        \blindtext & sample & sample & sample \\
        \blindtext & sample & sample & sample \\
    \end{tabu}
\end{sidewaystable}

\restoregeometry

\blindtext[9]
\end{document}

However, that prevents the sidewaystable from floating. Is there any way to change the margins while still allowing the table to float?

  • Now I found this: tex.stackexchange.com/a/139846/33534 . Using a minipage that is larger than the page and then shifting it with hspace in this case works. However, it is hard to center this in the page. – Jonas Feb 6 '17 at 19:23
  • Just a guess without having tried it to compile: how about placing the \newgeometry within the sidewaystable? – Jan Feb 6 '17 at 20:12
  • yeah I tried that. It doesnt work. It messed the whole thing up. (some discussion on that here tex.stackexchange.com/q/222343/33534). It messes up the whole table – Jonas Feb 7 '17 at 10:08

Your Answer

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

Browse other questions tagged or ask your own question.