Alexander Solovets wrote:
> 
> > BTW: I do not know how to express prescripts in Texmas so they
> > are currently not handled.
> 
> I'll look at the code. Making prescripts is quite easy -- lsup/lsub. I
> thin I've added them, perhaprs didn't cover all scripts cases.
> 
> And I was asking about axiom/fricas. What do I have to fix/improve in
> order to see "-texmacs" option in trunk?
> 

I want to know that it works as intended.  AFAICS in axiom/fricas
script tiny change of quoting should be enough.  But to test it one
needs to adjust code of fricas plugin -- I fetched your 'fricas-plugin.tgz'
but clearly it assumes initialization via '.fricas.input'.  I have
now working Texmacs and I hope to work out needed changes in next
days.  Of course if you provided updated version it would be
faster. 

BTW1: Compared to your version change may look trivial.  But
experience showed that such changes frequently introduce bugs.


BTW2: We probably should put (updated) content of 'fricas-plugin.tgz'
in 'contrib' subdirectory, so that somebody trying to use the interface
has all pieces handy.

BTW3: The change to axiom script probably should look like below,
but as I wrote this needs testing:

--- ../trunk.pp8/src/etc/axiom  2011-02-25 14:35:44.000000000 -0500
+++ etc/axiom   2011-03-01 14:02:40.000000000 -0500
@@ -66,6 +66,7 @@
 #echo "     [-clientprog fname]  use named program for spadclient"
 echo "     [-h]                 show usage"
 echo "     [-eval code]         evaluate specified code at start"
+echo "     [-texmacs]           setup Fricas for communication in TeXmacs 
protocol"
 }
 
 # 1. Ensure the environment is set.
@@ -121,9 +122,18 @@
 rootwsdir=$SPAD/bin
 
 # 2. Process command line arguments.
+algebra_off=')set output algebra off'
+texmacs_on=')set output texmacs on'
+markers=")lisp (setf |\$ioHook| (lambda (x &optional args) (cond ((eq x 
'|startPrompt|) (princ (concat (code-char 2) \"prompt\#\") ))  ((eq x 
'|endOfTeXmacsOutput|) (princ (concat (code-char 5) (code-char 10)))) ((eq x 
'|startTeXmacsOutput|) (princ (code-char 2)))  ((eq x '|startKeyedMsg|)  (princ 
(concat (code-char 2) \"verbatim:\")))  ((eq x '|endOfKeyedMsg|)  (princ 
(code-char 5)))  ((eq x '|endOfPrompt|) (princ (code-char 5) ))  )))"
+
+
+if [ "$*" = "-texmacs" ] ; then
+    exec "$SPAD/bin/AXIOMsys" -- -eval "$algebra_off" -eval "$markers" -eval 
"$texmacs_on"
+fi
+
 
 if [ "$*" = "-nosman" ] ; then
-    exec $SPAD/bin/AXIOMsys
+    exec "$SPAD/bin/AXIOMsys"
     exit 1
 fi
 

-- 
                              Waldek Hebisch
[email protected] 

-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/fricas-devel?hl=en.

Reply via email to