[texhax] How to write straight accents in TeX (not LaTeX!)

Reinhard Kotucha reinhard.kotucha at web.de
Sat Sep 8 00:37:02 CEST 2007


Pablo Mayckon writes:
 > Having been using LaTeX for more than two years, I have now decided to learn
 > TeX. I've just finished chapter 6 of the TeXbook.
 > 
 > But I'm from Brazil and I need to use accents quite often. When I used LaTeX,
 > that wasn't a problem, 'cause all I needed to do was to write
 > "\usepackage[latin9]{inputenc}". But now I'm in TeX and, as I expected, it
 > doesn't know what "\usepackage" is.
 > [...]
 > P.S.: As I tried to indicate in the subject of this message, I would like to
 > type accents in a straightforward manner, that is, "á" and not "\'a".

\catcode`\á=13
\defá{\'a}
á
\bye

Since you have the texbook, I don't have to explain a lot.  Characters
of \catcode 13 are called active characters and behave like control
sequences.  The second line gives this control sequence a meaning.

Regards,
  Reinhard

-- 
----------------------------------------------------------------------------
Reinhard Kotucha			              Phone: +49-511-4592165
Marschnerstr. 25
D-30167 Hannover	                      mailto:reinhard.kotucha at web.de
----------------------------------------------------------------------------
Microsoft isn't the answer. Microsoft is the question, and the answer is NO.
----------------------------------------------------------------------------


More information about the texhax mailing list