Using the SYSGUI Device
The purpose of the SYSGUI device is to facilitate the creation and manipulation
of custom graphical windows from a Visual PRO/5 program. To use SYSGUI
device, do the following:
-
Add an alias line like the following to config.bbx:
ALIAS X0 SYSGUI
Any alias starting with X may be used, but there is no advantage to using other than X0, which is provided by default when Visual PRO/5 is installed. Note that the installation process should add this line to the config.bbx file.
-
Open X0 and start interacting with it. Multiple windows, controls, etc. may be created and destroyed without closing or reopening X0.
Multiple SYSGUI Opens
It is permissible for an application to have more than one channel open to the SYSGUI device. However, the current context, scaling, units, and the like, are all global parameters. Changing these on one SYSGUI channel immediately affects the behavior of all SYSGUI channels. Additionally, there is only one event queue and one input stream. For example, theoretically 'LISTADD'(101,-1,10) can be sent to one SYSGUI channel, then send the ten items to the other.
When the last channel to SYSGUI is closed, all SYSGUI windows and all of their contents are destroyed automatically.
Querying the SYSGUI Device
At any time, the CTRL() function may be used to get information about the current state of the SYSGUI device, including current context, contents of controls, and the like.
FIN(chan) also returns useful information including current context, number of active contexts, and first available context. Get the TMPL(chan,IND=0) to see the template. For more information, see FIN() function.