I have a list of figures that I show in the appendix page each of them is on a separate page. The figures are showing on the top part of the page. I would like to know if it would be possible to have the figures in the middle of the page so that the half bottom of the page doesn't look empty. Would this be possible to overleaf, please? Many Thanks
-
You could use [h] or [H] to place the float where you want it or [b] for it to be at the bottom. See https://www.overleaf.com/learn/latex/Positioning_of_Figures – Elad Den Aug 31 '20 at 14:56
-
5Does this answer your question? How to influence the position of float environments like figure and table in LaTeX? – Elad Den Aug 31 '20 at 14:56
-
The answer I would point in the referenced question would be to skip using floats and simply include the graphics where you want them. – Teepeemm Aug 31 '20 at 21:14
1 Answers
For this you can force floats to be in a page of floats using the p option only (i.e., \begin{figure}[p] ... \end{figure}) where the figures are automatically centred, but take in mind that the purpose of page floats is gather scattered floats in the text. If this happens (and it is undesired) you can prevent this with a \clearpage after the float. Example:
\documentclass{article}
\usepackage{float,url}
\usepackage{graphicx}
\def\exampleimage#1{\begin{figure}[p]
\centering \includegraphics[width=#1\textwidth]{example-image}
\caption{Example}
\end{figure}}
\begin{document}
Helo word
\exampleimage{} \newpage % \newpage works here only if the image is enough big!
\exampleimage{.3}\exampleimage{.3}\clearpage % two small figures centred
\exampleimage{.5}\clearpage % single centred image
\end{document}
If you want some text before and/or after the float, just use the option [h] and add \vfill between the text and the float, i.e.:
Some text
\vfill
\begin{figure}[h]
\centering \includegraphics[width=\textwidth]{example-image}
\caption{Example}
\end{figure}
\vfill
Some text
Note that this will centre the figure with respect the available blank space. If you want to centre the image with respect the page, whatever the amount of above\below text, one solution could be put both chunks of text in minipages of equal height.
- 80,769