[Tex/LaTex] Wrapping text around figures in poster headerboxes

floatsposterswrapfigure

I am working on a poster with headerbox elements. In one of the boxes I try to have an image on the right side and have the text left of it. I tried different minipage and wrapfigure examples but the image ended up beeing all over the poster and not in the headerbox at the right position. :/

\headerbox{dataset}{name=dataset,column=1,span=2,row=0}{
\begin{wrapfigure}{l}{1in}
 \includegraphics[width=1in]{dataset} 
 \noindent 
 \hrulefill 
 \end{wrapfigure} 
 Lore ipsum
 \vspace{0.5em}
}

Best Answer

To place the wrap figure at the right , you have to use r not l. Another fact is that it should have enough text in the surrounding so as to wrap properly. If you want to force the placement **exactly here* you can use the capital R (or L, I, or O). Fot details see the documentation of wrapfigure. (texdoc wrapfig). Here is a complete MWE:

\documentclass{article}
\usepackage{graphicx,wrapfig,lipsum}
%------------------------------------------
\begin{document}
This is where the figure goes with text wrapping around it. There should be enough text around the wrapfigure so that it is warpped properly. 
%------------------------------------------
\begin{wrapfigure}{r}{6cm}
\includegraphics[width=6cm]{example-image-a}
\caption{A wrapped figure going nicely inside the text.}\label{wrap-fig:1}
\end{wrapfigure}
%------------------------------------------
\lipsum[3]
\par
Figure~\ref{wrap-fig:1} is a wrapped figure. \lipsum[4]
%------------------------------------------
\begin{wrapfigure}{R}{6cm}
\includegraphics[width=6cm]{example-image-a}
\caption{A wrapped figure going nicely inside the text.}\label{wrap-fig:1}
\end{wrapfigure}
%------------------------------------------
\lipsum[5]
%------------------------------------------
\end{document}

enter image description here

Related Question