2

I have a strange behavior of LaTeX inserting blank Pages between Sections. I have added very big Picturens (Data sheets) to the Appendix off my Dokument. I scaled / cropped them so they fit on a Page with my Section name above them. But now LaTeX inserts an empty Page between those two Sections.

Question: How can I remove this empty Page between the two Sections?

I think it's because the Pictures are 'to big' for a page, but everything I tried did not work.

I don't know why but if i remove the hyperref Package the empty Page disappiers.

Minimalexample

\documentclass{scrartcl}
\usepackage{graphicx}               % Packages to allow inclusion of graphics
\usepackage{hyperref}               % For creating hyperlinks in cross references - Links im Inhaltsverzeichnis

\begin{document}

\subsection{Anton Paar DSA48, Datenblatt}
\includegraphics[resolution=300]{AntonPaarDSA48}


\subsection{Hameg HM8118, Datenblatt}
\includegraphics[clip, trim=1.5cm 1.5cm 1.5cm 1.5cm, scale=0.85]{HamegHM8118}

\end{document}

Used Files:

https://drive.google.com/file/d/0ByihVf4G1hnBZ2JYalJzako5U1E/view?usp=sharing https://drive.google.com/file/d/0ByihVf4G1hnBdXdGTXhGNTRBQWM/view?usp=sharing

Picture of the Problem:

Picture of the empty Problem Page

List of things I tried

\resizebox{!}{\textwidth}{}

This resizes the Picture and removes the empty Page. But the picture is resizes very small and a very big portion of the page is now unused and empty.

I can't remember what else I tried in the last hour...

  • 1
    It sounds as if the bounding box for the picture is not correctly set in the image. One other thing to try is your first approach, but reduce the scale below 0.85 to see how much reduction is necessary to remove the blank page. The other thing to try is to set \fboxsep=-\fboxrule\relax and then put the \includegraphics inside an \fbox That will show the picture border perceived by LaTeX. – Steven B. Segletes May 13 '16 at 11:04
2

Here is a better MWE to test the basic spacing. If you trimmed your pdf to exactly the textheight minus subsection heading it will probably still generate an empty page. You can test around with the rule sizes below, .9\textheight gave me no empty pages. If you found a good value, adapt your \includegraphics with the optional height argument as shown below. If there is a difference between the behaviour with the rules and the includegraphics, then you can check the boxes of the pdf (but they are probably alright - you just have to find the right height for inclusion).

\documentclass{scrartcl}
\usepackage{graphicx}
\usepackage{hyperref}

\begin{document}
    \subsection{Anton Paar DSA48, Datenblatt}
    \rule{\linewidth}{0.9\textheight}
    % \includegraphics[height=.9\textheight]{}
    \subsection{Hameg HM8118, Datenblatt}
    \rule{\linewidth}{.9\textheight}
    % \includegraphics[height=.9\textheight]{}
\end{document}

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.