AnimationPropertyDrawer
[CustomPropertyDrawer(typeof(Animation))]public class AnimationPropertyDrawer : PropertyDrawerDraws ChartGuru.Animation in a shape that mirrors SwiftUI’s Animation API: a curve (Kind) selector plus duration / spring parameters and fluent modifiers (Delay / Speed / Repeat / AutoReverses).
Methods
Section titled “Methods”
GetPropertyHeight(SerializedProperty, GUIContent)
Section titled “GetPropertyHeight(SerializedProperty, GUIContent)”public override float GetPropertyHeight(SerializedProperty property, GUIContent label)Override this method to specify how tall the GUI for this field is in pixels.
Parameters
| Name | Type | Description |
|---|---|---|
property |
UnityEditor.SerializedProperty | The SerializedProperty to make the custom GUI for. |
label |
UnityEngine.GUIContent | The label of this property. |
Returns
System.Single —
The height in pixels.
OnGUI(Rect, SerializedProperty, GUIContent)
Section titled “OnGUI(Rect, SerializedProperty, GUIContent)”public override void OnGUI(Rect position, SerializedProperty property, GUIContent label)Override this method to make your own IMGUI based GUI for the property.
Parameters
| Name | Type | Description |
|---|---|---|
position |
UnityEngine.Rect | Rectangle on the screen to use for the property GUI. |
property |
UnityEditor.SerializedProperty | The SerializedProperty to make the custom GUI for. |
label |
UnityEngine.GUIContent | The label of this property. |