BarSplitButtonItemLink Class
Represents a link to a BarSplitButtonItem object.
Namespace: DevExpress.Xpf.Bars
Assembly: DevExpress.Xpf.Core.v19.2.dll
Declaration
Remarks
See Items and Links to learn more.
Example
This example shows how to create a BarSplitButtonItem, which represents a button with the drop-down functionality. Clicking the button’s Down Arrow displays a popup window. To add a custom content into the popup, use the PopupControlContainer as the PopupControl. To add other bar items, use the PopupMenu.
The following image shows the result:
Note
A complete sample project is available at https://github.com/DevExpress-Examples/how-to-create-a-barsplitbuttonitem-e1567.
private void btnFontColor_ItemClick(object sender, DevExpress.Xpf.Bars.ItemClickEventArgs e) {
PopupControlContainer pcc = (e.Item as DevExpress.Xpf.Bars.BarSplitButtonItem).PopupControl as PopupControlContainer;
Color color = ((pcc.Content as UserControl).Content as ColorChooser).Color;
MessageBox.Show("Color is applied: " + color.ToString());
}
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the BarSplitButtonItemLink class.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.