Packages
 In this topic

*Constructors

*Methods

 

Packages   PreviousThis PackageNext
Package com.ms.ui   Previous This
Package
Next

 


Class UIStatus

public class UIStatus extends UISingleContainer
{
  // Constructors
  public UIStatus();
  public UIStatus(String text);
  public UIStatus(String text, int style);
  public UIStatus(IUIComponent comp);

  // Methods
  public int getRoleCode();
  public boolean isKeyable();
}

This class implements a status bar control. Typically, a UIStatus object is used as an output-only informational window, located along the bottom of an application. Common uses for a status bar include displaying helpful information for the user and noting the current state of shift keys, such as NUM LOCK, CAPS LOCK, and SCROLL LOCK.

You can create a UIStatus object in several ways. For example, you can specify a text string with an optional style for justification, or you can create a component and display it on the UIStatus object. The following sample shows how to use UIStatus to display a component.

// Construct a text component that
// displays mouse coordinates.
txtCmpnt = new UIText("X:   Y:");

// Construct the status bar.
stbMousePos = new UIStatus(txtCmpnt);
UIComponent
  |
  +--UIContainer
    |
    +--UIStateContainer
      |
      +--UISingleContainer
        |
        +--UIStatus

Constructors

UIStatus

public UIStatus();

Creates a status bar control with no content.

UIStatus

public UIStatus(String text);

Creates a status bar control with the specified text.

ParameterDescription
text The text to be displayed within the control.

Remarks:

By default, the text is left-aligned.

UIStatus

public UIStatus(String text, int style);

Creates a status bar control with the specified text and style.

ParameterDescription
text The text to be displayed within the control.
style The style of the control. For a list of possible values, see the alignment flags described in the UIStatic.setFlags method.

UIStatus

public UIStatus(IUIComponent comp);

Creates a status bar control with the specified component.

ParameterDescription
comp The component to be displayed within the control.

Methods

getRoleCode

public int getRoleCode();

Retrieves the ROLE_SYSTEM code that best describes the role of the status bar control.

Return Value:

Returns the ROLE_SYSTEM_STATUSBAR code.

isKeyable

public boolean isKeyable();

Determines whether the status bar control can receive keyboard input.

Return Value:

Returns false, which indicates that the control cannot receive keyboard input.

upnrm.gif © 1998 Microsoft Corporation. All rights reserved. Terms of use.