In This Article

DockingWindowContainerBase Class

Represents the base class for a control that can contain multiple docking windows, with one selected.

[TemplatePart(Name = "PART_TabControl", Type = typeof(AdvancedTabControl))]
[TemplateVisualState(Name = "TabStripBottom", GroupName = "TabStripPlacementStates")]
[TemplateVisualState(Name = "TabStripLeft", GroupName = "TabStripPlacementStates")]
[TemplateVisualState(Name = "TabStripRight", GroupName = "TabStripPlacementStates")]
[TemplateVisualState(Name = "TabStripTop", GroupName = "TabStripPlacementStates")]
public abstract class DockingWindowContainerBase : Control, IOrientedElement
Inheritance:
object Visual UIElement FrameworkElement Control object
Derived:
TabbedMdiContainer ToolWindowContainer
Implements:
IOrientedElement

Constructors

DockingWindowContainerBase()

Initializes an instance of the class.

protected DockingWindowContainerBase()

Properties

CanTabsCloseOnMiddleClick

Indicates whether tabs can close when a middle-click is performed over them.

public bool CanTabsCloseOnMiddleClick { get; set; }

Property Value

bool:

The default value is true.

Remarks

The CanClose property must also be set to true for this behavior to work.

DockHost

The DockHost that contains this control.

public DockHost? DockHost { get; }

Property Value

DockHost

DockSite

The DockSite that is managing this control.

public DockSite? DockSite { get; }

Property Value

DockSite

HasTabImages

Indicates whether tabs display an embedded image when one is available.

public bool HasTabImages { get; set; }

Property Value

bool:

The default value is false.

IsActive

Indicates whether the container is currently active, due to focus being within it.

public bool IsActive { get; }

Property Value

bool:

The default value is false.

IsTabLayoutAnimationEnabled

Indicates whether animation effects should be applied during tab layout, such as when tabs are added or removed.

public bool IsTabLayoutAnimationEnabled { get; set; }

Property Value

bool:

The default value is false.

IsTabLayoutAnimationEnabledResolved

Indicates whether animation effects are applied during tab layout, such as when tabs are added or removed.

public bool IsTabLayoutAnimationEnabledResolved { get; }

Property Value

bool:

The default value is false.

IsTabStripVisible

Indicates whether the tabstrip is visible.

public bool IsTabStripVisible { get; protected set; }

Property Value

bool

LogicalChildren

Gets an enumerator for logical child elements of this element.

protected override IEnumerator LogicalChildren { get; }

Property Value

IEnumerator:

An enumerator for logical child elements of this element.

MaxTabExtent

The maximum extent of a tab.

public double MaxTabExtent { get; set; }

Property Value

double:

The default value is 260.0.

MinTabExtent

The minimum extent of a tab.

public double MinTabExtent { get; set; }

Property Value

double:

The default value is 30.0.

SelectedWindow

The DockingWindow that is currently selected in the container.

public DockingWindow? SelectedWindow { get; set; }

Property Value

DockingWindow

SingleTabLayoutBehavior

The behavior used when a single DockingWindow is in the container.

public SingleTabLayoutBehavior SingleTabLayoutBehavior { get; set; }

Property Value

SingleTabLayoutBehavior

State

The DockingWindowState that specifies the current state of the container.

public DockingWindowState State { get; }

Property Value

DockingWindowState

TabControl

The tab control in the container's user interface.

protected AdvancedTabControl? TabControl { get; }

Property Value

AdvancedTabControl

TabControlStyle

The Style to use for the contained TabControl.

public Style? TabControlStyle { get; set; }

Property Value

Style

TabItemContainerStyle

The Style to use for rendering the tab item containers.

public Style? TabItemContainerStyle { get; set; }

Property Value

Style

TabOverflowBehavior

The TabOverflowBehavior that indicates the logic to use in tab overflow scenarios.

public TabOverflowBehavior TabOverflowBehavior { get; set; }

Property Value

TabOverflowBehavior:

The default value is Shrink.

TabStripPlacement

A dock side indicating the side upon which the tabs are located.

public Side TabStripPlacement { get; set; }

Property Value

Side:

The default value is Bottom.

WindowsCore

The collection of child DockingWindow objects.

protected ObservableCollection<DockingWindow> WindowsCore { get; }

Property Value

ObservableCollection<DockingWindow>

Methods

OnApplyTemplate()

When overridden in a derived class, is invoked whenever application code or internal processes call ApplyTemplate().

public override void OnApplyTemplate()

OnDockSiteChanged(DockSite?, DockSite?)

Called when the DockSite property is changed.

protected virtual void OnDockSiteChanged(DockSite? oldDockSite, DockSite? newDockSite)
Parameter Type Description
oldDockSite DockSite

