Class Slider

Definition

Namespace:
Tizen.NUI.Components
Assembly:
Tizen.NUI.Components.dll
API Level:
6

A slider lets users select a value from a continuous or discrete range of values by moving the slider thumb.

C#
Copy
public class Slider : Control, IDynamicResourceHandler, IElement, INameScope, IElementController, System.IDisposable, IResourcesProvider, IAtspiValue
Inheritance
Implements

Constructors

View Source

Slider()

The constructor of the Slider class.

Declaration
C#
Copy
public Slider()
API Level: 6
View Source

Slider(String)

The constructor of the Slider class with specific style.

Declaration
C#
Copy
public Slider(string style)
Parameters
Type Name Description
String style

The string to initialize the Slider

API Level: 8
View Source

Slider(SliderStyle)

The constructor of the Slider class with specific style.

Declaration
C#
Copy
public Slider(SliderStyle sliderStyle)
Parameters
Type Name Description
SliderStyle sliderStyle

The style object to initialize the Slider

API Level: 8

Fields

View Source

BgTrackColorProperty

BgTrackColorProperty

Declaration
C#
Copy
public static readonly BindableProperty BgTrackColorProperty
Field Value
Type Description
BindableProperty
View Source

CurrentValueProperty

Bindable property of CurrentValue Hidden API, used for NUI XAML data binding

Declaration
C#
Copy
public static readonly BindableProperty CurrentValueProperty
Field Value
Type Description
BindableProperty
View Source

DirectionProperty

DirectionProperty

Declaration
C#
Copy
public static readonly BindableProperty DirectionProperty
Field Value
Type Description
BindableProperty
View Source

DiscreteValueProperty

DiscreteValueProperty

Declaration
C#
Copy
public static readonly BindableProperty DiscreteValueProperty
Field Value
Type Description
BindableProperty
View Source

HighIndicatorImageURLProperty

HighIndicatorImageURLProperty

Declaration
C#
Copy
public static readonly BindableProperty HighIndicatorImageURLProperty
Field Value
Type Description
BindableProperty
View Source

HighIndicatorSizeProperty

HighIndicatorSizeProperty

Declaration
C#
Copy
public static readonly BindableProperty HighIndicatorSizeProperty
Field Value
Type Description
BindableProperty
View Source

HighIndicatorTextContentProperty

HighIndicatorTextContentProperty

Declaration
C#
Copy
public static readonly BindableProperty HighIndicatorTextContentProperty
Field Value
Type Description
BindableProperty
View Source

IndicatorProperty

SpaceBetweenTrackAndIndicatorProperty

Declaration
C#
Copy
public static readonly BindableProperty IndicatorProperty
Field Value
Type Description
BindableProperty
View Source

IsDiscreteProperty

IsDiscreteProperty

Declaration
C#
Copy
public static readonly BindableProperty IsDiscreteProperty
Field Value
Type Description
BindableProperty
View Source

IsValueShownProperty

IsValueShownProperty

Declaration
C#
Copy
public static readonly BindableProperty IsValueShownProperty
Field Value
Type Description
BindableProperty
View Source

LowIndicatorImageURLProperty

LowIndicatorImageURLProperty

Declaration
C#
Copy
public static readonly BindableProperty LowIndicatorImageURLProperty
Field Value
Type Description
BindableProperty
View Source

LowIndicatorSizeProperty

LowIndicatorSizeProperty

Declaration
C#
Copy
public static readonly BindableProperty LowIndicatorSizeProperty
Field Value
Type Description
BindableProperty
View Source

LowIndicatorTextContentProperty

LowIndicatorTextContentProperty

Declaration
C#
Copy
public static readonly BindableProperty LowIndicatorTextContentProperty
Field Value
Type Description
BindableProperty
View Source

MaxValueProperty

MaxValueProperty

Declaration
C#
Copy
public static readonly BindableProperty MaxValueProperty
Field Value
Type Description
BindableProperty
View Source

MinValueProperty

MinValueProperty

Declaration
C#
Copy
public static readonly BindableProperty MinValueProperty
Field Value
Type Description
BindableProperty
View Source

SlidedTrackColorProperty

SlidedTrackColorProperty

Declaration
C#
Copy
public static readonly BindableProperty SlidedTrackColorProperty
Field Value
Type Description
BindableProperty
View Source

SpaceBetweenTrackAndIndicatorProperty

SpaceBetweenTrackAndIndicatorProperty

Declaration
C#
Copy
public static readonly BindableProperty SpaceBetweenTrackAndIndicatorProperty
Field Value
Type Description
BindableProperty
View Source

ThumbColorProperty

ThumbColorProperty

Declaration
C#
Copy
public static readonly BindableProperty ThumbColorProperty
Field Value
Type Description
BindableProperty
View Source

