Scilab Reference Manual |
---|
ScilabEval — tcl instruction : Evaluate a string with scilab interpreter
o | str : tcl string character Contains the string to evaluate with the current scilab interpreter. |
This function must be called in a tcl/tk script executed from scilab. It allows to associate scilab actions to tcl/tk widgets (graphic objects). The string str is put in the scilab interpreter buffer which then evaluates it. This has in general no border effect in the tcl/tk interpreter.
//Create a Tcl script using ScilabEval tcl_script=['toplevel .w1' 'button .w1.b -text ""Click here to see a new Scilab Graphic Window""\' ' -command {ScilabEval ""xselect()""}' 'pack .w1.b '] mputl(tcl_script,TMPDIR+'/test.tcl') // Execute the tcl script TK_EvalFile(TMPDIR+'/test.tcl')
Bertrand Guiheneuf
<< gcf | TK_EvalFile >> |