I added \n support to HSpeak the other day on Charbile's request, but
should have gone all the way and added multiline string constants.

I think I'll just go with """ to begin and end such a string

But I'm not sure how to handle indentation. Lots of languages have
multiline strings, but handle indentation and leading/trailing
newlines differently. Some have complex rules which never work in all
cases, and some parse the string verbatim. I've never seen a style I
was happy with, so was wondering where someone else thinks there IS a
One True Way.

I'm worried, of course, about scripts ending up looking like this:

script, foo, begin
 ...
       new textbox("""Mr. Miyagi:
There is a store down the street. Sells lots of stuff. Start there."""
                  , 4, align:center, align:bottom)
       wait for textbox
       new textbox("""Buck Star:
Yes sensai Danielsan.""", 4, align:center, align:bottom)
       wait for textbox
...

Whereas something like this might be nicer:

       new textbox("""
             Buck Star:
             Yes sensai Danielsan."""
                  , 4, align:center, align:bottom)
_______________________________________________
Ohrrpgce mailing list
[email protected]
http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org

Reply via email to