Skip to content

TextStudio3DSlider

ClassTextStudio.ThreeDTextStudio.3D
[AddComponentMenu("Text Studio/Spatial UI/3D Slider")]
public sealed class TextStudio3DSlider : TextStudio3DControl

Maps pointer movement or programmatic activation onto a bounded numeric range and optional 3D thumb.

public bool SetValue(float value, bool notify)

Clamps and optionally rounds the slider value, updates label and thumb presentation, and optionally raises its event.

Parameters

Name Type
value System.Single
notify System.Boolean

Returns

System.Boolean: True when the retained value changed.

public void SetNormalizedValue(float normalizedValue)

Maps a normalized position onto the configured numeric range and publishes the change.

Parameters

Name Type
normalizedValue System.Single

OnPointerPressed(TextStudio3DInteractionContext)

Section titled “OnPointerPressed(TextStudio3DInteractionContext)”
protected override void OnPointerPressed(TextStudio3DInteractionContext context)

Allows a subclass to initialize state for an accepted primary-button press.

Parameters

Name Type
context TextStudio.ThreeD.TextStudio3DInteractionContext

OnPointerDragged(TextStudio3DInteractionContext)

Section titled “OnPointerDragged(TextStudio3DInteractionContext)”
protected override void OnPointerDragged(TextStudio3DInteractionContext context)

Allows a subclass to update its value or transform from an accepted pointer drag.

Parameters

Name Type
context TextStudio.ThreeD.TextStudio3DInteractionContext
protected override void RefreshLabel()

Allows a subclass to derive its displayed label from current semantic state.

protected override void PerformActivation()

Applies the subclass’s semantic activation after common interactability checks.

public TextStudio3DSlider()

public float Minimum { get; set; }

Returns

System.Single

public float Maximum { get; set; }

Returns

System.Single

public float Value { get; set; }

Returns

System.Single

public float NormalizedValue { get; }

Returns

System.Single

public bool WholeNumbers { get; set; }

Returns

System.Boolean

public UnityEvent<float> OnValueChanged { get; }

Returns

UnityEngine.Events.UnityEvent{System.Single}

protected override bool ActivateOnPointerRelease { get; }

Returns

System.Boolean