Syntax: !tk scriptfile args ...This command will execute a tcl/tk script (see 15.15), contained in the file given as an argument. Command arguments can be referenced in the script using the standard argc, argv mechanism. The language syntax is provided in documentation supplied with tcl/tk, and is described in
Tcl and the Tk Toolkit, John K. Ousterhout, Addison-Wesley
Additional information can be found on the internet.
The scriptfile must have a .tcl or .tk extension, appropriate for the file contents. The tk language is a superset of tcl, containing a graphical interface. The files are executed differently: tk files are executed in an event loop and a default window will be created, and execution will continue until all created windows are destroyed. Tcl files are interpreted linearly, with no graphics.
The tcl/tk interface is not available under Microsoft Windows. This command will dynamically load the tcl/tk libraries, which must be installed. If the tcl/tk libraries are installed in the standard location (/usr/local/lib), the libraries should be found automatically. If these libraries are installed elsewhere, the following variables should be set to indicate the locations to Xic.
!set TclLibrary path_to_tcl
!set TkLibrary path_to_tk
The path_to... are the full paths to the dynamic libraries. These variables can be set in a .xicinit or .xicstart initialization file, or in the technology file.
An example tk script named ``tkdemo.tk'' is provided with the examples and can be used to set up and test the tk execution facility.