[lltx] \luanewcommand?

Khaled Hosny khaledhosny at eglug.org
Mon Jan 11 18:44:35 CET 2010


I think it'd be handy to have a \luanewcommand that is similar to
\newcommand but takes luacode instead of TeX macros, so one can do
something like:

\luanewcommand{\hello}[1]{tex.sprint("Hello #1")}

Instead of:
\newcommand{\hello}[1]{\directlua{tex.sprint("Hello #1")}}

This would make lua feel more integrated (and it may take care of spaces
and catcodes etc. so we can use lua comment char '--' etc.)

What do you think?

Regards,
 Khaled

P.S. I don't know enough TeX or LaTeX to dare doing it myself, I tried
looking at perltex.sty, but after few lines I closed the file and
started composing this message :)


-- 
 Khaled Hosny
 Arabic localiser and member of Arabeyes.org team
 Free font developer
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Digital signature
URL: <http://tug.org/pipermail/lualatex-dev/attachments/20100111/4790c5f9/attachment.bin>


More information about the lualatex-dev mailing list