Table of Contents

Struct OffsetValues

Namespace
Fallencake.UI
Assembly
Fallencake.UI.dll

Represents offset values for RectTransform margins offsetMin controls Left and Bottom margins offsetMax controls Right and Top margins

[Serializable]
public struct OffsetValues

Constructors

OffsetValues(float, float, float, float)

public OffsetValues(float left, float bottom, float right, float top)

Parameters

left float
bottom float
right float
top float

OffsetValues(Vector2, Vector2)

public OffsetValues(Vector2 offsetMin, Vector2 offsetMax)

Parameters

offsetMin Vector2
offsetMax Vector2

Properties

Bottom

Bottom margin (offsetMin.y)

public float Bottom { get; set; }

Property Value

float

Left

Left margin (offsetMin.x)

public float Left { get; set; }

Property Value

float

OffsetMax

public Vector2 OffsetMax { get; }

Property Value

Vector2

OffsetMin

public Vector2 OffsetMin { get; }

Property Value

Vector2

Right

Right margin (offsetMax.x)

public float Right { get; set; }

Property Value

float

Top

Top margin (offsetMax.y)

public float Top { get; set; }

Property Value

float

Methods

Lerp(OffsetValues, OffsetValues, float)

Linear interpolation between two OffsetValues

public static OffsetValues Lerp(OffsetValues a, OffsetValues b, float t)

Parameters

a OffsetValues
b OffsetValues
t float

Returns

OffsetValues

Operators

implicit operator OffsetValues((float left, float bottom, float right, float top))

public static implicit operator OffsetValues((float left, float bottom, float right, float top) tuple)

Parameters

tuple (float left, float bottom, float right, float top)

Returns

OffsetValues