user manual

Chapter 6: Creating a Visualization 125
iTool Developer’s Guide Creating a New Visualization Type
Note
Always use keyword inheritance (the _EXTRA keyword) to pass keyword
parameters through to the superclass. See “Keyword Inheritance” (Chapter 5,
Application Programming) for details on IDLs keyword inheritance mechanism.
Standard Base Class
While you can create your new visualization class from any existing visualization
class, in many cases, visualization classes you create will be subclassed directly from
the base class IDLitVisualization:
IF (self->IDLitVisualization::Init(_EXTRA = _extra) EQ 0) $
THEN RETURN, 0
The IDLitVisualization class provides the base iTool functionality used in the
visualization classes created by ITT Visual Information Solutions. See “Subclassing
from the IDLitVisualization Class” on page 121 for details.
Return Value
If all of the routines and methods used in the Init method execute successfully, the
method should indicate successful initialization by returning 1. Other visualization
classes that subclass from your visualization class may check this return value, as
your routine should check the value returned by any superclass Init methods called.
Registering Parameters
Visualization types must register each data parameter used to create the visualization.
Data parameters are described in detail in Chapter 3, “Data Management”.
Register a parameter by calling the RegisterParameter method of the IDLitParameter
class:
self->RegisterParameter,
ParmameterName
, $
TYPES = ['
DataType1
', ..., '
DataTypeN
']
where ParameterName is a string that defines the name of the parameter and the
TYPES keyword is set equal to a string or array of strings specifying the iTool system
data types the parameter can represent. See “Registering Parameters” on page 61 for
additional details.
Registering Properties
Visualization types can register properties with the iTool. Registered properties show
up in the property sheet interface, and can be modified interactively by users. The
iTool property interface is described in detail in Chapter 4, “Property Management”.