DockLayoutControl.Dock Attached Property
In This Article
Gets or sets the position of a child element within a parent DockLayoutControl. This is an attached property. This is a dependency property.
Namespace: DevExpress.Xpf.LayoutControl
Assembly: DevExpress.Xpf.LayoutControl.v14.2.dll
#Declaration
#Returns
Type | Description |
---|---|
Dock | A Dock value that specifies the position of a child element within a parent Dock |
#Remarks
To dock an item to a specific side of the DockLayoutControl, use the Dock attached property.
#Examples
The following example creates a DockLayoutControl with six items. The items are docked via the DockLayoutControl.Dock attached property.
The following image shows the result:
<UserControl
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:lc="http://schemas.devexpress.com/winfx/2008/xaml/layoutcontrol"
x:Class="SilverlightApplication10.MainPage"
Width="500" Height="400">
<Grid x:Name="LayoutRoot" Background="White">
<lc:DockLayoutControl >
<lc:GroupBox lc:DockLayoutControl.Dock="Top" Height="70" Header="GroupBox 1"/>
<lc:GroupBox lc:DockLayoutControl.Dock="Right" Header="GroupBox 2"/>
<lc:GroupBox lc:DockLayoutControl.Dock="Bottom" Height="70" Header="GroupBox 3"/>
<lc:GroupBox lc:DockLayoutControl.Dock="Left" Header="GroupBox 4"/>
<lc:GroupBox lc:DockLayoutControl.Dock="Top" Height="70" Header="GroupBox 5"/>
<lc:GroupBox lc:DockLayoutControl.Dock="Client" Header="GroupBox 6"/>
</lc:DockLayoutControl>
</Grid>
</UserControl>
See Also