I am looking for wrapping some text around part of a figure in the following way:
Lorem ipsum dolor sit amet, consectetur adipiscing elit.
Aenean quis mi ut elit interdum imperdiet quis non ante.
+---------------------------+ +-------------------------+
| | | |
| | | |
| | | |
+---------------------------+ +-------------------------|
(a) subfigure a (b) subfigure b
+------------------------+
Sed imperdiet, sapien quis | |
viverra rhoncus, tellus dui | |
dictum nisl, at porta purus | |
ipsum ac turpis. Fusce auctor | FIGURE |
ullamcorper adipiscing. Nunc | HERE |
non quam ac orci egestas con- | |
sequat ut eget quam. Cras +------------------------+
blandit condimentum ornare. (c) subfigure c
Curabitur aliquam, nulla sit
amet iaculis tristique, mi Figure 1: demo
nulla auctor magna, sit amet imperdiet ante arcu a libero.
The example here How to wrap text around a subfigure? has it only for equal-sized subfigures (which, I usually do simply by putting subfloat in my wrapfigure). Is there any way to do what I am suggesting. I am on Fedora 29 which has the texlive distribution. Thanks in advance for any suggestions or pointers.
The suggestion given works, but not for the subfig package (which uses subfloat that I thought was recommended over subfigure.)
Here is the example text:
\documentclass{article}
\usepackage{graphicx}
\usepackage{caption}
\usepackage{lipsum}
\usepackage{wrapfig}
\usepackage{verbatim,subfig}
\begin{document}
\lipsum[1]
\begin{figure}[h]\centering\ContinuedFloat*
\mbox{ \subfloat[]{\label{a}\includegraphics[draft,width=0.5\textwidth]{foo.png}}
\subfloat[]{\label{b}\includegraphics[draft,width=0.5\textwidth]{foo.png}}}
\end{figure}
\begin{wrapfigure}{r}{0.5\textwidth}\centering\ContinuedFloat
\subfloat[]{\label{c}\includegraphics[draft,width=0.5\textwidth]{foo.png}}
\caption{Demo}
\label{fig}
\end{wrapfigure}
\lipsum[2]
\end{document}
The counter deprecates every time ContinuedFloats in used.
I could perhaps add to the figure counter everytime continuedFloats is used but that does not seem kosher to me. I like clean solutions if available.
subfig
package (used in your question) and thesubcaption
package (used in the answer), see for example here: tex.stackexchange.com/a/13778/134144subfigure
, subfig` andsubcaption
. The first of them is deprecated. (The second one also introduces an environment calledsubfigure
).