23 Dec
2010
23 Dec
'10
2:36 p.m.
On Thu, Dec 23, 2010 at 2:09 PM, Peter Münster
On Thu, Dec 23 2010, Mojca Miklavec wrote:
tex.print('\\hbox to 1.5em{\\hss %s \\hss}',
tex.print() does not handle the %s. context() does.
So just replace tex.print() by context(). Right, this also works
\starttext \startluacode function draw_table(unicode_start,n_columns) for i=0,0xF do tex.print('\\dontleavehmode\\definedfont[Serif at 20pt]\\kern0pt') for j=0,n_columns do context('\\hbox to 1.5em{\\hss %s \\hss}',unicode.utf8.char(unicode_start+i*16+j)) end tex.print('\\crlf') end end draw_table(0x00C0,4) \stopluacode \stoptext -- luigi