TextStudio3DToggle
[AddComponentMenu("Text Studio/Spatial UI/3D Toggle")]public sealed class TextStudio3DToggle : TextStudio3DControlProvides a two-state spatial control with separate labels and a value-changed event.
Methods
Section titled “Methods”
SetIsOn(bool, bool)
Section titled “SetIsOn(bool, bool)”public void SetIsOn(bool value, bool notify)Changes the toggle value, refreshes selected visuals and label text, and optionally raises the value event.
Parameters
| Name | Type |
|---|---|
value |
System.Boolean |
notify |
System.Boolean |
RefreshLabel()
Section titled “RefreshLabel()”protected override void RefreshLabel()Allows a subclass to derive its displayed label from current semantic state.
PerformActivation()
Section titled “PerformActivation()”protected override void PerformActivation()Applies the subclass’s semantic activation after common interactability checks.
Constructors
Section titled “Constructors”
TextStudio3DToggle()
Section titled “TextStudio3DToggle()”public TextStudio3DToggle()Properties
Section titled “Properties”
public bool IsOn { get; set; }Returns
System.Boolean
OffLabel
Section titled “OffLabel”public string OffLabel { get; set; }Returns
System.String
OnLabel
Section titled “OnLabel”public string OnLabel { get; set; }Returns
System.String
OnValueChanged
Section titled “OnValueChanged”public UnityEvent<bool> OnValueChanged { get; }Returns
UnityEngine.Events.UnityEvent{System.Boolean}