'宣言 Public Shared ReadOnly AllowDockingInTabGroupProperty As DependencyProperty
public static readonly DependencyProperty AllowDockingInTabGroupProperty
Imports Infragistics.Windows.DockManager Private Sub InitializeDmTabs(ByVal dockManager As XamDockManager) ' The AllowInDocumentHost is used to control ' whether the end user may move the pane into ' the DocumentContentHost associated with the ' containing dockmanager. For this pane you ' cannot right click and choose Document nor ' can you drag it into the DocumentContentHost. ' Dim cpNeverDoc As New ContentPane() cpNeverDoc.Header = "Never a Document" cpNeverDoc.AllowInDocumentHost = False ' AllowDockingInTabGroup is used to control ' whether the end user can put the pane into ' a dockable tab group (or create a tabgroup ' using the pane). Note, it does not affect ' the pane when in the document content host. ' For this pane, you cannot drag it to another ' docked pane to create a tab group and cannot ' drag another pane into this such that it ' creates a tab group. ' Dim cpNeverTab As New ContentPane() cpNeverTab.Header = "Never in Docked Tab" cpNeverTab.AllowDockingInTabGroup = False Dim cpAll As New ContentPane() cpAll.Header = "Everything Allowed" Dim split As New SplitPane() split.SplitterOrientation = Orientation.Horizontal split.Panes.Add(cpNeverDoc) split.Panes.Add(cpNeverTab) split.Panes.Add(cpAll) dockManager.Panes.Add(split) dockManager.Content = New DocumentContentHost() End Sub
using Infragistics.Windows.DockManager; private void InitializeDmTabs(XamDockManager dockManager) { // The AllowInDocumentHost is used to control // whether the end user may move the pane into // the DocumentContentHost associated with the // containing dockmanager. For this pane you // cannot right click and choose Document nor // can you drag it into the DocumentContentHost. // ContentPane cpNeverDoc = new ContentPane(); cpNeverDoc.Header = "Never a Document"; cpNeverDoc.AllowInDocumentHost = false; // AllowDockingInTabGroup is used to control // whether the end user can put the pane into // a dockable tab group (or create a tabgroup // using the pane). Note, it does not affect // the pane when in the document content host. // For this pane, you cannot drag it to another // docked pane to create a tab group and cannot // drag another pane into this such that it // creates a tab group. // ContentPane cpNeverTab = new ContentPane(); cpNeverTab.Header = "Never in Docked Tab"; cpNeverTab.AllowDockingInTabGroup = false; ContentPane cpAll = new ContentPane(); cpAll.Header = "Everything Allowed"; SplitPane split = new SplitPane(); split.SplitterOrientation = Orientation.Horizontal; split.Panes.Add(cpNeverDoc); split.Panes.Add(cpNeverTab); split.Panes.Add(cpAll); dockManager.Panes.Add(split); dockManager.Content = new DocumentContentHost(); }