[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 199d6 feature creep...



Mathematica introduced a lisp-like tag for handling "notebooks" that could
have cells that were formatted, collapsed, etc.

If the first form is a Notebook form, then it looks for cells in the list to
display and manipulate.  If it's just a list of s-expr, it loads in the file
(equiv. to a scheme source file) and allows you to handle it as appropriate.
The normal save option saves as a notebook, a special save option saves it
as normal source.

Sort of like,

;;;  Making this up, but stored in standard text format.
(Notebook
    (cell (contents ....) (evaluation ...)(expanded . #t))
    (cell (contents ...) (evaluation ...) (expanded . #f))
    ((cell-input-font . "Times-Roman))(cell-output-font . "Arial"))
)

That way, it always editable although you want to save as a non-notebook in
the usual situations.  If you save as normal source, it just saves the
"contents" part as you would expect.  Forgetting about XML for the moment,
the list form is great for this type of thing.  Doing these annotations in
comments is okay, but in Mme you can manipulate notebooks as objects, which
may be useful for some applications.

Mme saves the eval answer in the cell as well (in a sub-box) so you can see
the previous answer that was there from your previous session.  In Mme, you
can evaluate on a cell-by-cell basis as well.

I have always liked the Mathematica interaction model their "front-end"
provides.



----- Original Message -----
From: "Greg Pettyjohn" <GregP@bsquare.com>
To: <plt-scheme@fast.cs.utah.edu>
Sent: Wednesday, October 31, 2001 1:54 PM
Subject: RE: 199d6 feature creep...


> Noel wrote:
>
> > I share some of Greg's reservations.  Would it be
> > possible to save the configuration in comments,
> ...
>
> Hmm... Perhaps the solution is to distinguise between project data, i.e.
the
> Scheme code,
> and meta data, i.e. how it should be displayed.
>
> I've noticed that DrScheme maintains two files for your "project". One is
> the current code
> itself, the other is the previous version in a backup. My thought is that
> the backup file, could
> be used as a true "project file" and the main file be left pristine.
>
> When you open a file in DrScheme, the first thing it would do is look for
a
> meta file with the same first name (different extension) in the same
> directory.
> If none is found, then create a new default one and proceed.
> If it is found, then interpret it, applying the meta data to what is
> displayed in
> the edit pane.
>
> The meta file would contain such information as:
> 1. Backup information, i.e. how to do a revert.
> 2. Viewing data, e.g. which expressions should be collapsed.
> 3. Other stuff, such as which language level was in
> use when the file was last saved, what font was used, whether the
> window was split... it could go on and on, this is why it
> is called "feature creep". :-)
>