Bob Reynolds wrote:
> I can define the abbreviation fine, and I can use the \infull version
> of it fine, but I can't use the command version at all. Another
> example: \ATX12V. I've been working around it by defining both
> synonyms and a logo like \PSTwo which typesets like I want \PS/2 to
> typeset, but what is a more elegent way of doing this that doesn't
> involve definining two different commands? I don't know how to change
> catcodes, despite numerous failed attempts to do just that with
> commands like \unprotect \catcode`2=\@@letter \protect.

Changing the catcode of digits is a bad idea because you are likely
to run into problems elsewhere (like in section headings etc.). The
cleanest solution is to use a small dedicated macro to call the
abbreviated version with:

  \logo [PS/2] [Play School Halved]

  \unexpanded\def\abbr#1{\getvalue{#1}}

  \starttext
  \abbr{PS/2}
  \stoptext

That takes a bit more typing, but is much safer and will work regardless
of the current catcode values.

Best wishes,
Taco


___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

Reply via email to