INFORMIX
Visionary User's Guide
Chapter 8: Adding Navigation Features to a Scene
Home Contents Index Master Index New Book

Creating Wormholes

A wormhole is a Visionary object that links two scenes. The source scene is where you place the Wormhole object; the destination scene is what the wormhole connects to.

A wormhole differs from a jump or a hyperlink in the following ways:

Figure 8-5 illustrates the concept of a wormhole.

Figure 8-5
Wormhole

A wormhole can be simple or parameterized:

Creating a Simple Wormhole

You can create a wormhole if you have already defined two scenes. When you insert a wormhole, a Wormhole object appears in the tree view of the Scenes panel. The Wormhole object displays the name of the destination scene in parentheses.

To insert a wormhole

    1. In the Scenes panel, double-click the source scene to open it in design mode.

    2. Choose Insert Primitive Wormhole to display the Wormhole Destination dialog box.

    3. Select the name of the destination scene from the Wormhole Destination list box.

    4. If you want to require your user to use the wormhole button on the Navigation toolbar to enter the wormhole, uncheck the Enter wormhole when clicked with the mouse check box.

    5. Click OK. A wormhole appears in the center of the Scene Editor display.

    In the Scenes panel, the Wormhole object displays the name of the destination scene in parentheses.

If you create a wormhole with the Enter wormhole when clicked with the mouse option, an event action is automatically created. For more information about event actions, see Chapter 9, "Adding Event Actions to a Scene."

Tip: You can also insert a wormhole by clicking it in the Graphics panel of the World Manager and then clicking the point in the Scene Editor where you want the wormhole to appear.

Creating a Parameterized Wormhole

To pass information from one scene to another when you go through a wormhole, you use scene parameters.

For example, if a source scene displays a scatter chart of automobile sales, you can define each point on the chart as a wormhole that leads to a destination scene displaying sales data for a particular manufacturer.

To create this example, you pass the manufacturer name as a parameter when you travel through the wormhole.

To create a parameterized wormhole using scene parameters

    1. Insert the destination scene into your world.

    Choose Insert Scene. If the destination scene already exists, open it by double-clicking the scene name in the Scenes panel.

    2. Add a scene parameter to the destination scene.

      a. Choose Insert Parameter to display the Parameter Properties dialog box.
      b. Enter the name and data type of the scene parameter.

    3. Insert the source scene into your world.

    Choose Insert Scene.

    4. Add a wormhole to the source scene.

      a. Double-click the source scene in the Scenes panel to make it active.
      b. Choose Insert Primitive Wormhole to display the Wormhole Destination dialog box.
      c. In the Wormhole Destination dialog box, select the destination scene from the list box.
      d. If you want to require your user to use the wormhole button on the Navigation toolbar to enter the wormhole, uncheck the Enter wormhole when clicked with the mouse check box.
      e. Click OK. A wormhole appears in the center of the Scene Editor display.

    5. Set the parameter value for the wormhole.

      a. In the Object Inspector, select the Wormhole.SceneParameter object and enter the parameter value.
      b. The parameter value can be a constant or another parameter name. If you insert a wormhole in a Data Element Editor, you can select data columns from the parameter bar.

    6. In the destination scene, link relevant object properties to the scene parameter.

    In the Object Inspector, select an object in the destination scene and type the scene parameter value in the relevant property cell.

When you switch to runtime mode in the Scene Editor and enter the wormhole, the object in the destination scene displays the current value you have set with the scene parameter.

If you create a wormhole with the Enter wormhole when clicked with the mouse option, an event action is automatically created. For more information about event actions, see Chapter 9, "Adding Event Actions to a Scene."

Tip: A good way to create an overview scene is to use wormholes to show a single destination scene multiple times, with different parameters governing the data in the display.




Visionary User's Guide, version 1.0
Copyright © 1998, Informix Software, Inc. All rights reserved.