string DisplayName { get; set; }

robot_2Generated
code_blocksInput

Description

The DisplayName property of the SerializedProperty class provides a user-friendly name for the property. This name is typically used in user interfaces, such as editors or inspectors, to present a more readable or descriptive label for the property, as opposed to its internal or technical name.

Usage

Use the DisplayName property to retrieve or set the display name of a serialized property. This can be particularly useful when you want to customize how properties are presented in a UI, making them more understandable to users.

Example

// Example of accessing the DisplayName property
SerializedProperty property = ...; // Assume this is an initialized SerializedProperty object
string displayName = property.DisplayName;

// Example of setting the DisplayName property
property.DisplayName = "Custom Display Name";