docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class OptionalStringDrawer

    Draws the Inspector GUI for an optional string property

    Inheritance
    object
    GUIDrawer
    PropertyDrawer
    OptionalPropertyDrawer<string, TextField>
    OptionalStringDrawer
    Inherited Members
    OptionalPropertyDrawer<string, TextField>.m_HasValue
    OptionalPropertyDrawer<string, TextField>.m_Value
    OptionalPropertyDrawer<string, TextField>.m_HasValueField
    OptionalPropertyDrawer<string, TextField>.m_ValueField
    OptionalPropertyDrawer<string, TextField>.CreatePropertyGUI(SerializedProperty)
    OptionalPropertyDrawer<string, TextField>.SetValue(string)
    PropertyDrawer.OnGUI(Rect, SerializedProperty, GUIContent)
    PropertyDrawer.CreatePropertyGUI(SerializedProperty)
    PropertyDrawer.GetPropertyHeight(SerializedProperty, GUIContent)
    PropertyDrawer.CanCacheInspectorGUI(SerializedProperty)
    PropertyDrawer.attribute
    PropertyDrawer.fieldInfo
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Unity.AppUI.Editor
    Assembly: Unity.AppUI.Editor.dll
    Syntax
    [CustomPropertyDrawer(typeof(Optional<string>))]
    public class OptionalStringDrawer : OptionalPropertyDrawer<string, TextField>

    Methods

    SetValue(string)

    Sets the value of the property in the serialized object

    Declaration
    protected override void SetValue(string newValue)
    Parameters
    Type Name Description
    string newValue

    The new value of the property

    Overrides
    OptionalPropertyDrawer<string, TextField>.SetValue(string)
    In This Article
    Back to top
    Copyright © 2025 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)