Class StackLayout
A layout that stacks its children in a row or a column, in the order they were added.
public class StackLayout : LayoutControl, IUpdateable, IEquatable<IUpdateable>, IDrawable, IIdentifiable<Guid>, IEquatable<IDrawable>, IDisposable
- Inheritance
-
StackLayout
- Implements
- Inherited Members
Constructors
StackLayout(ILogger, View, string)
Creates a stack layout in view.
public StackLayout(ILogger logger, View view, string id = null)
Parameters
Properties
HorizontalAlignment
Where the children sit horizontally when the layout is wider than they need.
public HorizontalAlignment HorizontalAlignment { get; set; }
Property Value
HorizontalSpacing
The gap between children, in pixels, when the layout runs horizontally.
public float HorizontalSpacing { get; set; }
Property Value
Orientation
Whether the children run across the layout or down it. Vertical by default.
public Orientation Orientation { get; set; }
Property Value
Padding
The space kept clear inside the layout's edges, around the children.
public Spacing Padding { get; set; }
Property Value
VerticalAlignment
Where the children sit vertically when the layout is taller than they need.
public VerticalAlignment VerticalAlignment { get; set; }
Property Value
VerticalSpacing
The gap between children, in pixels, when the layout runs vertically.
public float VerticalSpacing { get; set; }
Property Value
Methods
ArrangeControls()
Places the visible children one after another along the stack, aligned as the layout says.
protected override void ArrangeControls()
GetDesiredSize()
The size this layout asks for: its children, with the padding and spacing it keeps.
protected override Vector2 GetDesiredSize()