texmacs-dev
[Top][All Lists]
Advanced

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

[Texmacs-dev] Octave plugin


From: Andrea Gamba
Subject: [Texmacs-dev] Octave plugin
Date: Mon, 27 Apr 2009 21:41:13 +0200
User-agent: Thunderbird 2.0.0.21 (X11/20090318)

Dear Joris,

I am attaching here a minimal modification of

/usr/share/TeXmacs/plugins/octave/octave/tm-start.oct /usr/share/TeXmacs/plugins/octave/octave/.octaverc
/usr/share/TeXmacs/plugins/octave/octave/tm/tmrepl.m

which fixes the Octave plugin so that it can be used with the current Octave version (3.0). Do you think it can be applied?

Andrea





d=getenv("TEXMACS_PATH");
if (length(d) > 0)
        
addpath([d,"/plugins/octave/octave/tm"],[d,"/plugins/octave/octave/plot"],[d,"/plugins/octave/octave/polynomial"]);
        PS1("\\002channel:prompt\\005octave> \\005");
        PS2("\\002channel:prompt\\005> \\005");
        global TMSTRUCT=0;
        global TMCOLORS=["black"; "red"; "magenta"; "orange"; "green"; 
"blue";];         global TMCOLIDX=6;
%             gset terminal postscript eps enhanced color;
%             gset size 0.5,0.5;
        tmrepl
endif
d=getenv("TEXMACS_PATH");
if (length(d) > 0)
        
addpath([d,"/plugins/octave/octave/tm"],[d,"/plugins/octave/octave/plot"],[d,"/plugins/octave/octave/polynomial"]);
        PS1("\\002channel:prompt\\005octave> \\005");
        PS2("\\002channel:prompt\\005> \\005");
        global TMSTRUCT=0;
        global TMCOLORS=["black"; "red"; "magenta"; "orange"; "green"; 
"blue";];         global TMCOLIDX=6;
%             gset terminal postscript eps enhanced color;
%             gset size 0.5,0.5;
        tmrepl
endif
function tmrepl()
        prompt=sprintf("%cchannel:prompt%coctave> %c",2,5,5);
        r=input(prompt, "s");
        texmacsanswer="texmacs";
        while ( 1 )
                if r(length(r))!=";"
                        dispans=1;
                else
                        dispans=0;
                endif
                r=sprintf("%ctexmacs%c; %s;",39,39,r);
                texmacsanswer=eval(r,"tmlasterr");
                if dispans & isnewans(texmacsanswer)
                        tmdisp(texmacsanswer);
                endif
                r=input(prompt,'s');
        endwhile
endfunction

reply via email to

[Prev in Thread] Current Thread [Next in Thread]