[texhax] Caption to figure in margin -- gives "LaTeX Error: Not in outer par mode"

tom sgouros tomfool at as220.org
Wed Nov 22 16:39:51 CET 2006


Niall Mansfield <texhax at uit.co.uk> wrote:

> I want to put the caption to a figure in the margin (to save space,
> as vertical space is limited for reasons we don't have to go into).


Here's a non-general way to do this that works ok.  Perhaps you can take
this and generalize it by checking for odd and even pages.  If you're
using the memoir class, checking is easy, and memoir also has a way to
generate out-of-the-ordinary captions.

Others can probably tell you that there already exists a package to do
exactly this, but I don't know about any (yet).

 -tom




\documentclass{article}
\usepackage{graphicx}

\begin{document}

Now is the time for all good men to come to the aid of their party.
Now is the time for all good men to come to the aid of their party.
Now is the time for all good men to come to the aid of their party.
Now is the time for all good men to come to the aid of their party.


\begin{figure}[bht]
  \centering
  \hbox{\begin{minipage}[c]{0.8\textwidth}
      \includegraphics[width=0.8\textwidth]{dist.ps}
    \end{minipage}
    \begin{minipage}[c]{0.4\textwidth}
      Grade 11 reading proficency and
      district median income. With only a few exceptions, income is a
      very good predictor of  proficiency.
    \end{minipage}}
\end{figure}

Now is the time for all good men to come to the aid of their party.
Now is the time for all good men to come to the aid of their party.
Now is the time for all good men to come to the aid of their party.
Now is the time for all good men to come to the aid of their party.
Now is the time for all good men to come to the aid of their party.


\end{document}


-- 
 ------------------------
 tomfool at as220 dot org
 http://sgouros.com  
 http://whatcheer.net


More information about the texhax mailing list