The old value.

newDockSite DockSite

The new value.

OnIsKeyboardFocusWithinChanged(DependencyPropertyChangedEventArgs)

Invoked just before the IsKeyboardFocusWithinChanged event is raised by this element. Implement this method to add class handling for this event.

protected override void OnIsKeyboardFocusWithinChanged(DependencyPropertyChangedEventArgs e)
Parameter Type Description
e DependencyPropertyChangedEventArgs

A System.Windows.DependencyPropertyChangedEventArgs that contains the event data.

OnSelectedWindowChanged(DockingWindow?, DockingWindow?)

Invoked when the SelectedWindow property is changed.

protected virtual void OnSelectedWindowChanged(DockingWindow? oldSelectedWindow, DockingWindow? newSelectedWindow)
Parameter Type Description
oldSelectedWindow DockingWindow

The old selected window.

newSelectedWindow DockingWindow

The new selected window.

OnTabControlMenuOpening(AdvancedTabControlMenuEventArgs)

Invoked when a menu on the tab control is opening.

protected virtual void OnTabControlMenuOpening(AdvancedTabControlMenuEventArgs e)
Parameter Type Description
e AdvancedTabControlMenuEventArgs

The event data.

OnWindowsChanged(NotifyCollectionChangedEventArgs)

Invoked when the windows collection is changed.

protected virtual void OnWindowsChanged(NotifyCollectionChangedEventArgs e)
Parameter Type Description
e NotifyCollectionChangedEventArgs

The event data.

ToString()

Returns the string representation of this object.

public override string ToString()

Returns

string:

The string representation of this object.

UpdateCommands()

Updates the enabled states of the commands.

protected virtual void UpdateCommands()

UpdateDockingWindowStates()

Updates the DockingWindowState associated with all child docking windows.

protected abstract void UpdateDockingWindowStates()

UpdateIsTabStripVisible()

Updates the IsTabStripVisible property.

protected virtual void UpdateIsTabStripVisible()

UpdateTitleBarButtonVisibility()

Updates the title bar button visibility.

protected virtual void UpdateTitleBarButtonVisibility()

UpdateVisualState(bool)

Updates the visual state.

protected virtual void UpdateVisualState(bool useTransitions)
Parameter Type Description
useTransitions bool

Whether to use transitions.

ValidateChildType(DockingWindow)

Validates that the specified child DockingWindow type is valid for this container.

protected virtual void ValidateChildType(DockingWindow window)
Parameter Type Description
window DockingWindow

The DockingWindow to examine.

Fields

CanTabsCloseOnMiddleClickProperty

Defines the CanTabsCloseOnMiddleClick property.

public static readonly DependencyProperty CanTabsCloseOnMiddleClickProperty

HasTabImagesProperty

Defines the HasTabImages property.

public static readonly DependencyProperty HasTabImagesProperty

IsActiveProperty

Defines the IsActive property.

public static readonly DependencyProperty IsActiveProperty

IsTabLayoutAnimationEnabledProperty

Defines the IsTabLayoutAnimationEnabled property.

public static readonly DependencyProperty IsTabLayoutAnimationEnabledProperty

IsTabLayoutAnimationEnabledResolvedProperty

public static readonly DependencyProperty IsTabLayoutAnimationEnabledResolvedProperty

IsTabStripVisibleProperty

Defines the IsTabStripVisible property.

public static readonly DependencyProperty IsTabStripVisibleProperty

MaxTabExtentProperty

Defines the MaxTabExtent property.

public static readonly DependencyProperty MaxTabExtentProperty

MinTabExtentProperty

Defines the MinTabExtent property.

public static readonly DependencyProperty MinTabExtentProperty

SelectedWindowProperty

Defines the SelectedWindow property.

public static readonly DependencyProperty SelectedWindowProperty

SingleTabLayoutBehaviorProperty

Defines the SingleTabLayoutBehavior property.

public static readonly DependencyProperty SingleTabLayoutBehaviorProperty

StateProperty

Defines the State property.

public static readonly DependencyProperty StateProperty

TabControlStyleProperty

Defines the TabControlStyle property.

public static readonly DependencyProperty TabControlStyleProperty

TabItemContainerStyleProperty

Defines the TabItemContainerStyle property.

public static readonly DependencyProperty TabItemContainerStyleProperty

TabOverflowBehaviorProperty

Defines the TabOverflowBehavior property.

public static readonly DependencyProperty TabOverflowBehaviorProperty

TabStripPlacementProperty

Defines the TabStripPlacement property.

public static readonly DependencyProperty TabStripPlacementProperty

Extension Methods