[texhax] Trying to find the /right/ piece of LaTeX documentation.]

Peter Hutnick tex at hutnick.com
Fri Jul 9 19:16:49 CEST 2004

Mohamed HOUSSNI wrote:

> \newcommand{\placefig}[2]{
> \marginpar{
> \begin{minipage}[b][\textheight][s]{\marginparwidth}
> #1\par\vfill\par#2
> \end{minipage}
> }}
> This command support two floats without captions. And if you want add 
> caption, you have to define the following command in the preambule
> \makeatletter
> \def\@captype{Figure}
> \def\@captionof#1#2{{\def\@captype{#1}#2}}
> \makeatother
> NB. The whole syntaxe in the text looks like
> \placefig{\includegraphics[....]{...}
> \captionof{figure}{\caption{\label{...}legend's text}}}{...........}

Both of the chunks of code are in my preamble.  When I do:

\captionof{figure}{\caption{\label{1}The Plane.}}}
\rput(2,2){Quadrant I}
\rput(-2,2){Quadrant II}
\rput(-2,-2){Quadrant III}
\rput(2,-2){Quadrant IV}
%\caption{The Plane.}

LaTeX complains:

    ! Undefined control sequence.
    <argument> ... ][s]{\marginparwidth }  \captionof
    {\label ...
    l.971 \begin

What am I doing wrong?


More information about the texhax mailing list