SliderDrawingclass

Shared dimensions and painting for single-value and interval sliders.

object→SliderDrawing
Namespace
Editor
Assembly
Sandbox.Tools
Declaration
public static abstract sealed class Editor.SliderDrawing

Methods2

Showing 2 methods

public static void DrawHandle(Editor.Widget widget, Sandbox.Rect rect, float position)PUBLICSTATIC

Draws a handle centered at the given position, measured from the left of rect. Uses the owning widget's cursor and enabled state for hover highlighting.

ParameterTypeDescription
widgetWidget—
rectRect—
positionfloat—
Returns:void—

public static void DrawTrack(Sandbox.Rect rect, float start, float end, Color highlight, bool disabled = False)PUBLICSTATIC

Draws the track and selected interval. Endpoint positions are measured from the left of rect, at the centers of the handles.

ParameterTypeDescription
rectRect—
startfloat—
endfloat—
highlightColor—
disabled = Falsebool—
Returns:void—

On this page