StackLayoutPanel
Arranges child elements into a single line that can be oriented horizontally or vertically.
StackLayoutPanel provides sophisticated linear layout functionality, allowing elements to be arranged either horizontally or vertically. It supports advanced features including element wrapping when space is exceeded, equal sizing modes, forced element dimensions, and specialized strip mode behavior.
Key capabilities include:
- Horizontal and vertical orientation support with automatic layout direction
- Element wrapping to new rows or columns when available space is exceeded
- Equal sizing modes for creating uniform element dimensions
- Right-to-left layout support with automatic content alignment adjustment
- Strip mode for single-line layouts without wrapping behavior
- Collapse elements on resize for responsive layout behavior
This layout panel is extensively used in toolbars, button panels, menu bars, ribbon controls, and other UI areas where elements need linear arrangement with intelligent space management. The panel automatically handles content alignment, element spacing, and responsive behavior across different screen sizes and orientations.
Definition
Namespace:Telerik.WinControls.Layouts
Assembly:Telerik.WinControls.dll
Syntax:
public class StackLayoutPanel : LayoutPanel, IDisposable, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IStylableNode
Inheritance: objectDisposableObjectRadObjectRadElementLayoutPanelStackLayoutPanel...
Derived Classes:
Implements:
Inherited Members
Constructors
public StackLayoutPanel()
Fields
public static readonly RadProperty EqualChildrenHeightProperty
public static readonly RadProperty EqualChildrenWidthProperty
[Obsolete("The property is not relevant for this class.")]
public static RadProperty FlipMaxSizeDimensionsProperty
public static RadProperty OrientationProperty
public static RadProperty RowProperty
Properties
Gets or sets a value indicating whether the elements have equal height.
public bool EqualChildrenHeight { get; set; }
Gets or sets a value indicating whether the elements have equal width.
public bool EqualChildrenWidth { get; set; }
Notifies all children when same child changes. Effectively redraws all children in the panel.
public override bool InvalidateChildrenOnChildChanged { get; }
Overrides:
Gets or sets the elements orientation inside the stack layout. Possible values are horizontal and vertical.
public Orientation Orientation { get; set; }
Methods
Measures the space required by the RadElement
Used by the layout system.