[XeTeX] Setting a label within newcommand?

Karljurgen Feuerherm kfeuerherm at wlu.ca
Fri Sep 25 14:29:18 CEST 2009


Thank-you, I will try this.
 
K

>>> Andy Lin <kiryen at gmail.com> 25/09/2009 1:05 am >>>
I originally wrote the below code for automatically labelling examples
(don't know why I wanted that functionality, since it would break if I
ever rearranged the examples). I'm not sure why it works, but it does:
\theALabel is just a counter
\newcommand{\AutoLabel}[1]{\ifthenelse{\equal{#1}{}}{\label{\theALabel}}{\label{\theALabel}\label{#1}}}

-Andy

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/xetex/attachments/20090925/f6c128c9/attachment.html>


More information about the XeTeX mailing list