0

I am trying to flow a list around an image, I found the following example in the comment located at this question:

\documentclass{article}

\usepackage{calc} \usepackage{adjustbox} \usepackage{lipsum} \usepackage{wrapfig}

\begin{document}

\newlength{\strutheight} \settoheight{\strutheight}{\strut} \begin{enumerate} \item \lipsum[1] \item \begin{adjustbox}{valign=T,raise=\strutheight,minipage={\linewidth}} \begin{wrapfigure}{l}{0pt} \includegraphics[width=3cm]{example-image-a} \end{wrapfigure} \strut{}\lipsum[2] \end{adjustbox} \item \lipsum[1] \end{enumerate}

\end{document}

Although the image is embedded in one of the list items (and I wanted the image unbound to the list), the code in that question works in all the cases I have tested.

However, I would like to move the image from the left side to the right side, but I simply don't understand enough about the packages used.

I would be grateful for any direction.

enter image description here

Ritmo2k
  • 129

1 Answers1

0

Change the wrapfigure specification from l (for left) to r (for right).

\documentclass{article}

\usepackage{calc} \usepackage{adjustbox} \usepackage{lipsum} \usepackage{wrapfig}

\begin{document}

\newlength{\strutheight} \settoheight{\strutheight}{\strut} \begin{enumerate} \item \lipsum[1] \item \begin{adjustbox}{valign=T,raise=\strutheight,minipage={\linewidth}} \begin{wrapfigure}{r}{0pt} \includegraphics[width=3cm]{example-image-a} \end{wrapfigure} \strut{}\lipsum[2] \end{adjustbox} \item \lipsum[1] \end{enumerate}

\end{document}

Willie Wong
  • 24,733
  • 8
  • 74
  • 106