Skip to main content
A newer version of this page is available. .
Bar

BarItem Class

Provides the functionality of bar elements.

Namespace: DevExpress.XtraBars

Assembly: DevExpress.XtraBars.v20.2.dll

NuGet Package: DevExpress.Win.Navigation

Declaration

public class BarItem :
    Component,
    IXtraSerializable,
    ICustomTypeDescriptor,
    IAppearanceOwner,
    IBindableComponent,
    IComponent,
    IDisposable,
    IDXImageUriClient,
    ISupportAdornerElementBarItem,
    IUpdateAdornerUI,
    IDXMenuItemOwner,
    IImageDropInfo,
    ISupportDXSkinColorsEx,
    ISupportDXSkinColors

Remarks

BarItem describes the functionality for any object located within a bar. Items are non-visual elements that contain methods and properties of the object within a bar and process specific object events. Item defines an object’s response to mouse clicks or key press events. Properties displayed within the Properties section of the Customization window are item properties.

Items in Customization

A BarItem can be placed onto any existing bar or menu and based upon the item’s location, its behavior changes: in a bar, the item is a regular bar button, which can be clicked by a mouse or activated by a shortcut key combination. In a menu, the bar item is a specific menu command.

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.

See Also