I have a big figure that takes up a full page. I'd like to include it in my latex document on a separate page, centered horizontally and vertically.
I managed to put it on a separate page (or it is simply doing that because of the size). Horizontal centering also works using \centerline
, even though the figure is wider than the text.
The only problem left is that I can't center it vertically. No matter what I try it won't let me go over the top margin. I tried \vspace*{-2cm}
or ${}$\vspace*{-2cm}
, but only the caption was moved (onto the figure..).
My current code:
\begin{figure}[p]
\makebox[\linewidth]{
\includegraphics[width=1.3\linewidth]{images/sequence2.pdf}
}
\caption{Sequence diagram}
\end{figure}
EDIT:
Here is the result (I put a black border around the page, and covered the area of the figure with a gray box). The top margin is slightly larger than the bottom margin. And the figure's caption is below the page number. I'd just like to move the figure and caption up by 1-2 cm.
\centerline{...}
, does\makebox[\linewidth]{...}
provide a solution?\vspace*{1cm}
below\caption
to move the image upward1cm
.\vspace
at the end was simply ignored. However a negative\vspace
above the figure and\makebox
now work. Thanks for helping!