Class ScrollBar

Definition

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

The ScrollBar class of nui component. It allows users to recognize the direction and the range of lists/content.

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

Please note that this class will be replaced with Scrollbar class in the near future.

Constructors

View Source

ScrollBar()

The constructor of ScrollBar.

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

ScrollBar(String)

The constructor of ScrollBar with specific style.

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

style name

View Source

ScrollBar(ScrollBarStyle)

The constructor of ScrollBar with specific style.

Declaration
C#
Copy
public ScrollBar(ScrollBarStyle scrollBarStyle)
Parameters
Type Name Description
ScrollBarStyle scrollBarStyle

The style object to initialize the ScrollBar.

Fields

View Source

CurrentValueProperty

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

DirectionProperty

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

DurationProperty

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

MaxValueProperty

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

MinValueProperty

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

ThumbColorProperty

ThumbColorProperty

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

ThumbSizeProperty

ThumbSizeProperty

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

TrackColorProperty

TrackColorProperty

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

TrackImageURLProperty

TrackImageURLProperty

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

Properties

View Source

CurrentValue

The property to get/set the current value of the ScrollBar.

Declaration
C#
Copy
public int CurrentValue { get; set; }
Property Value
Type Description
Int32
Examples
Copy
ScrollBar scroll; scroll.MaxValue = 100; scroll.MinValue = 0; try { scroll.CurrentValue = 50; } catch(ArgumentOutOfRangeException e) { Tizen.Log.Error(LogTag, "Failed to set Current value : " + e.Message); }
API Level: 6
View Source

Direction

The property to get/set the direction of the ScrollBar.

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

Duration

Property to set/get animation duration.

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

MaxValue

The property to get/set the max value of the ScrollBar.

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

MinValue

The property to get/set the min value of the ScrollBar.

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

ThumbColor

The property to get/set the color of the thumb object.

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

ThumbSize

The property to get/set the size of the thumb object.

Declaration
C#
Copy
public Size ThumbSize { get; set; }
Property Value
Type Description
Size
Examples
Copy
ScrollBar scroll; try { scroll.ThumbSize = new Size(500, 10, 0); } catch(InvalidOperationException e) { Tizen.Log.Error(LogTag, "Failed to set ThumbSize value : " + e.Message); }
API Level: 6
View Source

TrackColor

The property to get/set the color of the track object.

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

TrackImageURL

The property to get/set the image URL of the track object.

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

Methods

View Source

ApplyStyle(ViewStyle)

Apply style instance to the view. Basically it sets the bindable property to the value of the bindable property with same name in the style.

Declaration
C#
Copy
public override void ApplyStyle(ViewStyle style)
Parameters
Type Name Description
ViewStyle style
Overrides
View Source

CreateViewStyle()

Get Scrollbar style.

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

The default scrollbar style.

Overrides
View Source

Dispose(DisposeTypes)

Dispose ScrollBar.

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

The DisposeTypes value.

Overrides
API Level: 6
View Source

OnInitialize()

Overrides the parent method.

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

SetCurrentValue(Int32, Boolean)

Method to set current value. The thumb object would move to the corresponding position with animation or not.

Declaration
C#
Copy
public void SetCurrentValue(int currentValue, bool enableAnimation = true)
Parameters
Type Name Description
Int32 currentValue

The special current value.

Boolean enableAnimation

Enable move with animation or not, the default value is true.

Examples
Copy
ScrollBar scroll; scroll.MinValue = 0; scroll.MaxValue = 100; try { scroll.SetCurrentValue(50); } catch(ArgumentOutOfRangeException e) { Tizen.Log.Error(LogTag, "Failed to set current value : " + e.Message); }
API Level: 6

Implements

Extension Methods