0

Why does the wrapfigure environment not allow for continuation of the sentence, but places white text above the figure instead? The picture is illustrating my problem.

enter image description here

By adding \fbox, I get the following result: enter image description here

Here is a MWE:

\documentclass[12pt,danish,a4paper]{article}
\usepackage{wrapfig}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
\usepackage{graphicx}
\usepackage{lipsum}
\begin{document}
\lipsum

    \begin{wrapfigure}[10]{r}{0.5\textwidth}
    \centering
    \caption{FunFun}
    \includegraphics[width=0.4\textwidth]{Side_product_Furan.jpg}
    \label{Carbenoid}
    \end{wrapfigure}
    \noindent
    \lipsum
\end{document}

Do you see that the second \lipsum dosn't follow the first?

8
  • Maybe it comes from white space at the top of the figure. You can check that inserting your figure in a \fbox.
    – Bernard
    Commented Jun 5, 2017 at 16:32
  • Where is that command supposed to go? Before or after \begin{wrapfigure} ? Commented Jun 5, 2017 at 16:37
  • After. If you use \includegraphics, it would be \fbox{\includegraphics{my graphic file}}.
    – Bernard
    Commented Jun 5, 2017 at 16:45
  • 2
    you haven't shown your code so that makes it very hard to guess what in the code is forcing a paragraph break, it looks like you are forcing a break after allowing but impossible to say Commented Jun 5, 2017 at 17:36
  • You CAN insert wrapfigure into the middle a a paragraph, but it has to be at a line break. Commented Jun 5, 2017 at 20:22

1 Answer 1

1

You have given no clues about your input, but it looks like you have the first form, with a paragraph break mid-sentence, and you want the second form without a paragraph break after "allowing"

enter image description here

\documentclass{article}

\usepackage{wrapfig}

\begin{document}

zzzzz zzzz zzz zzz zzz zz zzzzzz
zzzzz zzzz zzz zzz zzz zz zzzzzz
zzzzz zzzz 
character thus allowing

\begin{wrapfigure}{r}{.5\linewidth}
\centering
  \rule{3cm}{3cm}
\caption{Carbenoid of something}
\end{wrapfigure}
C-H into electron rich systems such as olefins and 
alkynes. Given the oribital discussion above, the
carbene would be expected to react in the singlet
state and therefore in a concerted fashion.

aa\\aa\\aa\\aa\\aa
aa\\aa\\aa\\aa\\aa

\bigskip


\begin{wrapfigure}{r}{.5\linewidth}
\centering
  \rule{3cm}{3cm}
\caption{Carbenoid of something}
\end{wrapfigure}
zzzzz zzzz zzz zzz zzz zz zzzzzz
zzzzz zzzz zzz zzz zzz zz zzzzzz
zzzzz zzzz 
character thus allowing
C-H into electron rich systems such as olefins and 
alkynes. Given the oribital discussion above, the
carbene would be expected to react in the singlet
state and therefore in a concerted fashion.

aa\\aa\\aa\\aa\\aa
aa\\aa\\aa\\aa\\aa

\end{document}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .