Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
   Reporting
  [Expand]Data Grid
  [Expand]Ribbon, Bars and Menu
  [Expand]Charts Suite
  [Expand]Pivot Grid
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Collapse]Layout Management
   [Expand]Dock Windows
   [Collapse]Tile and Layout
    [Collapse]Layout and Data Layout Controls
      Layout Control
      Data Layout Control
      Layout Items and Groups
      Aligning contents of LayoutItems
      Aligning Items within LayoutGroup and LayoutControl Objects
      Customization Mode
      Available Items List
     Tile Layout Control
     Dock Layout Control
     Flow Layout Control
    [Expand]Common Features
    [Expand]Examples
   [Expand]Tab Control
   [Expand]Carousel
    Book Control
    Workspace Manager
  [Expand]Windows Modern UI
  [Expand]Printing-Exporting
  [Expand]Data Editors
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Diagram Control
  [Expand]Scheduler (legacy)
 [Expand]Scaffolding Wizard
 [Expand]Localization
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Aligning contents of LayoutItems

Expanded Across-Group Alignment

Layout items are objects that associate labels with controls. When layout items are used within a LayoutControl, the automatic alignment feature is enabled. With this feature, the left edges of the item's content regions are aligned, according to the width of the largest label:

By default, the LayoutControl supports the content region alignment across multiple groups. This takes place for layout items that have the same horizontal offset from the left edge of the LayoutControl, even if they belong to different groups. Again, content regions of these items are aligned by the largest label:

The following image demonstrates the same feature. Here, layout groups are arranged in two columns. For layout items that have the same horizontal offset, content regions are aligned:

Expanded Local Alignment

For individual groups, you can enable a local alignment of items' content regions. The local alignment of content regions is not affected by labels of other groups. To enable the local alignment of content regions, set the LayoutGroup.ItemLabelsAlignment property to Local.

In the following image, the LayoutGroup.ItemLabelsAlignment property is set to Local for Group 2. The content regions in this group are aligned locally, while the content regions in Group 1, Group 3 and Group 4 are aligned disregarding the labels in Group 2:

Note

Layout items whose the LayoutItem.Label property is not specified are considered as LayoutItems without a label part and are excluded from alignment.

Is this topic helpful?​​​​​​​