Skip to main content

RibbonBarGroup

Namespace: Wisej.Web.Ext.RibbonBar

Assembly: Wisej.Web.Ext.RibbonBar (4.1.0.0)

Represents a group of RibbonBarItem in a RibbonBarPage.

public class RibbonBarGroup : Component

The group displays its Items in vertical columns (see ColumnBreak) above the title set in Text. When ShowButton is true, a small button is displayed next to the title; clicking it fires the Click event and the GroupClick event.

Constructors​

Instance member RibbonBarGroup()​

Initializes a new instance of RibbonBarGroup.

Properties​

Instance member Enabled​

Boolean: Returns or sets whether the items in the RibbonBarGroup can respond to user interaction. (Default: True)

Value: true if the group and its items can respond to user interaction; otherwise, false. The default is true.

Disabling the group disables all its child items on the client, including the group button, without changing the Enabled property of the items.

Instance member Items​

RibbonBarItemCollection: Returns the collection of RibbonBarItem children.

Adding an item to the collection sets its Parent to this group. The items are stacked vertically in columns in the order they appear in the collection; see ColumnBreak.

Example:

Adding a large button, a separator and a column of small items:

var group = this.ribbonBarGroup1;
group.Items.Add(new RibbonBarItemButton { Name = "find", Text = "Find", ImageSource = "icon-search" });
group.Items.Add(new RibbonBarItemSeparator());
group.Items.Add(new RibbonBarItemCheckBox { Name = "matchCase", Text = "Match case" });
group.Items.Add(new RibbonBarItemCheckBox { Name = "wholeWord", Text = "Whole word" });
group.Items.Add(new RibbonBarItemTextBox { Name = "searchText", Text = "Find:" });

Instance member Name​

String: Returns or sets the name of the RibbonBarGroup.

Value: The name of the RibbonBarGroup. The default is an empty string ("").

The name can be used to retrieve the group from the Groups collection (case insensitive). At design time it's the name of the component in the designer.

Instance member Parent​

RibbonBarPage: Returns the RibbonBarPage that owns this RibbonBarGroup.

Instance member RibbonBar​

RibbonBar: Returns the RibbonBar that contains this RibbonBarGroup.

Returns null until the group is added to a RibbonBarPage that belongs to a RibbonBar.

Instance member ShowButton​

Boolean: Returns or sets whether the RibbonBarGroup shows the expand button next to the group's title. (Default: False)

Value: true to show the button next to the title; otherwise, false. The default is false.

Clicking the button fires the Click event on the group and the GroupClick event on the RibbonBar. It's typically used to open a dialog with additional options.

Example:

Opening a dialog with more options when the group button is clicked:

this.ribbonBarGroupFont.ShowButton = true;
this.ribbonBarGroupFont.Click += (s, e) =>
{
new FontOptionsDialog().ShowDialog();
};

Instance member Tag​

Object: Returns or sets the object that contains data about the control. (Default: null)

Value: An object that contains user-defined data about the control. The default is null.

Instance member Text​

String: Returns or sets the title of the RibbonBarGroup. (Default: "")

Value: The text displayed at the bottom of the group.

The title is hidden when the text is empty.

Instance member Visible​

Boolean: Returns or sets whether the RibbonBarGroup is visible or hidden. (Default: True)

Value: true if the group is visible; otherwise, false. The default is true.

A hidden group doesn't take any space in the RibbonBarPage.

Methods​

Protected member Dispose(disposing)​

Disposes of the resources (other than memory) used by the RibbonBarGroup.

ParameterTypeDescription
disposingBooleantrue when this method is called by the application rather than a finalizer.

Protected member OnAddReferences(items)​

Returns a collection of referenced components or collection of components.

ParameterTypeDescription
itemsIList

Instance member OnClick(e)​

Fires the Click event.

ParameterTypeDescription
eEventArgsA EventArgs that contains the event data.

Protected member OnWebEvent(e)​

Processes the event from the client.

ParameterTypeDescription
eWisejEventArgsEvent arguments.

Protected member OnWebRender(config)​

Renders the client component.

ParameterTypeDescription
configObjectDynamic configuration object.

Instance member Update()​

Updates the component on the client.

Changing the properties of the group already updates the client. At design time the entire RibbonBar is updated.

Example:

Forcing the group to be updated on the client:

this.ribbonBarGroup1.Update();

Events​

Instance member Click​

EventHandler Fired when the user clicks the RibbonBarGroup button next to the label.

Implements​