[texhax] HTML specials with '_' character
Toby Cubitt
tsc25 at cantab.net
Fri Feb 22 17:51:37 CET 2008
Oleg Katsitadze wrote:
> On Sun, Feb 17, 2008 at 08:27:54PM +0100, Michael M. Tung wrote:
> So, why use @ in macro names? That's the common trick to make
> "hidden" macros, which can't be called by the end user. For this to
> work, you have to temporarily change catcode of @ to 11 ("letter") so
> that you can use it to define your hidden macros (this is the part
> Reinhard omitted), and when you are done, change the catcode back to
> 12, to prevent users from calling hidden macros. Something like:
>
> \catcode`@=11
> \def\@mailto#1{...}
> <other definitions of (or calling the) hidden macros>
> \catcode`@=12
They probably don't exist in plain TeX, but maybe it's worth adding that
in LaTeX packages these specific catcode changes should always be
performed using the \makeatletter and \makeatother macros:
\makeatletter
\def\@mailto#1{...}
<other definitions of (or calling the) hidden macros>
\makeatother
Toby
More information about the texhax
mailing list