ContentsIndexPreviousNext

Special Properties

PANEL-WIDTHS (numeric) You may specify this property's value with an integer data item or literal. PANEL-WIDTHS allows you to specify:

1. How many panels the status bar should hold: You may use an array to specify all the panels on one line, and the number of items in the array determines how many panels are created on the status bar; and

2. The width of each panel on the status bar. Each number on the array specifies the width of its corresponding panel in characters.

So, if you specify your status bar using the following array:

    DISPLAY STATUS-BAR
            PANEL-WIDTHS   (50,  20,  20)
            [ ... ].

you are setting up a status bar with three panels, the first 50 characters wide, the other two at 20 characters each.

If you set PANEL-WIDTHS = 0, you create a status bar with one panel extending across its entire width and no text.

If you set PANEL-WIDTHS to a single positive non-zero number greater than the width of the entire status bar (as defined by the width of the host window), the panel gets sized down to fit in the host window and the text gets truncated.

The widths of panels with no PANEL-WIDTHS specified will be automatically calculated based on the total available width of the status bar divided by the number of panels, as specified through the use of PANEL-STYLE, PANEL-TEXT, or PANEL-INDEX.

When you modify PANEL-WIDTHS, the panel is not visually updated until the text is applied. This means that a MODIFY using PANEL-WIDTHS and no PANEL-TEXT will never be displayed. Conversely, any MODIFY statement without PANEL-WIDTHS reflects the changes immediately.

To erase the contents of a status bar, use:

    MODIFY  statusbar-handle
            PANEL-WIDTHS   0.

This removes all the panels and sets up the status bar with one panel extending across its entire width. After this operation, you have one panel with the style of previous panel 1 and no text.

PANEL-STYLE (numeric) allows you to specify the preferred style of the actual panel. You may specify the value with an integer data item or literal. Valid values are:

"0" - Flat; the panel has the same height as the rest of the window, with no visual borders. This style is generally used to present information as a guide, displaying different text to inform the user about the status of the program or the cursor's location on the screen, or prompt for action or data entry into a field. It may also be used to indicate a condition that is temporarily disabled.

"1" - Lowered; the panel appears sunken in the host window. This style is generally used to indicate that an option is active, for instance, the "numlock" is on or the "insert" mode is active.

"2" - Raised; the panel appears raised in the host window. This style is generally used to indicate that an option is deactivated ("capslock" off, etc.)

You must apply the PANEL-STYLE before you apply the PANEL-TEXT, in order to have the text displayed properly.

The default is "0" (zero).

PANEL-TEXT (alphanumeric) can be specified with a data item or a literal. It allows you to specify the text content of a panel. The property pays attention to the current setting of the TRANSLATE-TO-ANSI environment configuration variable. The text may not exceed 255 characters, else the rightmost text is automatically truncated. If the text exceeds the size of the panel, the visibility is the same as in any native Windows control, that is, the leftmost text is visible.

PANEL-INDEX (numeric) is an integer data item or literal. It allows you to specify which panel you want to work with. General number range is from 1 to 128. If you specify an index number that is larger than the current number of panels but lower than 128, the status bar attempts to provide the additional panels up to the index number specified. The new panels all have the same width, as determined by the width of the status bar minus the width of the existing panels and divided by the number of additional panels to be generated. The additional panels inherit their style from the first existing panel. If the first panel does not exist, the default style "0" (zero) applies.

More:

Array and index modes

Sequence order