Table of Contents

DOFlexibleSize Method

Namespace
DG.Tweening

DOFlexibleSize(LayoutElement, Vector2, float, bool)

public static TweenerCore<Vector2, Vector2, VectorOptions> DOFlexibleSize(this LayoutElement target, Vector2 endValue, float duration, bool snapping = false)

Tweens an LayoutElement's flexibleWidth/Height to the given value. Also stores the LayoutElement as the tween's target so it can be used for filtered operations

Parameters

target LayoutElement
endValue Vector2

The end value to reach

duration float

The duration of the tween

snapping bool

If TRUE the tween will smoothly snap all values to integers

Returns

TweenerCore<Vector2, Vector2, VectorOptions>