[Logiweb] "Default" LaTeX rendering
Klaus Ebbe Grue
grue at diku.dk
Fri Jan 5 13:20:32 CET 2007
Hi Frederik,
> I looked up the construct Ded0( " , ") in the codex of the new check page,
> and I was surprised to see that there's no mention of any "tex aspect". In
> spite of this, LaTeX has no problems displaying the construct. How is this
> possible? Is there a "default" mechansim for rendering constructs using
> LaTeX?
Yes, there is a default: when no "tex aspect" is present, the tex
rendering is based on the "pyk aspect" as follows: Space characters in
the pyk aspect are converted to streacheable, linebreakable spaces,
characters with codes in the range 33-127 are converted into something
which tex can typeset (as an example, a left curly brace { is converted
into a \{ command sequence).
Unfortunately, unicodes above 127 are just converted to hex codes, so use
of e.g. Danish characters æ, ø, and å in pyk names give rise to
tex renderings that work but are not nice to read. To make constructs that
contain non-ascii in their pyk name look good, you can as usual define a
tex aspect for the construct. Or you can change from default to custom
rendering. It is not too easy to set up custom rendering. To see how,
download logiweb-0.1.2.tar.gz, do 'tar zxf logiweb-0.1.2.tar.gz' then cd
to logiweb-0.1.2/test/msg and look at 'renderer.pyk' and 'rendered.pyk'.
The 'renderer' page defines a custom renderer and both 'renderer' and
'rendered' use the custom renderer defined in 'renderer'.
Internally, Logiweb uses Unicode/UTF-8. All output from pyk is in
Unicode/UTF-8, but if you edit your pyk files in e.g. ISO-Latin1, then you
can tell pyk to convert it to Unicode/UTF-8 using the 'filter' option
(c.f. 'man pyk').
Cheers,
Klaus
More information about the Logiweb
mailing list