# \paragraph does not appear where it should

until now I think I have searched the whole internet, but without finding an answer. I hope this question is not embarrassing.

I have the following Latex Code:

 \subsection{Benutzeroberfläche}

\subsubsection{Öffentliche Sicht}

\paragraph{Fallunbezogene Sichten}
\begin{center}
\begin{figure}[!hbt]
\centering
\includegraphics[width = \textwidth]{frontend-mockup/Web 1920 öffentlich – Alle Publikationen.pdf}
\caption{Ansicht aller Publikationen in der öffentlichen Sicht}
\label{fig:public-all-publications}
\end{figure}
\end{center}

\paragraph{F1a - F2a Suchen und Filtern}
\begin{figure}[!h]
\centering
\includegraphics[width = \textwidth]{frontend-mockup/Web 1920 öffentlich – Suche.pdf}
\caption{Suchen von Publikationen in der öffentlichen Sicht}
\label{fig:public-search}
\end{figure}

\begin{figure}[!h]
\centering
\includegraphics[width = \textwidth]{frontend-mockup/Web 1920 öffentlich – Alle Publikationen gefiltert.pdf}
\caption{Filtern aller Publikationen in der öffentlichen Sicht}
\label{fig:public-filter-all-publications}
\end{figure}

\begin{figure}[!h]
\centering
\includegraphics[width = \textwidth]{frontend-mockup/Web 1920 öffentlich – Suche gefiltert.pdf}
\caption{Filtern der Suche in der öffentlichen Sicht}
\label{fig:pulic-fitler-search}
\end{figure}

\paragraph{F3a BibTeX generieren}
...


But my problem is, that \paragraph isn't positioned where it should be. It should be (as is the order in the Latex Code):

1. \subsection{Benutzeroberfläche}
2. \subsubsection{Öffentliche Sicht}
3. \paragraph{Fallunbezogene Sichten}
4. Figure
5. Etc. You get the point...

But that is not happening. See:

And on the next page it only gets weirder: (Each paragraph in the red box should have content)

I am just frustrated at this point and would much appreciate your advice.

• Your concern here is more about the placement of the figures, not so much the \paragraphs. For that, add \usepackage{float} and use the [H] float specifier (see How to influence the position of float environments like figure and table in LaTeX?; duplicate). However, you may have to manually insert page breaks in order for the layout to match your requirements. – Werner Dec 17 '20 at 22:13
• don't pace center around figure. The \paragraph always appears where placed but you have surrounded the image with \begin{figure}..\end{figure} the only purpose of that environment is to allow the figure to be moved to help with page breaking. – David Carlisle Dec 17 '20 at 22:13
• The center around the figure was a desperate attempt to fix this... – Lukas Thiersch Dec 18 '20 at 9:37

The problem isn't figure placement but paragraph title placement!

Since \paragraph merges the title with the first line of the ensuing paragraph the title has to be held until the paragraph is seen, or something else forces it, like another poaragraph. In your case, you have no text at all between the paragraph titles (no "content"), so the \paragraph is delayed until after the figure.

You can fix this by using

\paragraph{F1a - F2a Suchen und Filtern}
\indent % start paragraph


Or use \mbox{} or ~ instead of \indent. The aim is to create some blank paragraph text.

You also have an error of \begin{center} ... \end{center} around your figures. Since you already use \centering inside the figure, just get rid of the center environment.

Since you don't want your images to float, don't use the figure environment. To nevertheless be able to add a caption to your images, you can use the \captionof command from the \caption package:

\documentclass{article}
\usepackage{caption}
\usepackage[demo]{graphicx} % remove the demo onption in your actual document

\begin{document}

\subsection{Benutzeroberfläche}

\subsubsection{Öffentliche Sicht}

\paragraph{Fallunbezogene Sichten}
\begin{center}
\includegraphics[width = \textwidth]{frontend-mockup/Web 1920 öffentlich – Alle Publikationen.pdf}
\captionof{figure}{Ansicht aller Publikationen in der öffentlichen Sicht}
\label{fig:public-all-publications}
\end{center}

\paragraph{F1a - F2a Suchen und Filtern}
\begin{center}
\includegraphics[width = \textwidth]{frontend-mockup/Web 1920 öffentlich – Suche.pdf}
\captionof{figure}{Suchen von Publikationen in der öffentlichen Sicht}
\label{fig:public-search}
\end{center}

\begin{center}
\includegraphics[width = \textwidth]{frontend-mockup/Web 1920 öffentlich – Alle Publikationen gefiltert.pdf}
\captionof{figure}{Filtern aller Publikationen in der öffentlichen Sicht}
\label{fig:public-filter-all-publications}
\end{center}

\begin{center}
\includegraphics[width = \textwidth]{frontend-mockup/Web 1920 öffentlich – Suche gefiltert.pdf}
\captionof{figure}{Filtern der Suche in der öffentlichen Sicht}
\label{fig:pulic-fitler-search}
\end{center}

\paragraph{F3a BibTeX generieren}

\end{document}

• You've made a change that will allow this to work, but you didn't explain it. The real problem is that \paragraph requires another argument. Just providing one (which you did by removing the figure environment} will get rid of the "misplacement" of the heading, but doesn't lead to understanding. – barbara beeton Jan 17 at 20:06