[Tex/LaTex] changing the position of a caption

captionsfloatspositioning

I have a code for putting a figure:

\begin{figure}
\includegraphics{some_narrow_and_tall_image.pdf}
\caption{caption of the figure which can be pretty long}
\end{figure}

The page format is single-column. Right now the caption appears below the image, as expected from this code. I would like to set it up so that the caption is on the right hand-side of the image. Is that possible?

Best Answer

You can use the floatrow package to do this.

\documentclass{article}
\usepackage[capbesideposition=right]{floatrow}
\begin{document}
\begin{figure}
\fcapside
  {\caption{A nice figure.}} 
  {\rule{4cm}{4cm}} %Replace with image
\end{figure}
\end{document}

Which yields:

enter image description here

Related Question