[texhax] pound-sterlings

Alex Scorpan scorpan at gmail.com
Fri Jun 23 07:32:48 CEST 2006


> If you are interested, see the .sty file attached that
> has a comment about the problem of getting braces in a
> verbatim-like context used for handling C-programs.

You'd be better off setting
	\def{[\lbrace]
	\def}[\rbrace]
rather than exiting-and-entering math mode as in
	\def{[$\string{$]
	\def}[$\string}$]
Similarly for other def's in your .sty, you should look up the long  
name of the char and use it.

This test works fine for me:

\begin{document}

\catcode`[=\catcode`{
\catcode`]=\catcode`}
\catcode`{=\active
\catcode`}=\active

\def{[\lbrace]
\def}[\rbrace]

\begin[document]

$$ \tt {aba} $$

\end[document]



More information about the texhax mailing list