Back to API Reference
Class
AnimationHandler
abstract
One Animator-driven diff unit on a UniTextAnimationBridge. A Unity Animator writes serialized fields directly, bypassing the property setters that normally raise UniTextDirty; a handler caches a baseline of the values it watches and, after each apply, re-issues the invalidation those setters would have.
Remarks
Add handlers to the bridge's inspector list. Built-ins cover the component's own fields (UniTextFieldsAnimationHandler, UniTextWorldFieldsAnimationHandler); author your own by subclassing this for any other component-level diff. The bridge binds every handler on enable. Diffing runs once per OnDidApplyAnimationProperties — keep it allocation-free in steady state.
Derived Types(2)
Types that inherit from AnimationHandler.
CC
ModifierFieldsAnimationHandler
Animates modifier fields from a Unity Animator: diffs every state field of every modifier in the host's styles and raises each field's own declared invalidation. Rebinds itself when the style graph changes.
UniTextFieldsAnimationHandler
Animates a text component's own fields from a Unity Animator: font size, colour, word wrap, auto-size and its min/max, and horizontal/vertical alignment. Add it to the UniTextAnimationBridge on a UniText; use UniTextWorldFieldsAnimationHandler for a UniTextWorld.
protected UniTextBase Host{ get }The component this handler diffs against, or null before Bind.
protected abstract void OnBind(UniTextBase host)Snapshots the watched values as the comparison baseline and caches any per-bind metadata.
Drops any live binding held beyond Host. Default: nothing.
protected abstract void OnDiff(UniTextBase host)Diffs watched values, refreshes their baselines, and raises the matching granular invalidation.
