If a picture doesn't fit on a page, it's printed one the following page, while it's heading (in my case just the exercise number) is printed on the page before.
Is it possible to print the heading and the picture on the same page?
MWE
\documentclass[12pt, a4paper, parskip=full]{scrbook}
\usepackage{exsheets}
\DeclareInstance{exsheets-heading}{hugeIndent}{default}{
runin = true,
attach = {main[r,vc]number[l,vc](-3em,0pt)}
}
\SetupExSheets{
headings=hugeIndent,
question/pre-hook=\begin{addmargin}[3em]{0cm},
question/post-hook=\end{addmargin},
solution/pre-hook=\begin{addmargin}[3em]{0cm},
solution/post-hook=\end{addmargin},
counter-within={section},
counter-format=ch.se.qu[1]
}
\usepackage{tikz}
\usepackage[most]{tcolorbox}
\begin{document}
\part{EXCERCISES}
\chapter{Topic 1}
\section{Section}
\begin{question}[ID=111]
I'm an excercise.
\end{question}
\begin{solution}
\tcbsidebyside[
sidebyside adapt=left,
blanker,
sidebyside gap=0.5\baselineskip,
sidebyside align=top seam,
before skip=\dimexpr-\parskip-\baselineskip\relax
]
{
\begin{tikzpicture}[scale=\linewidth/20cm, baseline=(current bounding box.north)]
\draw[step=1,help lines,black!20] (-4.95,-3.45) grid (4.95,3.45);
\draw[thick] (-2.5,0) ellipse [x radius=2.25, y radius=3.4];
\draw[thick] (2.5,0) ellipse [x radius=2.25, y radius=3.4];
\end{tikzpicture}%
}
{
description
}
\end{solution}
\setcounter{chapter}{0}
\part{SOLUTIONS}
\chapter{Topic 1}
\section{Section}
\printsolutions[byID={111,111}]
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum.
\printsolutions[byID={111,111}]
\end{document}

before skipthere is a break point - you can see this if you delete thebefore skipline and the lorem ipsum text. – Andreas Schneider Jun 29 '16 at 07:51before skipoption and addnobeforeafter, box align=top– cgnieder Jun 29 '16 at 09:33before skipoption I don't know how to align the heading next to the picture. Related: How to align heading and tikzpicture – Andreas Schneider Jun 29 '16 at 09:42