ThumbImageUrlProperty

ThumbImageUrlProperty

Declaration
C#
Copy
public static readonly BindableProperty ThumbImageUrlProperty
Field Value
Type Description
BindableProperty
View Source

ThumbImageURLProperty

ThumbImageURLProperty

Declaration
C#
Copy
public static readonly BindableProperty ThumbImageURLProperty
Field Value
Type Description
BindableProperty
View Source

ThumbImageURLSelectorProperty

ThumbImageURLSelectorProperty

Declaration
C#
Copy
public static readonly BindableProperty ThumbImageURLSelectorProperty
Field Value
Type Description
BindableProperty
View Source

ThumbSizeProperty

ThumbSizeProperty

Declaration
C#
Copy
public static readonly BindableProperty ThumbSizeProperty
Field Value
Type Description
BindableProperty
View Source

TrackThicknessProperty

TrackThicknessProperty

Declaration
C#
Copy
public static readonly BindableProperty TrackThicknessProperty
Field Value
Type Description
BindableProperty
View Source

ValueIndicatorSizeProperty

ValueIndicatorSizeProperty

Declaration
C#
Copy
public static readonly BindableProperty ValueIndicatorSizeProperty
Field Value
Type Description
BindableProperty
View Source

ValueIndicatorTextProperty

ValueIndicatorTextProperty

Declaration
C#
Copy
public static readonly BindableProperty ValueIndicatorTextProperty
Field Value
Type Description
BindableProperty
View Source

ValueIndicatorUrlProperty

ValueIndicatorUrlProperty

Declaration
C#
Copy
public static readonly BindableProperty ValueIndicatorUrlProperty
Field Value
Type Description
BindableProperty
View Source

WarningSlidedTrackColorProperty

WarningSlidedTrackColorProperty

Declaration
C#
Copy
public static readonly BindableProperty WarningSlidedTrackColorProperty
Field Value
Type Description
BindableProperty
View Source

WarningStartValueProperty

WarningStartValueProperty

Declaration
C#
Copy
public static readonly BindableProperty WarningStartValueProperty
Field Value
Type Description
BindableProperty
View Source

WarningThumbColorProperty

WarningThumbColorProperty

Declaration
C#
Copy
public static readonly BindableProperty WarningThumbColorProperty
Field Value
Type Description
BindableProperty
View Source

WarningThumbImageUrlProperty

WarningThumbImageUrlProperty

Declaration
C#
Copy
public static readonly BindableProperty WarningThumbImageUrlProperty
Field Value
Type Description
BindableProperty
View Source

WarningTrackColorProperty

WarningTrackColorProperty

Declaration
C#
Copy
public static readonly BindableProperty WarningTrackColorProperty
Field Value
Type Description
BindableProperty

Properties

View Source

BgTrackColor

Gets or sets the color of the background track image object.

Declaration
C#
Copy
public Color BgTrackColor { get; set; }
Property Value
Type Description
Color
API Level: 6
View Source

CurrentValue

Gets or sets the current value of slider.

Declaration
C#
Copy
public float CurrentValue { get; set; }
Property Value
Type Description
Single
API Level: 6
View Source

Direction

Gets or sets the direction type of slider.

Declaration
C#
Copy
public Slider.DirectionType Direction { get; set; }
Property Value
Type Description
Slider.DirectionType
API Level: 6
View Source

DiscreteValue

Gets or sets the discrete value of slider.

Declaration
C#
Copy
public float DiscreteValue { get; set; }
Property Value
Type Description
Single
Remarks

The discrete value is evenly spaced between MinValue and MaxValue. For example, MinValue is 0, MaxValue is 100, and DiscreteValue is 20. Then, the thumb can only go to 0, 20, 40, 60, 80, and 100. The default is 0.

API Level: 9
View Source

HighIndicatorImageURL

Gets or sets the resource url of the high indicator image object.

Declaration
C#
Copy
public string HighIndicatorImageURL { get; set; }
Property Value
Type Description
String
API Level: 6
View Source

HighIndicatorSize

Gets or sets the size of the high indicator object(image or text).

Declaration
C#
Copy
public Size HighIndicatorSize { get; set; }
Property Value
Type Description
Size
API Level: 6
View Source

HighIndicatorTextContent

Gets or sets the text content of the high indicator text object.

Declaration
C#
Copy
public string HighIndicatorTextContent { get; set; }
Property Value
Type Description
String
API Level: 6
View Source

Indicator

Gets or sets the indicator type, arrow or sign.

Declaration
C#
Copy
public Slider.IndicatorType Indicator { get; set; }
Property Value
Type Description
Slider.IndicatorType
API Level: 6
View Source

IsDiscrete

