Skip to content

Class: cCJStatusBarPane

Properties | Events | Methods | Index of Classes

Used to create statusbar panes in a commandbar system's statusbar

Hierarchy

cObject > DfComAutomationObject > cComAutomationObject > cCJComStatusBarPane > cCJStatusBarPane

Show full hierarchy and direct subclasses

Library: Windows Application Class Library

Package: cCJCommandBarSystem.pkg

Description

The cCJStatusBarPane object is used to create panes within a statusbar object. These objects must be created inside of a cCJStatusBar object.

Object oCommandBarSystem is a cCJCommandBarSystem

    Object oMenuBar is a cCJMenuBar
        :    
    End_Object

    Object oFindToolBar is a cCJToolbar
        :    
    End_Object

    Object oFileToolBar is a cCJToolbar
        :    
    End_Object

    Object oStatusBar is a cCJStatusBar

        Object oStatusIdle is a cCJStatusBarPane
            Set piId to sbpIDIdlePane
            Set pbStyleStretch to True
        End_Object

        Object oStatusView is a cCJStatusBarPane
            Set phoViewPane to Self
            Set pbStyleStretch to True
        End_Object

        Object oUserName is a cCJStatusBarPane
            Set psText to "User Name"
        End_Object

        Object oStatusCaps is a cCJStatusBarPane
            Set piId to sbpIDCapslock
        End_Object

        Object oReadOnly is a cCJStatusBarPane
            Set psImage to "ImageReadOnly.ico"
        End_Object

    End_Object

End_Object
Col 1 Col 2
Note: For an overview on the commandbar system, refer to Using Menus, Toolbars and Statusbars

Pane Appearance

The appearance of a status pane can be controlled by a number of properties A pane can be assigned text (psText) and/or an image (psImage)Pane content can be left justified, right justified or centered (peAlignment)A pane can be have a tooltip (psTooltip).The size of a pane can be explicitly set or auto-sized (piWidth).Panes can be stretched to fill available space (pbStyleStretch).Panes can appear disabled (pbStyleDisabled)Pane can be hidden (pbVisible)Panes can appear without a border (pbStyleNoBorders)Panes can have custom background (piBackgroundColor) and text (piTextColor) colors

Mouse Events

When you click of double click on a statusbar pane, an event will be sent to the pane (OnClick, OnDblClick). These events can be used to respond to the event in any manner you wish.

Special Panes

Each statusbar pane must be assigned a unique id (piID). Normally, pane IDs are auto assigned. There are several special IDs that can be manually assigned. Those are

Pane ID Purpose
sbpIDAutoAssign This indicates that the piID will be will be auto assigned during pane's end_construct_object (this is the default).
sbpIDIdlePane This is used to display idle text (i.e., statusbar help text) and the psDescription text of cCJMenuItems during mouse hover event. Typically this is applied to the first pane.
sbpIDCapslock Indicates whether CAPS Lock is on or off.
sbpIDNumLock Indicates whether Num Lock is on or off.
sbpIDScrollLock Indicates whether Scroll Lock is on or off.
Object oStatusBar is a cCJStatusBar

    Object oStatusIdle is a cCJStatusBarPane
        Set piId to sbpIDIdlePane
        Set pbStyleStretch to True
    End_Object

    Object oStatusView is a cCJStatusBarPane
        Set phoViewPane to Self
        Set pbStyleStretch to True
    End_Object

    Object oStatusCaps is a cCJStatusBarPane
        Set piId to sbpIDCapslock
    End_Object

    Object oStatusNumLock is a cCJStatusBarPane
        Set piId to sbpIDNumLock
    End_Object

    Object oStatusScrollLock is a cCJStatusBarPane
        Set piId to sbpIDScrollLock
    End_Object

End_Object

The Statusbar Pane Creation Process

When the commandbar system is created, the message CreateComInstance is sent to the cCJStatusBar object. This method will create all of the COM statusbar pane objects and then send OnCreate to each pane. Once the COM object is created, it remains statically bound to its cCJStatusbarPane proxy object.

See Also

cCJCommandBarSystem | cCJStatusBar