user manual

Chapter 15: Creating a Custom iTool Widget Interface 335
iTool Developer’s Guide Overview of Creating an iTool Interface
Overview of Creating an iTool Interface
This section provides a brief outline of the steps necessary to create a custom iTool
interface. The topics introduced here are discussed in greater detail in later sections of
this chapter.
To create a custom iTool interface, you will do the following:
1. Create or Choose an iTool
2. Create the Widget Interface
3. Create Event Handlers
4. Create Callback Routines
5. Create a Cleanup Routine
6. Create an iTool User Interface Object
7. Create an iTool Launch Routine
Create or Choose an iTool
The interface you will create is the interface to an iTool. While you may choose to
create a new interface to an existing iTool, it is more likely that you will be creating
an interface to a custom iTool that you have defined. Even if you simply want to
insert an iTool draw window into an existing widget interface, you will probably
want to specify which of the standard iTool operations, menu items, and toolbars are
included — this means creating and registering a new iTool definition routine. See
Chapter 5, “Creating an iTool” for a complete description of the process of creating
your own iTool.
Create the Widget Interface
You will use traditional IDL widget programming techniques to create the interface
used by your iTool. iTool components such as menus, toolbars, status bars, and iTool
draw windows are encapsulated in a special set of compound widgets that you can
add to your interface just like other widgets.
Note
iTool compound widgets are not exactly like other compound widgets. They do not
generate widget events, and you cannot get or set their values using the
WIDGET_CONTROL routine.