Previous Getting Started with IDL: Creating Interfaces with the IDL GUIBuilder Next

What is the IDL GUIBuilder?

The IDL GUIBuilder is part of the IDL Development Environment. GUI stands for Graphical User Interface; the IDL GUIBuilder supplies you with a way to interactively create user interfaces. You can then generate the IDL source code that defines that interface and contains the event-handling routine place holders that complete your interface.


Note
The IDL GUIBuilder is supported on Windows only. However, the code it generates is portable to other platforms and will run on the same version of IDL or higher.

The IDL GUIBuilder has several tools that simplify application development. These tools allow you to create the widgets that constitute user interfaces, define the behavior of those widgets, define menus, as well as create and edit color bitmaps for use in buttons.


Note
When using code generated by the IDL GUIBuilder on other non-Windows platforms, more consistent results are obtained by using a row or column layout for your bases instead of a bulletin board layout. By using a row or column layout, problems caused by differences in the default spacing and decorations (for example, beveling) of widgets on each platform can be avoided.

Using the IDL GUIBuilder

These are the basic steps you will follow when building an application interface using the IDL GUIBuilder:

  1. Interactively design and create a user interface using the components, or widgets, supplied in the IDL GUIBuilder. Widgets are simple graphical objects supported by IDL, such as sliders or buttons.
  2.  

  3. Set attribute properties for each widget. The attributes control the display, initial state, and behavior of the widget.
  4.  

  5. Set event properties for each widget. Each widget has a set of events to which it can respond. When you design and create an application, it is up to you to decide if and how a widget will respond to the events it can generate. The first step to having a widget respond to an event is to supply an event procedure name for that event.
  6.  

  7. Save the interface design to an IDL resource file, *.prc file, and generate the portable IDL source code files. There are two types of generated IDL source code: widget definition code (*.pro files) and event-handling code (*_eventcb.pro files).
  8.  

  9. Modify the generated *_eventcb.pro event-handling code file using the IDLDE, then compile and run the *.pro code. This code can run on any IDL-supported platform.

The *_eventcb.pro file contains place holders for all of the event procedures you defined for the widgets, and you complete the file by filling in the necessary event callback routines for each procedure.


Warning
Once you have generated the widget definition code (*.pro files), you should not modify this file manually. If you decide to change your interface definition, you will need to regenerate the interface code, and will therefore overwrite that *.pro file. The event handling code will not be overwritten but will instead be appended.

You can also create user interfaces programmatically in IDL without the GUIBuilder. Creating Widget Applications contains complete information about IDL widgets, and it describes this process.

  IDL Online Help (March 06, 2007)