docs.unity.cn
    Show / Hide Table of Contents

    Class RelativePropertiesDrawer

    Custom property drawer that renders automatically a set of properties of a given object

    Inheritance
    System.Object
    GUIDrawer
    PropertyDrawer
    RelativePropertiesDrawer
    Inherited Members
    PropertyDrawer.CanCacheInspectorGUI(SerializedProperty)
    PropertyDrawer.attribute
    PropertyDrawer.fieldInfo
    PropertyDrawer.preferredLabel
    Namespace: UnityEditor.Rendering
    Syntax
    public abstract class RelativePropertiesDrawer : PropertyDrawer

    Properties

    relativePropertiesNames

    The set of properties to draw the default PropertyDrawer.

    Declaration
    protected abstract string[] relativePropertiesNames { get; }
    Property Value
    Type Description
    String[]

    Methods

    CreatePropertyGUI(SerializedProperty)

    Declaration
    public override VisualElement CreatePropertyGUI(SerializedProperty property)
    Parameters
    Type Name Description
    SerializedProperty property
    Returns
    Type Description
    VisualElement
    Overrides
    PropertyDrawer.CreatePropertyGUI(SerializedProperty)

    GetPropertyHeight(SerializedProperty, GUIContent)

    Declaration
    public override float GetPropertyHeight(SerializedProperty property, GUIContent label)
    Parameters
    Type Name Description
    SerializedProperty property
    GUIContent label
    Returns
    Type Description
    System.Single
    Overrides
    PropertyDrawer.GetPropertyHeight(SerializedProperty, GUIContent)

    OnGUI(Rect, SerializedProperty, GUIContent)

    Declaration
    public override void OnGUI(Rect position, SerializedProperty property, GUIContent label)
    Parameters
    Type Name Description
    Rect position
    SerializedProperty property
    GUIContent label
    Overrides
    PropertyDrawer.OnGUI(Rect, SerializedProperty, GUIContent)

    Extension Methods

    AnalyticsUtils.ToNestedColumnWithDefault<T>(T, T, Boolean)
    ReflectionUtils.Invoke(Object, String, Object[])
    ReflectionUtils.SetField(Object, String, Object)
    ReflectionUtils.GetField(Object, String)
    ReflectionUtils.GetFields(Object)
    Back to top Copyright © 2023 Unity Technologies — Terms of use
    Generated by DocFX
    on 07 July 2023