[texhax] captions and floats

Lars Madsen daleif at imf.au.dk
Tue Jun 6 17:39:45 CEST 2006


Tom Sgouros :

>
> Hello all:
>
> In hunting through the memoir class, learning about captions, I found
> this code:
>
> \let\@memoldcaption\caption
> \def\caption{\donemaincaptiontrue\@memoldcaption}
>

save the old \caption in \@memoldcaption, then define a new which will set
\donemaincaption to true at the cerybeginning


> \let\@memold at caption\@caption
> \long\def\@caption#1[#2]#3{%
>  \M at gettitle{#2}\@memold at caption{#1}[#2]{#3}}
>

again same thing, redefine the normal caption to get some extra code into 
it.

it is very simple when you look at the code.

>
> Can someone explain to me what kind of trickery is going on here?  These
> both look circular to me.
>
> Thanks,
>
> -tom
>
>
> -- 
> ------------------------
> tomfool at as220 dot org
> http://sgouros.com
> http://whatcheer.net
> _______________________________________________
> TeX FAQ: http://www.tex.ac.uk/faq
> Mailing list archives: http://tug.org/pipermail/texhax/
> More links: http://tug.org/begin.html
>
> Automated subscription management: http://tug.org/mailman/listinfo/texhax
> Human mailing list managers: postmaster at tug.org
>


/daleif

``You cannot help men permanently by doing for them
what they could and should do for themselves. ''
  -- Abraham Lincoln


More information about the texhax mailing list