Back to Devexpress

DataLayoutControl.HorizontalGroupMark Property

wpf-devexpress-dot-xpf-dot-layoutcontrol-dot-datalayoutcontrol-67639859.md

latest3.4 KB
Original Source

DataLayoutControl.HorizontalGroupMark Property

Specifies the symbol that indicates that children within the current DataLayoutControl group will be arranged horizontally.

Namespace : DevExpress.Xpf.LayoutControl

Assembly : DevExpress.Xpf.LayoutControl.v25.2.dll

NuGet Package : DevExpress.Wpf.LayoutControl

Declaration

csharp
public static char HorizontalGroupMark { get; set; }
vb
Public Shared Property HorizontalGroupMark As Char

Property Value

TypeDescription
Char

A Char value that indicates that children within the current DataLayoutControl group will be arranged horizontally.

|

Remarks

To arrange items within a group horizontally or vertically, by default, you have to add the ‘-‘ or the ‘|’ character respectively before the group’s closing character when defining group descriptions via the DisplayAttribute.GroupName attribute. The code below illustrates the example.

csharp
//Two items within a borderless group are arranged vertically
[Display(GroupName = "<Name|>", Name = "Last name")]
public string LastName { get; set; }
[Display(GroupName = "<Name|>", Name = "First name", Order = 0)]
public string FirstName { get; set; }

//Two items within a borderless group are arranged horizontally
[Display(GroupName = "<Name->", Name = "Last name")]
public string LastName { get; set; }
[Display(GroupName = "<Name->", Name = "First name", Order = 0)]
public string FirstName { get; set; }
vb
'Two items within a borderless group are arranged vertically
<Display(GroupName := "<Name|>", Name="" := "Last name")> _
Public Property LastName() As String 
'... 
End Property 
<Display(GroupName := "<Name|>", Name="" := "First name", _
     Order="" := "0")> _
Public Property FirstName() As String 
'... 
End Property 

'Two items within a borderless group are arranged horizontally
<Display(GroupName := "<Name->", Name="" := "Last name")> _
Public Property LastName() As String 
'... 
End Property 
<Display(GroupName := "<Name->", Name="" := "First name", _
     Order="" := "0")> _
Public Property FirstName() As String 
'... 
End Property

To implement your own custom syntax and override the default vertical or horizontal alignment characters, use the static DataLayoutControl.VerticalGroupMark or HorizontalGroupMark properties respectively.

See Also

VerticalGroupMark

Data Layout Control

DataLayoutControl Class

DataLayoutControl Members

DevExpress.Xpf.LayoutControl Namespace