Skip to content

Class AlignmentExtensions

Definition

Namespace: StardewUI.Layout
Assembly: StardewUI.dll

Common helpers for Alignment.

public static class AlignmentExtensions

Inheritance
Object ⇦ AlignmentExtensions

Members

Methods

Name Description
Align(Alignment, Single, Single) Applies an alignment to an axis starting at position 0.

Details

Methods

Align(Alignment, float, float)

Applies an alignment to an axis starting at position 0.

public static float Align(StardewUI.Layout.Alignment alignment, float contentLength, float axisLength);
Parameters

alignment   Alignment
The alignment type.

contentLength   Single
The length (width or height) of the content to align.

axisLength   Single
The total space (width or height) available for the content.

Returns

Single