User Interface
This is the menu and toolbar in IDE. To read the short prompt of an icon in the toolbar simply move mouse and stay there for seconds.
File
(i)New item creates a new file. (ii)Open item opens an existing file. (iii)Save item saves a file. (iv)SaveAs item saves a file with a new name. (v)Close item closes a file.
(i)Print item prints file. (ii)Print Preview item shows the preview of the file. (iii)Page Setup item sets the print page. (iv)Recent file list shows a group of files. (v)Send item sends file through email.
Edit
(i)Undo item will undo the last operation. (ii)Cut item will cut a paragraph. (iii)Copy item will copy a paragraph. (iv)Paste item will paste content in the clipboard. (v)Paste special may paste an formatted document. (vi)Clear will clear a paragraph. (vii)Select All will select entire text.
(i)Find item finds a word in the script. (ii)Find Next try to find next word. (iii)Replace will replace the found word.
Insert
(i)Date and Time item help you insert a date/time from selected format. (ii)Object item insert an object into the script. You do not need to use it.
Format
There is no need to use this menu for Tcl script because no format on it.
(i)Font item sets the font of the script.(ii)Bullet Style item sets the bullet style. (iii)Paragraph item sets the attributes of the paragraph. (iv)Tabs item sets the tab stop position and size.
Help
Neatware MyrmecoX Website directs you to access the MyrmecoX documents on Neatware's website.
Build
This item execute current Tcl script with different defaults
First Group
(i)Run is the normal execution of Tcl/Tk script. You can also run this item simply by clicking the icon button on the right-most of toolbar.
(ii)Run with console launch a Tcl/Tk program with a console, so you can use gets/puts on standard input/output.
(iii)Run with debugger will launch the Tcl debugger, then you can use step in or over to execute Tcl script. Read more details about debugger in the help\tclpro\ folder.
Second Group
(i)Execute wish helps you launch standard wish shell. Unlike Run this item allows you run multiple Tcl scripts at the same time. So you can easily debug and test client/server applications with MyrmecoX IDE.
(ii)Execute expect allows you run Expect script. This expect version worked for Tcl 8.0 so you may not work with the other Tcl C++ extension upto 8.0 together. However, it works well for Expect 5.21.
(iii)Execute and browse will run current Tcl script and launch IE to browse the current file name with the postfix of .html. This is help to develop web applications with Snaml.
Third Group
(i)Compile will generate an .exe file for this Tcl script. You need to pre-install MyrmecoX Runtime to execute this executable program. After clicking the compile an .exe file has been generated in the current folder. Clicking the minus (-) block on the left file browser, the folder will be shrinked. Then click the plus (+) block again, the .exe file should be displayed. Double click the .exe file the program will be executed.
Important: To generate .exe file for any Tcl script, you need to add following line in front of the Tcl script
catch {package require myrmecox}
The trick to use the catch makes your Tcl script working for all Tcl core. In MyrmecoX sample codes we have not added this line of code to keep clarity.
Shell
(i)Tcl shell will run the default shell program set in the menu Setting/Configuration/General item. You can select your own shell and use this item. In the MyrmecoX Enterprise Edition, Neatware used this function to run MyrmecoX Runtime for Intanium 64-bit scripts. These Runtimes may be specially optimized for different platforms, so this advanced feature provides developers a method to test their mission critical programs finally.
(ii)MyrmecoX launch pad will start Launch Pad program then you can easily add, delete, and run a Tcl script.
(iii)Expect launch pad will start Launch Pad program for Expect then you can easily add, delete, and run an Expect script.
(iv)Starkit launch pad will start Ladunch Pad program for Starkit then you can easily add, delete, and run a .kit of Startkit.
Settings
1. Configuration
The setting property sheet is showed below
General
The Enable console check makes console show after Run.
The Shell path box allows you specify a Tcl shell path and executable program name with parameters. After clicking the Apply button you store this path as default. Then, you can run this Tcl shell along with the current script from the item "Tcl Shell" under the Build menu.
Checker
You can write current script name and *.tcl in the Input files box. Then, you can check the syntax of the script or all the tcl files in the current directory. Warning level drop-dwon box lets you select the warning level. Under the check box of Setting, Disable check disables the function of checker which is the default setting. Quiet check will display short message. Finally, Verbose check will display detail messages.
Debugger
There are GUI Debugger and Console Debugger in MyrmecoX IDE.
GUI Debugger allows you debug Tcl code with the source code. It is convenient to set breakpoints, step in/over the code, and watch the value of a variable. For more details please read the Debugger manual.
Click GUI Debugger Snaphot to have a breview.
Console Debugger is a small and fast debugger. Click Console Debugger Commands to get detail information.
Compiler
When you set the Enable check and fill the Output file name, after the execution of Run, MyrmecoX IDE will generate a .tbc Tcl Byte Code file. The default name is the current Tcl name with the .tbc postfix instead of the .tcl postfix. You can execute a .tbc file without exposure your source code.
Profiler
Enable profile allows you use profile to collect the statistics of the Tcl execution.
2. Edit keywords
Because Tcl has no reserved keywords, you can define your own keyword set. Tcl command has the format: command subcommand argument ... . A command may have no subcommand such as puts command. A command with subcommand can specify more operations, for example, file copy , file dirname, etc..
An argument could be var, option, and pair in the keyword editor.
var represents that the argument is a variable or an expression. For example, in the command [set v $e], the keyword is set, its variable v is set to (var Argument1 VARIABLE) and the e is set to (var Argument2 VALUE) in the field (Type Name Value) respectively.
option represents that the argument is optional. In the Tcl its syntax is ?option?. For example, the puts command has the syntax [puts ?-nonewline? ?channelid? str]. Its keyword is puts. Its options are set to (option OPTION [-nonewline]) and (option OPTION [CHANID]) in the field (Type Name Value) respectively.
pari represents that the argument is a name and value pair. In the Tcl its syntax is [-title value]. For example, [pack .x -padx 20 -pady 40] where -padx 20 is a name and value pair. Without this pair in a command, the name item has the default value.
Keyword editor completes keyword operations. You may add a keyword with a sub-keyword and a group of arguments, search a keyword, edit keyword's arguments and comment, or delete a keyword. The command keyword database is used to prompt keyword information.
The Keyword box allows a user input and edit a keyword. Subkeyword field is a combobox that allows you input a subkeyword or select a subkeyword from available list. The Comment box allows you to input or modify the description of a keyword and its subkeyword. The Argument field lists the arguments with form (Item#, Type, Name, Value). You may edit each item in its cells.
A group of buttons complete different operations. Reset button sets the editor to the initial state and clears all setting values. After you input a keyword and click Search button, Keyword editor will try to find the keyword along with its subkeyword and arguments. If a keyword has several subkeywords, clicking the Search button leaving subkey as empty, you may read the list of subkeywords by clicking on dropdown button. Then you can select one subkeyword and do search again to retrive exact arguments. Add button adds a keyword or a subkeyword and its arguments to the database. Delete button will delete a keyword and all its subkeywords. Close button closes the dialog box and save database to a default file named "_diction.dat".
3. Window list
It shows current opened file windows.