Member variable XbpStatusBarPanel():alignment Foundation

Specifies how the status message (caption) is to be aligned.

Attribute: EXPORTED
Data type: Numeric (XBPALIGN_LEFT)

The instance variable :alignment contains a numeric value that specifies how both the caption and the image, if defined, are to be aligned within an XbpStatusBarPanel object. The following table lists the constants that may be assigned to the :alignmentinstance variable:

Constants defined for controlling alignment within XbpStatusBarPanel objects
Constant Description
XBPALIGN_LEFT *) Text is displayed left-justified. If an image is defined, it is shown to the left of the text.
XBPALIGN_HCENTER Text is displayed centered within the panel object. If an image is shown, it is displayed to the left of the text.
XBPALIGN_RIGHT Text is shown right-justified. Images are displayed to the right of the text, if defined.
  1. Default value

// Example for changing text alignment within an 
// XbpStatusBarPanel object 
#include "XBP.CH" 

  LOCAL oSBar, oPanel 

    // Create the XbpStatusBar object 
    oSBar := XbpStatusBar():new() 
    oSBar:create( ,, {0,0}, {SetAppWindow():currentSize()[1],30} ) 

    // Have default XbpStatusBarPanel object created 
    // by method :create() display its status 
    // message right-justified 
    oPanel           := oSBar:getItem( 1 ) 
    oPanel:caption   := "Right-justified item" 
    oPanel:alignment := XBPALIGN_RIGHT 



If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.