Flag to decide whether the thumb snaps to the nearest discrete value when the user drags the thumb or taps.

The default value is false.

Declaration
C#
Copy
public bool IsDiscrete { get; set; }
Property Value
Type Description
Boolean
API Level: 9
View Source

IsValueShown

Flag to decide whether the value indicator is shown

Declaration
C#
Copy
public bool IsValueShown { get; set; }
Property Value
Type Description
Boolean
API Level: 9
View Source

LowIndicatorImageURL

Gets or sets the resource url of the low indicator image object.

Declaration
C#
Copy
public string LowIndicatorImageURL { get; set; }
Property Value
Type Description
String
API Level: 6
View Source

LowIndicatorSize

Gets or sets the size of the low indicator object(image or text).

Declaration
C#
Copy
public Size LowIndicatorSize { get; set; }
Property Value
Type Description
Size
API Level: 6
View Source

LowIndicatorTextContent

Gets or sets the text content of the low indicator text object.

Declaration
C#
Copy
public string LowIndicatorTextContent { get; set; }
Property Value
Type Description
String
API Level: 6
View Source

MaxValue

Gets or sets the maximum value of slider.

Declaration
C#
Copy
public float MaxValue { get; set; }
Property Value
Type Description
Single
API Level: 6
View Source

MinValue

Gets or sets the minimum value of slider.

Declaration
C#
Copy
public float MinValue { get; set; }
Property Value
Type Description
Single
API Level: 6
View Source

SlidedTrackColor

Gets or sets the color of the slided track image object.

Declaration
C#
Copy
public Color SlidedTrackColor { get; set; }
Property Value
Type Description
Color
API Level: 6
View Source

SpaceBetweenTrackAndIndicator

Gets or sets the value of the space between track and indicator.

Declaration
C#
Copy
public uint SpaceBetweenTrackAndIndicator { get; set; }
Property Value
Type Description
UInt32
API Level: 6
View Source

Style

Return currently applied style.

Declaration
C#
Copy
public SliderStyle Style { get; }
Property Value
Type Description
SliderStyle
Remarks

Modifying contents in style may cause unexpected behaviour.

API Level: 8
View Source

ThumbColor

Gets or sets the color of the thumb image object.

Declaration
C#
Copy
public Color ThumbColor { get; set; }
Property Value
Type Description
Color
API Level: 8
View Source

ThumbImageUrl

Gets or sets the Url of the thumb image.

Declaration
C#
Copy
public Selector<string> ThumbImageUrl { get; set; }
Property Value
Type Description
Selector<String>
API Level: 9
View Source

ThumbImageURL

Gets or sets the resource url of the thumb image object.

Please use ThumbImageUrl property.

Declaration
C#
Copy
public string ThumbImageURL { get; set; }
Property Value
Type Description
String
API Level: 6
View Source

ThumbImageURLSelector

Gets or sets the resource url selector of the thumb image object. Getter returns copied selector value if exist, null otherwise.

Please use ThumbImageUrl property.

Declaration
C#
Copy
public StringSelector ThumbImageURLSelector { get; set; }
Property Value
Type Description
StringSelector
API Level: 6
View Source

ThumbSize

Gets or sets the size of the thumb image object.

Declaration
C#
Copy
public Size ThumbSize { get; set; }
Property Value
Type Description
Size
API Level: 6
View Source

TrackThickness

Gets or sets the thickness value of the track.

Declaration
C#
Copy
public uint TrackThickness { get; set; }
Property Value
Type Description
UInt32
API Level: 6
View Source

ValueIndicatorSize

Gets or sets the size of the value indicator image object.

Declaration
C#
Copy
public Size ValueIndicatorSize { get; set; }
Property Value
Type Description
Size
API Level: 9
View Source

ValueIndicatorText

Gets or sets the text of value indicator.

Declaration
C#
Copy
public string ValueIndicatorText { get; set; }
Property Value
Type Description
String
API Level: 9
View Source

ValueIndicatorUrl

Gets or sets the resource url of the value indicator image object.

Declaration
C#
Copy
public string ValueIndicatorUrl { get; set; }
Property Value
Type Description
String
API Level: 9
View Source

WarningSlidedTrackColor

Gets or sets the color of the warning slided track image object.

Declaration
C#
Copy
public Color WarningSlidedTrackColor { get; set; }
Property Value
Type Description
Color
View Source

WarningStartValue

Gets or sets the warning start value between minimum value and maximum value of slider.

Declaration
C#
Copy
public float WarningStartValue { get; set; }
Property Value
Type Description
Single
View Source

WarningThumbColor

Gets or sets the color of the warning thumb image object.

Declaration
C#
Copy
public Color WarningThumbColor { get; set; }
Property Value
Type Description
Color
View Source

WarningThumbImageUrl

