LayoutGroup.GroupBoxStyle Property

Gets or sets the style applied to the GroupBox that represents the current LayoutGroup when the LayoutGroup.View property is set to LayoutGroupView.GroupBox. This is a dependency property.

Namespace: DevExpress.Xpf.LayoutControl

Assembly: DevExpress.Xpf.LayoutControl.v20.1.dll


public Style GroupBoxStyle { get; set; }
Public Property GroupBoxStyle As Style

Property Value

Type Description

A Style that is applied to the LayoutGroup when it's visually represented as a GroupBox.



Target type: GroupBox. For more information on styles, see the Styling and Templating topic in MSDN.

When the LayoutGroup.View property is set to LayoutGroupView.GroupBox, a new GroupBox object is internally created. It's used to visually represent the current LayoutGroup in this paint mode. The GroupBoxStyle style is applied to this GroupBox.

To simultaneously specify a common GroupBoxStyle for all groups within a LayoutControl, use the LayoutControl's inherited GroupBoxStyle property. The control's child groups will be painted according to the LayoutControl's GroupBoxStyle style, provided that a group doesn't override this style via its own GroupBoxStyle property.


The following example shows how to customize the style of a LayoutGroup's header via the LayoutGroup.GroupBoxStyle property. In the example, the title is painted in blue over a light yellow background.

The following image shows the result:


<lc:LayoutGroup x:Name="myLayoutGroup" Orientation="Vertical" View="GroupBox" Header="Group 1" >
        <Style TargetType="lc:GroupBox">
            <Setter Property="TitleBackground" Value="LightYellow"/>
            <Setter Property="Foreground" Value="Blue"/>
See Also