WithDisplayName(string)
Configures the display name of the port being built.
Read time 1 minuteLast updated 11 days ago
Definition
- Type: Method
- Namespace: Unity.GraphToolkit.Editor
- Assembly: UnityEditor
T WithDisplayName(string displayName)
Parameters
The display name to assign to the port.
Returns
Type | Description |
|---|---|
| T | The current builder instance for method chaining. |
Remarks
Use this method to assign a custom label to the port. This label appears in the user interface next to the port and helps clarify its purpose. Set the display name before calling IPortBuilder<T>.Build(). The value does not affect functionality but improves usability and readability. If not set, the port name passed during creation (see: Node.IPortDefinitionContext.AddInputPort and Node.IPortDefinitionContext.AddOutputPort) is used as the fallback display name.