[XeTeX] Allowing Ucharcat to produce active characters

Joseph Wright joseph.wright at morningstar2.co.uk
Wed Apr 18 18:52:17 CEST 2018


On 18/04/2018 16:08, Bruno Le Floch wrote:
> Hello,
> 
> I suggest allowing \Ucharcat to produce active characters.  See
> three-line patch attached.  This would allow to produce active
> characters expandably in all engines (pdfTeX, luaTeX, XeTeX, pTeX,
> upTeX).  My code makes
> 
>      \Ucharcat `~ 13
>      \expandafter\show\Ucharcat `~ 13
>      \edef\foo{\expandafter\noexpand\Ucharcat `~ 13 }
> 
> run the code of the active ~ as if it had been typed directly, then show
> its meaning, then do the equivalent of \def\foo{~}.
> 
> Bruno

In case anyone wonders: only XeTeX has \Ucharcat. In LuaTeX we can make 
char tokens from the 'Lua side', so are unrestricted in terms of 
catcode. In pdfTeX and (u)pTeX, assuming we are only dealing with the 
8-bit range (upTeX) it's feasible to pre-generate all combinations and 
use expandable macros to output the tokens.

Joseph



More information about the XeTeX mailing list