[luatex] % character in \directlua

Yannis Haralambous yannis.haralambous at telecom-bretagne.eu
Sat Feb 19 01:10:31 CET 2011


Hi everybody, and sorry for my mailer: it gives me only two choices, either "text" (my current choice, believe it or not) or "rtf".

I'm writing to ask whether there is a more elegant way to use a % in a \directlua argument (I need the Lua modulo operator)
besides changing the catcode of % to 12 around the \directlua command:

\begingroup
\catcode`\%=12
\directlua{texio.write(5 % 2)}
\endgroup

I have tried \%, \string%, nothing works besides the code above.

cheers

Yannis
-- 
-------------------------------------------------------
Yannis Haralambous
Directeur d'études
ADRESSE TEMPORAIRE :
University of Aizu
Aizu-Wakamatsu, Fukushima-ken  965-8580, Japon
ADRESSE PERMANENTE :
Institut Télécom, Télécom Bretagne
Département Informatique
UMR CNRS 3192 Lab-STICC
Technopôle Brest Iroise
CS 83818, 29238 Brest Cedex 3, France
Tel: +33 2 29 00 14 27
Fax: +33 2 29 00 12 82
Email: yannis.haralambous at telecom-bretagne.eu
Internet: http://omega.enstb.org/yannis
ICBM address: 48°21'31.57"N 4°34'16.76"W
Twitter: y_haralambous
-------------------------------------------------------
...pour distinguer l'extérieur d'un aquarium,
mieux vaut n'être pas poisson

...the ball I threw while playing in the park
has not yet reached the ground

Es gab eine Zeit, wo ich nur ungern über Schubert sprechen,
nur Nächtens den Bäumen und Sternen von ihm vorerzählen mögen.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: Yannis Haralambous.vcf
Type: text/directory
Size: 508 bytes
Desc: not available
URL: <http://tug.org/pipermail/luatex/attachments/20110219/d5ba2580/attachment.bin>
-------------- next part --------------



More information about the luatex mailing list