Ah, thanks very much, using \protect fixed it.<br><br><div class="gmail_quote">On Sun, May 16, 2010 at 10:51 AM, Ulrike Fischer <span dir="ltr"><<a href="mailto:news3@nililand.de">news3@nililand.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Am Sat, 15 May 2010 23:20:12 -0400 schrieb Taylor Venable:<br>
<div class="im"><br>
> Hello, I just updated my TeXlive 2009 installation the other day from CTAN<br>
> and am having a problem with some shortcut macros I was using to make<br>
> indexing easier. I have a shortest working example attached as test.tex,<br>
> and the log file as well. I've summarised the things which can and can't be<br>
> changed in the test file. Essentially, if I have a \newcommand which<br>
> creates an index entry and specifies the output formatting of that entry,<br>
> while using Polyglossia, I get an error. The error is:<br>
><br>
> ! Missing control sequence inserted.<br>
> <inserted text><br>
> \inaccessible<br>
> l.7 \item {\ttfamily \def r<br>
> m{tt}lambda}, \hyperpage{1}<br>
><br>
> Which originates from the .ind file produced by makeindex. The error is<br>
> sort of an obvious problem: that \def should not be there! :-)<br>
<br>
</div>Polyglossia redefines \ttfamily, it adds \def\familytype{tt} to it -<br>
obviously to save the "type" of the font. \familytype is also<br>
redefined by \rmfamily and \sffamily.<br>
<br>
But now \ttfamily is no longer robust. You can avoid your problem<br>
with \protect:<br>
\newcommand{\broken}[1]{\index{#1@{\protect\ttfamily #1}}}<br>
<br>
But I think polyglossia should change its definitions and make the<br>
commands robust.<br>
<font color="#888888"><br>
--<br>
Ulrike Fischer<br>
<br>
<br>
<br>
--------------------------------------------------<br>
Subscriptions, Archive, and List information, etc.:<br>
<a href="http://tug.org/mailman/listinfo/xetex" target="_blank">http://tug.org/mailman/listinfo/xetex</a><br>
</font></blockquote></div><br><br clear="all"><br>-- <br>Taylor C. Venable<br><a href="http://metasyntax.net/">http://metasyntax.net/</a><br>