i have a problem with the spacing after a figure in my document. Here is the code i use:
\documentclass[twoside,open=right,12pt,a4paper,abstracton,BCOR=15mm,bibliography=totoc,toc=indentunnumbered]{scrreprt}
\usepackage{lettrine}
\usepackage{lmodern}
\usepackage{tocloft}
\usepackage{graphicx}
\usepackage{amsmath}
\usepackage{caption}
\usepackage{subcaption}
\usepackage[normalem]{ulem}
\makeatletter
\setlength{\@fptop}{0pt}
\setlength{\@fpbot}{0pt}
\makeatother
\begin{document}
some text
\par\rule{1pt}{.95\textheight}\par% needed to reproduce reported behavior
\noindent
some text that goes right till the end of the page
\begin{figure}
\centering
\captionsetup{labelfont=bf}
\includegraphics[]{example-image}
\caption{The figure appears on the top of the second page, which ist perfect.}\label{fig:FCC}
\end{figure}
\par\bigskip
\noindent
Some other text that appears on the third page although there is enough space below the figure/caption.
\end{document}
I described the problem in the sample code. I only have a limited number of pages for this report. I have checked with a ruler that there is enough space below the caption of the figure to put at least a little space and 6-7 lines of text. But somehow latex thinks different, so how can i convince it?
/edit1: Sorry, the \vspace below the caption ist not acually there (i copied it from another part of my document). And the negative \vspace does not work. The text either stays on the third page or it will be written across the figure which is of course not acceptable. It will just not start below the caption.
/edit2: If i use \begin{figure}[ht] the whole figure is shifted to the end of my document, which is also not acceptable. Another problem is that the "changes needed to reproduce the problem" are ruining the layout of my document and on top are not needed by me. I can totally reproduce the error with my original code. I try to show a picture of this part of my document to illustrate the problem. I also would upload the full working sample of my code, but it is awfully long due to the text. I have uploaded the files of the 3 page example here. Including the output file i get.
1cm
of space after the caption; that's part of the "extra space" after the figure -- get rid of it. you can shrink that space even further by specifying negative\vspace
where you now have the1cm
. you'll probably have to experiment to get the optimum spacing. it would also be a good idea to leave a blank line between input text and the figure code; figures are best input in vertical mode, between paragraphs.