This topic introduces the ability to place a close button on the tabs of a tabbed docked area.
The following topics are prerequisites to understanding this topic:
This topic contains the following sections:
In previous versions, the close buttons for tabs were only available in the caption area of a pane. With the addition of the CloseButtonLocation property, the close button can also appear on the tab itself for any tabbed dock area.
The following screenshot is a preview of the close button appearing in the caption area, tabs of a tab group, and an unpinned tab.
The CloseButtonLocation property determines the display areas of the close button. The CloseButtonLocation property has been added to the GroupSettings object of the WinDockManager.
The following table summarizes the values of the CloseButtonLocation enum.
The screenshot below demonstrates how the WinDockManager component with a WinTree and a WinExplorerBar docked as a TabGroup looks as a result of setting the DefaultGroupSettings.CloseButtonLocation property to All:
In C#:
// Set the DefaultGroupSettings.CloseButtonLocation property to All.
this.ultraDockManager1.DefaultGroupSettings.CloseButtonLocation = Infragistics.Win.UltraWinDock.CloseButtonLocation.All;
// Dock some controls as a TabGroup.
Infragistics.Win.UltraWinDock.DockAreaPane dockAreaPane = this.ultraDockManager1.DockControls(
new Control[] { this.ultraTree1, this.ultraExplorerBar1 },
Infragistics.Win.UltraWinDock.DockedLocation.DockedLeft,
Infragistics.Win.UltraWinDock.ChildPaneStyle.TabGroup);
In Visual Basic:
' Set the DefaultGroupSettings.CloseButtonLocation property to All. Me.UltraDockManager1.DefaultGroupSettings.CloseButtonLocation = Infragistics.Win.UltraWinDock.CloseButtonLocation.All ' Dock some controls as a TabGroup. Dim dockAreaPane As Infragistics.Win.UltraWinDock.DockAreaPane = Me.UltraDockManager1.DockControls( New Control() { Me.UltraTree1, Me.UltraExplorerBar1 }, Infragistics.Win.UltraWinDock.DockedLocation.DockedLeft, Infragistics.Win.UltraWinDock.ChildPaneStyle.TabGroup)
The following topics provide additional information related to this topic: