Requesting input on some possible low-level changes
Subject: Requesting input on some possible low-level changes
From: Andrey G. Grozin
Date: Wed, 3 Sep 2003 15:34:17 +0700 (NOVST)
Hello *,
On Tue, 2 Sep 2003, James Amundson wrote:
> 1) The ordinary command input at the (C1) prompt. This one is obvious.
1a) When the user writes a part of a statement after (C1) prompt
(no ; or $), Maxima waits for more input without any prompt at all.
It should issue some "continuation" prompt (I think this would be good
even for the text-mode Maxima).
> 2) Questions encountered during a calculation, e.g., "Is a positive,
> negative, or zero?" This one is pretty obvious, too.
>
> 3) Input from the info routines, e.g.,
>
> --------------------------------------------------
> (C3) ? ask
>
> 0: ASKEXP :(maxima.info)Definitions for Simplification.
> 1: ASKINTEGER :Definitions for Simplification.
> 2: ASKSIGN :Definitions for Simplification.
> Enter n, all, none, or multiple choices eg 1 3 :
> --------------------------------------------------
>
> 4) Other inputs under Maxima control, including the Maxima debugger. I'm
> not sure how many such routines there are. Anyone?
When writing the TeXmacs-Maxima interface, I tried to identify such
places. (C1) prompts, pos/neg/zero questions, entermatrix, and Maxima
debugger work. I could not find how to redefine the string printed by
info.
> 5) to_lisp() or ctrl-c send the user to the underlying Lisp's
> read-eval-print loop.
>
> 6) Lisp errors send the user to the underlying Lisp's debugger.
Yes, the Lisp debugger is useless for most Maxima users. It would be
better to print some error message and return to the main Maxima prompt.
My idea was to define a function (prompt "some string") and use it for
(C1), continuation-prompt when the previous line is not terminated by ; or
$, pos/neg/zero questions, entermatrix and similar cases, Maxima debugger.
Then it would be easy for an interface to redefine just this single
function (e.g., to insert some ctrl-chars before and after "some string").
But I have no idea how to deal with 5) and 6). This seems to depend on the
underlying Lisp.
Andrey Grozin