Gets or sets the Url of the warning thumb image.

Declaration
C#
Copy
public Selector<string> WarningThumbImageUrl { get; set; }
Property Value
Type Description
Selector<String>
View Source

WarningTrackColor

Gets or sets the color of the warning track image object.

Declaration
C#
Copy
public Color WarningTrackColor { get; set; }
Property Value
Type Description
Color

Methods

View Source

ApplyStyle(ViewStyle)

Apply style to scrollbar.

Declaration
C#
Copy
public override void ApplyStyle(ViewStyle viewStyle)
Parameters
Type Name Description
ViewStyle viewStyle

The style to apply.

Overrides
API Level: 8
View Source

CreateViewStyle()

Get Slider style.

Declaration
C#
Copy
protected override ViewStyle CreateViewStyle()
Returns
Type Description
ViewStyle

The default slider style.

Overrides
API Level: 8
View Source

Dispose(DisposeTypes)

Dispose Slider.

Declaration
C#
Copy
protected override void Dispose(DisposeTypes type)
Parameters
Type Name Description
DisposeTypes type

Dispose type.

Overrides
API Level: 6
View Source

OnEnabled(Boolean)

Internal callback of enabled property changes. Inherited view can override this method to implements enabled property changes.

Declaration
C#
Copy
protected override void OnEnabled(bool enabled)
Parameters
Type Name Description
Boolean enabled
Overrides
View Source

OnFocusGained()

Focus gained callback.

Declaration
C#
Copy
public override void OnFocusGained()
Overrides
API Level: 8
View Source

OnFocusLost()

Focus Lost callback.

Declaration
C#
Copy
public override void OnFocusLost()
Overrides
API Level: 8
View Source

OnInitialize()

Initialize AT-SPI object.

Declaration
C#
Copy
public override void OnInitialize()
Overrides
View Source

OnKey(Key)

Called after a key event is received by the view that has had its focus set.

Declaration
C#
Copy
public override bool OnKey(Key key)
Parameters
Type Name Description
Key key

The key event.

Returns
Type Description
Boolean

True if the key event should be consumed.

Overrides
View Source

OnKeyboardEnter()

This method is called when the control has enter pressed on it.
Derived classes should override this to perform custom actions.

Declaration
C#
Copy
public override bool OnKeyboardEnter()
Returns
Type Description
Boolean

True if this control supported this action.

Overrides
View Source

OnUpdate()

Update Slider by style.

Declaration
C#
Copy
protected override void OnUpdate()
Overrides

Events

View Source

SlidingFinished

The sliding finished event handler.

Declaration
C#
Copy
public event EventHandler<SliderSlidingFinishedEventArgs> SlidingFinished
Event Type
Type Description
EventHandler<SliderSlidingFinishedEventArgs>
API Level: 8
View Source

SlidingStarted

The sliding started event handler.

Declaration
C#
Copy
public event EventHandler<SliderSlidingStartedEventArgs> SlidingStarted
Event Type
Type Description
EventHandler<SliderSlidingStartedEventArgs>
API Level: 8
View Source

ValueChanged

The value changed event handler.

Declaration
C#
Copy
public event EventHandler<SliderValueChangedEventArgs> ValueChanged
Event Type
Type Description
EventHandler<SliderValueChangedEventArgs>
API Level: 8

Explicit Interface Implementations

View Source

IAtspiValue.AccessibilityGetCurrent()

Gets the current value for Accessibility.

Declaration
C#
Copy
double IAtspiValue.AccessibilityGetCurrent()
Returns
Type Description
Double
View Source

IAtspiValue.AccessibilityGetMaximum()

Gets maximum value for Accessibility.

Declaration
C#
Copy
double IAtspiValue.AccessibilityGetMaximum()
Returns
Type Description
Double
View Source

IAtspiValue.AccessibilityGetMinimum()

Gets minimum value for Accessibility.

Declaration
C#
Copy
double IAtspiValue.AccessibilityGetMinimum()
Returns
Type Description
Double
View Source

IAtspiValue.AccessibilityGetMinimumIncrement()

Gets minimum increment for Accessibility.

Declaration
C#
Copy
double IAtspiValue.AccessibilityGetMinimumIncrement()
Returns
Type Description
Double
View Source

IAtspiValue.AccessibilityGetValueText()

Formatted current value.

Declaration
C#
Copy
string IAtspiValue.AccessibilityGetValueText()
Returns
Type Description
String
View Source

IAtspiValue.AccessibilitySetCurrent(Double)

Sets the current value using Accessibility.

Declaration
C#
Copy
bool IAtspiValue.AccessibilitySetCurrent(double value)
Parameters
Type Name Description
Double value
Returns
Type Description
Boolean

Implements

Extension Methods