[tex-eplain] \tocentry with `depth' argument, verbatim characters in index terms
Oleg Katsitadze
olegkat at gmail.com
Tue May 2 22:21:15 CEST 2006
Hi,
The changes are in CVS:
http://tug.org/eplain/src/eplain.tex
==========
Now, when you give an integer PART argument to
\writetocentry or \writenumberedtocentry, they write out to
the .toc file a line starting with \tocentry{PART}.
==========
All indexing macros now read their TERM and SUBTERM
arguments verbatim, so you can pass them any characters
(presumably inside some verbatim environment). A test file
with examples is available from
http://tug.org/eplain/src/test/indexvrb.tex
Some tricks are still needed with curly braces inside TERM
arguments and brackets inside (optional) SUBTERM arguments.
The brackets are easy -- just pass the TERM!SUBTERM string
as a {TERM} argument.
The difficult part are curly braces. I've added two
parameters, \idxargopen and \idxargclose, which contain the
characters which are used to delimit the TERM arguments. By
default they are `\{ and `\}, respectively. If you need
braces inside TERMs, set \idxargopen and \idxargclose to
something else, e.g.,
\def\idxargopen{`\<}
\def\idxargclose{`\>}
and then delimit TERM as <TERM> instead of {TERM}. This is
not yet documented but the test file I mention above has an
example at the end.
Since SEE and SEEALSO can also contain verbatim things, I've
added verbatim support to the \indexsee and \indexseealso
macros. There is a problem here, though, since `{' and `}'
can't be used in the arguments to \indexsee and
\indexseealso. The best solution here is probably to just
define macros which expand to verbatim `{' and `}' and use
them inside SEE and SEEALSO references.
==========
Finally, if anybody cares to check this out, there is a new
demo
http://tug.org/eplain/demo/lscommnt.tex
http://tug.org/eplain/demo/lscommnt.pdf
As always, any comments and suggestions are welcome.
Best,
Oleg
More information about the tex-eplain
mailing list