# Pagefilling pictures resulting in blank page before the next chapter

I've got a question in regards to pictures and chapters. It happened a few times now to me (like in the example below) that I have 1 or 2 pictures that fill up a page that suddenly the chapter following the picutre is not on the next page but one page after the next page (resulting in it being this order: Picture, Empty page, Chapter).

Now what would interest me is why is there time and again (example is below for one such occurance) this situation the case and what can I do to avoid this?

\documentclass[11pt,a4paper,BCOR10mm,DIV11,toc=listof,parskip=full]{scrbook}
\usepackage{etoolbox}
\makeatletter
\renewcommand{\chapterheadstartvskip}{\vspace{0pt}}
\renewcommand{\chapterheadendvskip}{\vspace{\baselineskip}}
\patchcmd{\section}{-3.5ex \@plus -1ex \@minus -.2ex}{-\z@}{}{}
\patchcmd{\section}{2.3ex \@plus .2ex}{1sp}{}{}
\patchcmd{\subsection}{-3.25ex\@plus -1ex \@minus -.2ex}{-\z@}{}{}
\patchcmd{\subsection}{1.5ex \@plus .2ex}{1sp}{}{}
\patchcmd{\subsubsection}{-3.25ex\@plus -1ex \@minus -.2ex}{-\z@}{}{}
\patchcmd{\subsubsection}{1.5ex \@plus .2ex}{1sp}{}{}
\patchcmd{\@xsect}{\ignorespaces}{\vspace*{-.5\baselineskip}\ignorespaces}{}{}
\makeatother

\usepackage[english]{babel}
\usepackage[utf8x]{inputenc}
\usepackage{amsmath}
\usepackage{graphicx}
\usepackage{booktabs}
\usepackage{multicol}
\usepackage[usenames,svgnames, dvipsnames]{xcolor}

\usepackage{hyperref}
\begin{document}
\twocolumn
\raggedright
\null\vfill
\hspace*{-3cm}\includegraphics[width=\paperwidth]{chart_part1.jpg}
\hspace*{-3cm}\includegraphics[width=\paperwidth]{chart_part2.jpg}
\vfill\null
\chapter{Forms of the dragons}
Test1
\end{document}


As note: The pics are not tall enough to fill the entire page so thhey are centered on the page without filling it completely.

Edit:trying out Werners answer I still have the prob with teh 2 pics. 1 blank page in between the pics and the chapter.

 \clearpage
\mbox{}% Just to put something on the page
\AddToShipoutPictureFG*{%
\AtPageCenter{%
\begin{tabular}{@{}c@{}}
\makebox[0pt]{\includegraphics[width=\paperwidth]{chart_part1.jpg}} \\
\makebox[0pt]{\includegraphics[width=\paperwidth]{chart_part2.jpg}}
\end{tabular}%
}%
}
\clearpage
% \null\vfill
% \hspace*{-3cm}\includegraphics[width=\paperwidth]{chart_part1.jpg}
% \hspace*{-3cm}\includegraphics[width=\paperwidth]{chart_part2.jpg}
% \vfill\null
\chapter{Forms of the dragons}
Dragons despite being


tried to remove the 2nd clearpage but no effect there

• Perhaps you should find a better way of placing the images so that it doesn't affect the setting of the chapter. Instead of asking how to avoid something that is dependent on the content, what is it that you're after exactly in terms of the what the output should resemble?
– Werner
Jul 23 '14 at 21:10
• The output is planed so: I have 1 image (or int the case of the example above 2 images) on one page and then on the next page a chapter. The images must be enlarged so that they fill the page as good as possible (it is a resourcebook for an rpg so the fillergraphics are artistic imaginations about what the coming chapter is about,...). Jul 23 '14 at 21:12
• By default scrbook places the start of a chapter on an right-hand (odd-numbered) page. In this example, the pictures fall on page 1 and the chapter starts on page 3. If you want to allow chapters to start on a left-hand page, use the openany or oneside option to \documentclass. Or change scrbook to scrreprt.
– Dan
Jul 23 '14 at 21:34
• The combination of this comment (didnt see it from home this morning) and the answer below functioned nicely tnx! Jul 24 '14 at 15:49

## 1 Answer

I would use a different tactic that makes the images not interfere with the placement of the text: Place them in the foreground as an overlay using eso-pic.

\documentclass[11pt,a4paper,BCOR10mm,DIV11,toc=listof,parskip=full]{scrbook}

\usepackage{graphicx,eso-pic}

\begin{document}
Here is some regular text.

\clearpage

\mbox{}% Just to put something on the page
\AddToShipoutPictureFG*{%
\AtPageCenter{%
\begin{tabular}{@{}c@{}}
\makebox[0pt]{\includegraphics[width=\paperwidth]{example-image-a}} \\
\makebox[0pt]{\includegraphics[width=\paperwidth]{example-image-b}}
\end{tabular}%
}%
}
\clearpage

\chapter{Forms of the dragons}
Test1
\end{document}


The placement is made using \AddToShipoutPictureFG* so that it is placed in the ForeGround only on the current page (the starred version) \AtPageCenter.

• Which part does the center vertically there? (the atpagecenter?) Jul 24 '14 at 5:04
• @ThomasE.: Yes, \AtPageCenter places its contents at the page centre (vertically and horizontally). Using \makebox[0pt] makes a zero-width box and places its contents horizontally centred. Otherwise you'll end up with the images anchored on the left side. On the other hand, a tabular has a vertical centred anchor. So, while \AtPageCenter puts the contents in the middle of the page, tabular helps to keep vertically stacked content centred vertically, and \makebox[0pt] helps to keep horizontally wide things centred horizontally.
– Werner
Jul 24 '14 at 5:20
• hmmmmm with the 2 pics I still have a prob. wil lupdate the post (still 1 page in between pics and chapter Jul 24 '14 at 11:33
• @ThomasE.: Did you see Dan's comment about the default settings for scrbook?
– Werner
Jul 24 '14 at 14:13
• no just now saw it (at home I seemingly have a few probs with comments and even your answer not showing up time and again) tnx Jul 24 '14 at 14:26