Chapter 4 - Using the Rustogramer GUI
Rustogramer suplies a sample GUI that is based on the NSCLSpecTcl treegui with, what I think are, some improvements in how objects are creatd. The GUI is a sample of a REST client written in Python against the Python Rest API.
If the envirionment variable RUST_TOP is defined to point to the top installation directory of Rustogramer, you can run the gui as follows:
$RUST_TOP/bin/gui [--host rghost] [[--port rest_port] | [--service rest_service] [--service-user rg_user]]
The gui supports the following command options
--hostspecifies the host on which the rustogramer you want to control is running. This defaults tolocalhostif not specified.- One of two methods to specify the REST port that Rustogramer is using:
--portspecifies the numeric port on which Rustogramer's REST server is listening. This defaults to8000which is Rustogrammer's default REST port.- If rustogramer is using the NSCLDAQ port manager to advertise a service name:
--servicespecifies the name of service rustogramer is advertising.--service-userspecifies the name of the user that rustogramer is running under. This defaults to your login username and, in general, should not be used.
When connected to Rustogramer, the GUI will look like this:

Prior to describing each of the user interface elements let's look at a few features of this image.
- The menubar at the top of the window provides access to operations that are not as frequent as those available on the main window. Note that the contents of the menubar depends on the actual application the GUI is connectec to.
- The tabs below the menu-bar provide access to the sections of functionality of the GUI. Note that the set of tabs will, again, depend on the application the GUI is connected to. For example, Rustogramer does not have TreeVariable like functionality as that capability is pushed back onto the code that prepares data-sets. If connected to SpecTcl, however, a
Variablestab will be present. - Below the Tabs are controls for the things that Tab manages. In the figure above, the
Spectratab is selected and shows a tabbed notebook that allows you to create and edit the definitions of Spectra as well as a filtered list of spectra and their applications. More about this tab in the documentation the spectra tab - Note that the only thing the
Helpmenu provides is information about the program (theAboutmenu command).
For information about the contents of each tab:
- The
SpectraTab - The
ParametersTab - The
VariablesTab (SpecTcl only). - The
GateTab - The
BindSetsTab
For information about the Menus:
- The
FileMenu - The
Data SourceMenu - The
FiltersMenu (SpecTcl only). - The
SpectraMenu - The
GateMenu
The rustogramer GUI is now included in SpecTcl (as of version 7.0). To use it you'll need to setup the ReST server as described in the CutiePie documentation. You can then start the GUI from SpecTclRC.tcl
by adding the line:
exec python3 $SpecTclHome/pythontree/Gui.py --port $HTTPDPort &
towards the end of that file.