Ralf Hemmecke wrote:
> 
> Consider the output of
> 
> http://axiom-wiki.newsynthesis.org/SandboxOutputTest
> 
> (since this is FriCAS 1.2.3 that obviously does not contain my fix w.r.t
> the problem with printing "%", there is a problem with an unfinished
> \mbox -- never mind that)
> 
> But due to this error you see the actual latex that is generated.
> 
> I actually cannot say whether there are several bugs.
> 
> That message("\") gives "\ " instead of \verb#\# is certainly a bug, but
> interestingly I also get this wrong output with my patch.
> 
> That message("%pi") output \pi is something I don't know whether I
> really want that. Note that adding a space before or after %pi gives
> somehing totally different.
> 
> What *should* message actually return for these cases when turned into
> TexFormat?

'message' is intended to literaly output _printable_ text.  I
think that for unprintable text what appears in the output
should be considerd undefined.  Of course now w should define
printable.  For now I would say that letters and digits
are printable.  Algebra uses several punctuation charactes,
so we should also include them in printable subset.
White space is partially printable: at least TeXFormat
is allowed to change amount of whitespace.  Currently
'%' is unprintable.

Note that description of 'message' and 'string' is similar,
but IMO intent is quite different: 'string' should show
structure of string, that is charactes.  So for example
'string' if possible should print character codes in
place of charactes that can not be rendered on a device.
OTOH 'message' emits canned message to which formatting
rules apply.  In particular it means that embedded formatting
codes can have unexpected results.

We may try to add better escaping support in 'message'.
But what we can do now is limited by current structure
of OutputForm.  In particular when TeXFormat sees '%pi'
it is too late to distingish between mathematical 'pi'
and abuse of 'message'.  OTOH benefits from better
escaping in message are limited.


-- 
                              Waldek Hebisch
[email protected] 

-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/fricas-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to