scipad - Embedded Scilab text editor
Scipad is an embedded Scilab text editor written in TCL/TK. It can be started with the "Editor" button on top of the main Scilab window, or from Scilab command line with the instruction scipad() or scipad f .
The same invocation adds further files to an already opened scipad session. Scipad allows Windows like edition modes. Keyboard shortcuts are defined for most possible editing actions and reported by the menu entries.
Additionally, the following shortcuts are defined:
<F2> | Save file |
<F5> | Save file and run it into Scilab |
<F6>, <Control-F6> | Show next buffer |
<F7>, <Control-F7> | Show previous buffer |
<double-click mouse-button1> | Select word |
<triple-click mouse-button1> | Select line |
<Shift-Control-mouse-button1> | Open the source of the library function under the pointer |
<mouse-button2> | Paste selection |
<mouse-button3> | Popup edit menu, or debug menu if clicked during a debug session |
<Shift-mouse-button3> | Popup Execute menu |
<Control-mouse-button3> | Popup Options menu |
<Control-plus> | Increase the font size |
<Control-minus> | Decrease the font size |
<double-button1> on a tile title | Maximize this tile |
<double-button1> on a sash | Space sashes evenly (for this paned window) |
<button2> on a tile title | Switch hidden files |
The "Load Into Scilab" (Ctrl-lowercase-l) menu entry can be used to exec the file content into Scilab, while "Execute selection" (Ctrl-lowercase-y) passes the selected lines to the scilab shell using ScilabEval (i.e. execstr ).
Scipad 2.0 or later includes a debugger (for .sci files only). The user can:
At this point there are several possibilities for the user:
At any time during the debug, a watch window can be displayed on user request. It allows to monitor any variable value, or change a variable value during a breakpoint stop and relaunch execution with the modified value. The watch window also displays the calling stack.
After the end of the execution, the breakpoints are removed from Scilab (but kept in Scipad).
In its current development state the debugger works well with functions, i.e. pure .sci files. Support of .sce files or mixed .sce/.sci files has been foreseen but not yet implemented. That means that a .sce file will not crash Scipad, which is the very least, but more, once a feasible solution for debugging this type of files is figured out, it should be easy to add the functionality in the Scipad source code. Anyway, if actually a debug is required in a .sce, you should first convert it into a .sci function just by adding (output_vars)=function foo(input_vars) / endfunction and that's it. The absence of breakpoints management for .sce is therefore not such a major drawback.
Dragging one or more files from an explorer and dropping to Scipad will open the file(s) in Scipad. Doing the same with a directory will open recursively all the directory contents (beware!)
For text selected within the Scipad window, the possible actions are move (just use mouse button-1) and copy (Control button-1). Text selections can be moved or copied also between different Scipad subpanes, when tiling is active.
Drag and drop capabilities in Scipad rely on the TkDnD package (http://sourceforge.net/projects/tkdnd). Presence of this package should be automatically detected by Scipad, enabling the corresponding features at that time. Windows and linux-i386 binary versions of Scilab are currently shipped with Tkdnd. If not, here are some installation instructions:
Windows platforms: Download the full package (currently tkdnd-1.0a2.tar.gz), and uncompress it somewhere. Copy the content of lib\tkdnd and paste it into SCI\tcl\tk8.4\tkdnd. That's all!
linux-i386 platforms: Download the rpm package (currently tkdnd-1.0-b2.i386.rpm). Install it with rpm -U (may have to force --nodeps if it doesn't recognize an existing tcl installation). If you have a source version of Scilab and an installation of tcl-tk, check where they are installed (e.g. /usr/share/) and move the newly created directory /usr/lib/tkdnd1.0/ to there. If you have a binary version of Scilab, move tkdnd1.0/ to SCI/tcl/, where the supplied tcl-tk binaries are.
scipad SCI/scilab.star
edit , manedit , edit_error ,