https://documentation.devexpress.com/#WindowsForms/CustomDocument2498

 

官方文档说明

A Ribbon Status Bar (RibbonStatusBar) is displayed at the bottom of a parent window (form).

It is typically used to display various kinds of status information, zoom controls, etc.

All items displayed within a Ribbon Status Bar are item links.

 

The collection of item links that are owned by the status bar can be accessed via the RibbonStatusBar.ItemLinks property.

This collection provides methods that can be used to add, delete, access individual link objects and perform other common collection management tasks.

At design time, you can add items to the Ribbon Status Bar using a context menu.

 

The Ribbon Status Bar supports a built-in size grip, which allows an end-user to resize the window by dragging.

The visibility of the size grip is controlled by the RibbonStatusBar.ShowSizeGrip property.

 

Note:

The RibbonStatusBar must be associated with a RibbonControl. When you drop a RibbonStatusBar onto the form at design time, it is automatically linked to an existing RibbonControl via the RibbonStatusBar.Ribbon property. When you create a RibbonStatusBar at runtime, you need to manually set the RibbonStatusBar.Ribbon property to an existing RibbonControl.

RibbonStatusBar 必须要有对应的RibbonControl,拖动一个RibbonControl到form上,如果不需要附带的其他的控件(ribbonPage1,ribbonPageGroup1),可以直接删除。

Note:

It is not recommended to use multiple Ribbon Status Bars within the same form. If your form is derived from the RibbonForm class, only the Ribbon Status Bar added last is visible, while all the previously added Status Bars are hidden.

 

添加成员

BarHeaderItem

https://documentation.devexpress.com/#WindowsForms/clsDevExpressXtraBarsBarHeaderItemtopic

Displays static text using a heading style which is determined by the current skin.

The text is typically painted bold出题 against a background that is different from the background of regular buttons.

Use BarHeaderItem to add headers to a PopupMenu or BarSubItem (sub-menu) to separate sets of items.

Remarks

BarHeaderItem is a bar item that can be added to a PopupMenu or BarSubItem (sub-menu) to give a caption to a set of items that follow this BarHeaderItem.

Ribbon Status Bar_sed

The items that follow the BarHeaderItem in the PopupMenu/BarSubItem are arranged in one column by default.

You can arrange them in multiple columns by setting the MultiColumn property to True.

Multi-column mode settings (including the number of columns and item text visibility) can be customized using the OptionsMultiColumn property.

 

To enable multi-column mode for all items in the PopupMenu and BarSubItem, use the PopupMenu.MultiColumn and BarLinkContainerItem.MultiColumn inherited property, respectively.

If the BarHeaderItem.MultiColumn property is set to Default, the multi-column mode availability is specified by the MultiColumn property of the item's owner menu.

It is possible to customize multi-column mode settings in a centralized way, using these properties:

See Replicate Existing Bar Items. Bar Item Links to learn more.

 

Note:

If you only need to display a caption at the top of the PopupMenu, use the PopupMenu.MenuCaption and PopupMenu.ShowCaption properties.

 

 

BarStaticItem 

https://documentation.devexpress.com/#WindowsForms/clsDevExpressXtraBarsBarStaticItemtopic

Represents a bar item with a look and feel similar to the StatusbarPanel.

设置控件显示在RibbonStatusBar的右侧

设置Alignment为Right

 

Remarks

This class combines the functionality of the BarItem and a Status Panel (See StatusBarPanel in MSDN).

With this item, you can create a Status bar-like panel within your application form.

A status panel is often used to display static information or data which cannot be modified by a user.

You are allowed to change its width, right and left indents and content alignment within the item.

The AutoSize property specifies how the item link is located within the bar.

Each link for this item can have its own caption.

Ribbon Status Bar_perl_02

Note:

If you create Bar Items in code, note that these objects may not function properly without being associated with a BarManager or RibbonControl.

To create a Bar Item, use a Bar Item constructor that has the BarManager parameter.

When creating a Bar Item in code for use within a RibbonControl, use a Bar Item constructor that has the BarManager parameter, and pass the RibbonControl.Manager object as this parameter.