action.skip

Cursor Tab

The Cursor tab contains cursor movement settings to be used with character-mode hosts. (If you are not working with a character-mode host, Cursor tab controls are unavailable.) Defining cursor movement is helpful when the host and the host application are working in character mode and there are multiple pieces of data to enter on the terminal screen.

To enable Host Integrator to control cursor movement, a key must be mapped in a move cursor command list to create this action. For example, configure tabstops to navigate around attributes or recordset fields on a selected entity by creating a move cursor command list, so that Host Integrator recognizes that the Tab key is mapped to move the cursor on the screen.

You can define cursor movement differently on each entity by using the options on the Cursor tab or you can choose to define a global definition to be used throughout your model using the options in the Advanced Model Properties dialog box. Under Character mode cursor positioning, use the following options to configure a move cursor command list for the selected entity:

  • Use global definition from Model Properties dialog

    Default. Select this option to use the global configuration that you defined in the Advanced Model Properties dialog box to move the cursor between attributes on an entity.

  • Execute operations to move cursor

    This option allows you to select existing operations to move the cursor around the attributes and/or recordset fields of the selected entity. The entity can use one operation to move the cursor forward and another to move the cursor backward.

    Each time Host Integrator executes one of these operations, it expects the cursor to move to a new tabstop. Host Integrator will iteratively execute a cursor operation as needed to reach a desired location on the screen.

Note

Use tabstops to synchronize the host state instead of waiting for a host update.

Notes:

  • In block mode, the cursor location is managed by the local terminal, so Host Integrator can typically direct the terminal to place the cursor in the desired location on the terminal screen. In character mode, however, the host controls all of the data exchange mechanisms.

  • At runtime, Host Integrator uses the configuration hierarchy of entity, global command list, and then global default to decide which direction to move the cursor. For example, if you decide to configure cursor movement for a specific entity on the Cursor tab, this configuration will be used even if you have a global command list defined in the Advanced Model Properties dialog box.

  • To set a timeout by which Host Integrator should expect the host to move to another tabstop, use the MoveCursor Command List Timeout setting. If the operation is still executing when this timeout expires, the operation will terminate.

  • See the Pine model example for more information about configuring cursor movement for character mode applications.

To configure the MoveCursor Command List Timeout setting:

  1. On the Settings menu, click View Settings to open the View Settings dialog box.
  2. Under Host Integrator settings, expand the Entity Design directory tree and select MoveCursor Command List Timeout.
  3. Under Setting details, specify how long (in seconds) to wait for a move cursor command list to execute before an error appears.

Configuring Tabstops

Use the options in the Tabstops box to configure a list of tabstops that constitute all of the possible valid "at rest" positions on the terminal screen. By default, when executing a move cursor operation or command list, Host Integrator will assume that any location other than the current position constitutes the host's next tabstop or new "at rest" position for user interaction.

In most cases, the host requires additional information from Host Integrator to ensure tabstop accuracy. The host often updates status lines or performs other terminal updates before moving the cursor to the next tabstop. Because character mode terminals always write data at the cursor position, the host has to move the cursor to the status line or another update location to make the desired screen changes. Without additional configuration, Host Integrator may issue more move cursor requests than is necessary and get out of sync with the host.

To prevent Host Integrator from getting into this state, define tabstops at the locations for which Host Integrator should wait after issuing move cursor requests. For example, from a given location on the screen, Host Integrator may issue a move forward operation or command list that waits for the cursor to appear at any valid tabstop that is not the starting cursor position. If this new location matches the desired destination, the process terminates.

Otherwise, Host Integrator repeats the process until it reaches the correct location. It is essential that all locations where the host can leave the cursor "at rest" for user interaction be defined as tabstops, regardless of whether the model has an attribute or field defined in that location. If even one location is missed, Host Integrator will issue timeout exceptions when the cursor is moved to the omitted location.

Note

If moving through the fields of your host application requires application interaction, you may have to define the tabstops manually.

The following three lists contain tabstop positioning information:

  • Num - the number of tabstops on the screen.
  • Row - the screen row in which the tabstop begins.
  • Column - the terminal column of the tabstop.

The following options allow you to configure an ordered list of tabstops for the selected entity:

  • Insert - Click to manually insert a tabstop at the current cursor position. To have the Design Tool identify the tabstop positions automatically, click the Generate Next button.
  • Add Current Pos - Click to add the tabstop order number (Num), the screen row, (Row), and the terminal column (Col) of the current cursor position on the Terminal window.

The Apply and Cancel buttons on the Cursor tab are unavailable if the Design Tool recognizes that you have not made any other changes since the last apply was made. Even though the Apply button is unavailable, any changes that you add will be automatically applied to your model.

  • Delete - Removes the selected entry.
  • Move Up - Moves the tab position up one row in the ordered list of tabstops.
  • Move Down - Moves the tabstop down one row in the ordered list of tabstops.
  • Clear - Deletes the entire list.
  • Generate Next - Executes the move cursor command list until all attributes have been recognized and recorded. Once this list is generated, it appears in the Character mode applications box and is saved in the model file.

Notes

  • When generating tabstops, temporarily clear the Wait for cursor check box on the Validation tab of the Advanced Entity Properties dialog box. If you do not clear this check box, the screen snapshot will fail because the entity is set to match attributes according to cursor positioning and generating a tabstop changes the initial cursor position.
  • The Generate Next button is disabled in offline mode.
  • Tabstops are only generated for attributes that appear after the currently defined tabstop on the terminal screen.
  • Test - Click to test the tabstops in the list. If a tabstop in the list does not accurately reflect an attribute on the entity, an error message will appear. Note: This button is disabled in offline mode.
  • Use writable attributes as automatic tabstops - Select this option to automatically include configured attributes as tabstops. This eliminates the need to enter all tabstops manually. If there are other tabstops besides those defined as writable attributes, those tabstops will still have to be entered manually.
  • Tabstops are in specified order - Select this option to make sure that the order of the tabstops reflected in the Design Tool is the order that they will execute at runtime. By default, tabstops are not assumed to be in any specific order.

    If both move forward and move backward options are defined above, Host Integrator uses the screen offsets of the cursor destination location relative to the current cursor location to determine whether to move forward or backward. On some terminal screens, the cursor offset is not a good indicator of direction; therefore, listing tabstops in the same order that the host accesses them can be helpful. Host Integrator then uses the relative location of the tabstop in the list to choose a move cursor direction.

    Note

    This does not mean Host Integrator will wait for the next or prior tabstop in the list. This ordered list is only used to determine the direction to move. Once the operation or command list has been executed, Host Integrator will still wait for any valid tabstop to become the current cursor position.