[texhax] index entries in verbatim text?

Edsko de Vries edsko at edsko.net
Sat Oct 18 11:22:28 CEST 2008


Try the listings package. It allows to escape to tex from within the typeset listing, so you could do something like (untested:)

\begin{lstlisting}[escapechar=\%]
..
..
..
.. %\index{key}%
..
..
..
\end{lstlisting}

Edsko


More information about the texhax mailing list