Table of Contents

Class Slider

Namespace
BSGameLib.UI.Builder.Models
Assembly
BSGameLib.UI.dll

A horizontal slider choosing a number between Minimum and Maximum - a volume, a scale. Value binds two-way, so the view model sees every change as the player drags.

public class Slider : Control
Inheritance
Slider
Inherited Members

Properties

BorderColor

An outline drawn around the track.

public string BorderColor { get; set; }

Property Value

string

BorderThickness

The border's width in pixels. Has no effect unless BorderColor is set. One by default.

[Range(0, 2147483647)]
public int BorderThickness { get; set; }

Property Value

int

FillColor

The filled part of the track, up to the value.

public string FillColor { get; set; }

Property Value

string

FillGradient

A gradient for the filled part, naming a Gradient resource. Drawn in place of FillColor when both are set.

public string FillGradient { get; set; }

Property Value

string

FocusColor

An outline drawn around the handle while the slider has keyboard focus.

public string FocusColor { get; set; }

Property Value

string

LiveUpdate

Whether dragging writes the value back as it goes, or only on release. Arrow keys always write each step.

public bool LiveUpdate { get; set; }

Property Value

bool

Maximum

The value at the right end. One by default.

public float Maximum { get; set; }

Property Value

float

Minimum

The value at the left end. Zero by default.

public float Minimum { get; set; }

Property Value

float

Size

The size of the whole slider in pixels. The handle spans its full height.

public Size Size { get; set; }

Property Value

Size

SizeValue

The Size attribute's text form. See Size.

public string SizeValue { get; set; }

Property Value

string

Step

The increment the value snaps to, which arrow keys also move by. Zero means no snapping, and arrow keys then move a twentieth of the range.

[Range(0, 3.4028234663852886E+38)]
public float Step { get; set; }

Property Value

float

ThumbColor

The color of the handle. Falls back to FillColor.

public string ThumbColor { get; set; }

Property Value

string

ThumbWidth

How wide the handle is, in pixels. Ten by default.

[Range(1, 2147483647)]
public int ThumbWidth { get; set; }

Property Value

int

TrackColor

The full-length track behind the fill.

public string TrackColor { get; set; }

Property Value

string

TrackHeight

How tall the track is, in pixels, centered in the slider. Six by default.

[Range(1, 2147483647)]
public int TrackHeight { get; set; }

Property Value

int

Value

The current value, between Minimum and Maximum. Zero by default.

public float Value { get; set; }

Property Value

float

ValueBinding

The view model property the value is bound to, when Value was a binding; otherwise null.

public string ValueBinding { get; set; }

Property Value

string

ValueValue

The Value attribute's text: a literal, or a binding. Use Value in code.

public string ValueValue { get; set; }

Property Value

string