[plt-scheme] should .scm's be text-only?

From: George Herson (gherson at snet.net)
Date: Mon Dec 25 20:31:01 EST 2006

--- Eli Barzilay <eli at barzilay.org> wrote:
> On Dec 24, George Herson wrote:
> > [...]
> > As written by DrScheme to file as text:
> > 
> > ;«Insert-Fraction
> > (+ 3 (/ 4 5))
> > ;»
> > ;«Insert-Comment-Box
> > ;(display "This line is commented out and in
> DrScheme 
> > ; appears in a proper comment box.") 
> > ;»
> > [...]
> This is better than trying to force s-expressions
> into something that
> is used as both the actual language and the encoding
> of binary objects
> (context: this is from previous discussion). 

Agreed.  There's no reason not to make the distinction
clear, and this new way allows analogs to the DrScheme
special objects to work in non-DrScheme Schemes.

> However, it is still
> suffering from issues: the resulting file is no
> longer read/editable
> by plain tools -- for example, the text will be
> sensitive to
> indentation, 

No, there's no sensitivity to indentation.  Just the
lines starting flush left with ;« and ;» will be
imbued with special meaning and shouldn't be edited
except by DrScheme.  The issue of having machine-added
lines in (configuration) files is commonly dealt with
by inserting a warning at top of file to not edit.  In
this case, the file itself is editable in any plain
text editor, it's just those particular lines that
shouldn't be hand-edited (unless you know what you're

> you need to remember that the newline
> after the ;» marker
> is important, 

again, the user will be warned to leave those lines
alone. No big deal, i think.

> you will need some other solution for
> font information
> (otherwise the text is going to all be made of these
> things).  

I didn't see any way to enter font info in DrScheme. 
Pls explain?

> Also,
> you're trying to find some way that can textualize
> all of these
> objects, but they can come from arbitrary snip
> implementations that
> can have no meaningful textual representation.  Oh
> and don't forget --
> you will need to make sure that the solution works
> fine for Java files
> and generic text files.

what is meant by snip implementations?  what issues 
might arise re: Java files and generic text files?  
i'll be happy to try to address them...  I'll address
all i can but I haven't your knowledge of the issues,
which is necessary to take this further.  Perhaps we
should take the discussion off-list again until i (we)
have something presentable?

(small correction:  to my original post yesterday:  we
can't display an image's alternate text (because with
the image's url as the only info given, that's all
that can be shown).)

George Herson

Posted on the users mailing list.