I am trying to float a figure using wrapfigure
within an exam
document using minipage
. If I don't use a minipage
, then the exam questions do not wrap around the figure. When I use minipage
as in the example below, everything wraps, but if the minipage
(or the longer form with solutions included with \printanswers
) is longer than one page, then the typesetting runs off the bottom.
My simple question is this: what's the correct way to include figures in an exam
? My example questions
block follows:
\documentclass{exam}
\usepackage{amsmath}
\usepackage{graphics}
\usepackage{wrapfig}
\begin{document}
\begin{questions}
\begin{minipage}{\linewidth}
\begin{wrapfigure}{r}{9cm}
\includegraphics[width=8cm]{./20x20grid-axes.png}
\end{wrapfigure}
\question Answer all parts below:
\begin{parts}
\part[1] 1 + 1 = \answerline
\fullwidth{\begin{solution}\begin{align*} \boxed{ 2 } \end{align*}\end{solution}}
\part[1] 2 + 2 = \answerline
\fullwidth{\begin{solution}\begin{align*} \boxed{ 4 } \end{align*}\end{solution}}
\part[1] 3 + 3 = \answerline
\fullwidth{\begin{solution}\begin{align*} \boxed{ 6 } \end{align*}\end{solution}}
\end{parts}
\end{minipage}
\end{questions}
\end{document}