MAUI

  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class SfRangeSlider

    Show / Hide Table of Contents

    Class SfRangeSlider

    A material design for SfRangeSlider.

    Inheritance
    System.Object
    SfView
    RangeView<System.Double>
    RangeSliderBase<System.Double>
    SfRangeSlider
    Implements
    IDrawableLayout
    Microsoft.Maui.Graphics.IDrawable
    Microsoft.Maui.IAbsoluteLayout
    Microsoft.Maui.ILayout
    Microsoft.Maui.IView
    Microsoft.Maui.IElement
    Microsoft.Maui.ITransform
    Microsoft.Maui.IContainer
    System.Collections.Generic.IList<Microsoft.Maui.IView>
    System.Collections.Generic.ICollection<Microsoft.Maui.IView>
    System.Collections.Generic.IEnumerable<Microsoft.Maui.IView>
    System.Collections.IEnumerable
    Microsoft.Maui.ISafeAreaView
    Microsoft.Maui.IPadding
    Microsoft.Maui.IVisualTreeElement
    INumericElement
    IOrientationElement
    Inherited Members
    RangeSliderBase<Double>.RangeStartProperty
    RangeSliderBase<Double>.RangeEndProperty
    RangeSliderBase<Double>.StartThumbIconProperty
    RangeSliderBase<Double>.EndThumbIconProperty
    RangeSliderBase<Double>.DragBehaviorProperty
    RangeSliderBase<Double>.EnableIntervalSelectionProperty
    RangeSliderBase<Double>.RangeStart
    RangeSliderBase<Double>.RangeEnd
    RangeSliderBase<Double>.StartThumbIcon
    RangeSliderBase<Double>.EndThumbIcon
    RangeSliderBase<Double>.DragBehavior
    RangeSliderBase<Double>.EnableIntervalSelection
    RangeView<Double>.MinimumProperty
    RangeView<Double>.MaximumProperty
    RangeView<Double>.IntervalProperty
    RangeView<Double>.MinorTicksPerIntervalProperty
    RangeView<Double>.ShowTicksProperty
    RangeView<Double>.ShowLabelsProperty
    RangeView<Double>.ShowDividersProperty
    RangeView<Double>.IsInversedProperty
    RangeView<Double>.TrackExtentProperty
    RangeView<Double>.LabelsPlacementProperty
    RangeView<Double>.EdgeLabelsPlacementProperty
    RangeView<Double>.EnableDeferredUpdateProperty
    RangeView<Double>.DeferredUpdateDelayProperty
    RangeView<Double>.TrackStyleProperty
    RangeView<Double>.ThumbStyleProperty
    RangeView<Double>.ThumbOverlayStyleProperty
    RangeView<Double>.DividerStyleProperty
    RangeView<Double>.MajorTickStyleProperty
    RangeView<Double>.MinorTickStyleProperty
    RangeView<Double>.LabelStyleProperty
    RangeView<Double>.TooltipProperty
    RangeView<Double>.DragStartedCommandProperty
    RangeView<Double>.DragStartedCommandParameterProperty
    RangeView<Double>.DragCompletedCommandProperty
    RangeView<Double>.DragCompletedCommandParameterProperty
    RangeView<Double>.ChangeVisualState()
    RangeView<Double>.OnBindingContextChanged()
    RangeView<Double>.OnPropertyChanged(String)
    RangeView<Double>.OnHandlerChanged()
    RangeView<Double>.MeasureContent(Double, Double)
    RangeView<Double>.ArrangeContent(Rect)
    RangeView<Double>.OnDraw(ICanvas, RectF)
    RangeView<Double>.Minimum
    RangeView<Double>.Maximum
    RangeView<Double>.Interval
    RangeView<Double>.MinorTicksPerInterval
    RangeView<Double>.ShowDividers
    RangeView<Double>.ShowTicks
    RangeView<Double>.ShowLabels
    RangeView<Double>.IsInversed
    RangeView<Double>.TrackExtent
    RangeView<Double>.LabelsPlacement
    RangeView<Double>.EdgeLabelsPlacement
    RangeView<Double>.EnableDeferredUpdate
    RangeView<Double>.DeferredUpdateDelay
    RangeView<Double>.TrackStyle
    RangeView<Double>.ThumbStyle
    RangeView<Double>.ThumbOverlayStyle
    RangeView<Double>.DividerStyle
    RangeView<Double>.MajorTickStyle
    RangeView<Double>.MinorTickStyle
    RangeView<Double>.LabelStyle
    RangeView<Double>.Tooltip
    RangeView<Double>.DragStartedCommand
    RangeView<Double>.DragStartedCommandParameter
    RangeView<Double>.DragCompletedCommand
    RangeView<Double>.DragCompletedCommandParameter
    RangeView<Double>.ValueChangeStart
    RangeView<Double>.ValueChangeEnd
    RangeView<Double>.LabelCreated
    SfView.MeasureOverride(Double, Double)
    SfView.ArrangeOverride(Rect)
    SfView.OnMeasure(Double, Double)
    SfView.IDrawableLayout.InvalidateDrawable()
    SfView.Children
    SfView.ClipToBounds
    SfView.Padding
    SfView.IDrawableLayout.DrawingOrder
    Namespace: Syncfusion.Maui.Sliders
    Assembly: Syncfusion.Maui.Sliders.dll
    Syntax
    public class SfRangeSlider : RangeSliderBase<double>, IDrawableLayout, IDrawable, IAbsoluteLayout, ILayout, IView, IElement, ITransform, IContainer, IList<IView>, ICollection<IView>, IEnumerable<IView>, IEnumerable, ISafeAreaView, IPadding, IVisualTreeElement, ITouchListener, ITapGestureListener, IPanGestureListener, IGestureListener, IRangeView<double>, INumericElement, IOrientationElement

    Constructors

    SfRangeSlider()

    Initializes a new instance of the SfRangeSlider class.

    Declaration
    public SfRangeSlider()

    Fields

    NumberFormatProperty

    The backing store for the NumberFormat field.

    Declaration
    public static readonly BindableProperty NumberFormatProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Microsoft.Maui.Controls.BindableProperty.

    OrientationProperty

    The backing store for the Orientation field.

    Declaration
    public static readonly BindableProperty OrientationProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Microsoft.Maui.Controls.BindableProperty.

    StepSizeProperty

    The backing store for the StepSize field.

    Declaration
    public static readonly BindableProperty StepSizeProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Microsoft.Maui.Controls.BindableProperty.

    Properties

    NumberFormat

    Gets or sets the value to format the label text.

    Declaration
    public string NumberFormat { get; set; }
    Property Value
    Type Description
    System.String

    Defaults to 0.##.

    Examples

    Snippet for SfRangeSlider

    • XAML
    • C#
    <sliders:SfRangeSlider ShowLabels = "True"
                           NumberFormat = "0.0" />
    SfRangeSlider rangeSlider = new SfRangeSlider()
    {
        ShowLabels = true,
        NumberFormat = "0.0",
    };

    Orientation

    Gets or sets the orientation of the RangeSlider.

    If you set this property to Horizontal, the slider will be render from left to right. If you set this property to Vertical, the slider will be render from bottom to top.

    Declaration
    public SliderOrientation Orientation { get; set; }
    Property Value
    Type Description
    SliderOrientation

    Defaults to Horizontal.

    Examples

    Snippet for SfRangeSlider

    • XAML
    • C#
    <sliders:SfRangeSlider Orientation = "Vertical" />
    SfRangeSlider slider = new SfRangeSlider()
    {
        Orientation = SliderOrientation.Vertical
    };

    StepSize

    Gets or sets the value indicating whether to select the discrete value.

    For example, if Minimum is 0.0 and Maximum is 10.0 and StepSize is 2.0, then the slider will move the thumb positions to 0.0, 2.0, 4.0, 6.0, 8.0 and 10.0 only.

    Declaration
    public double StepSize { get; set; }
    Property Value
    Type Description
    System.Double

    Defaults to 0d.

    Remarks

    StepSize does not work with BetweenThumbs.

    Examples

    Snippet for SfRangeSlider

    • XAML
    • C#
    <sliders:SfRangeSlider Minimum="0"
                           Maximum="10" 
                           StepSize="2">
    </sliders:SfRangeSlider>
    SfRangeSlider rangeSlider = new SfRangeSlider()
    { 
         Minimum = 0,
         Maximum = 10,
         StepSize = 2
    };

    Events

    ValueChanged

    Represents the ValueChanged event, which occurs when the user is done selecting a new value for the Range Slider.

    Declaration
    public event EventHandler<RangeSliderValueChangedEventArgs> ValueChanged
    Event Type
    Type Description
    System.EventHandler<RangeSliderValueChangedEventArgs>
    Examples
    • XAML
    • C#
    <sliders:SfRangeSlider ValueChanged="OnValueChanged" />
    SfRangeSlider rangeSlider = new SfRangeSlider()
    {
        ValueChanged += OnValueChanged
    }
    
    private void OnValueChanged(object sender, RangeSliderValueChangedEventArgs e)
    {
    }

    ValueChanging

    Represents the ValueChanging event, which occurs when the user is selecting a new value for the Range Slider by dragging any one of the thumb.

    Declaration
    public event EventHandler<RangeSliderValueChangingEventArgs> ValueChanging
    Event Type
    Type Description
    System.EventHandler<RangeSliderValueChangingEventArgs>
    Examples
    • XAML
    • C#
    <sliders:SfRangeSlider ValueChanging="OnValueChanging" />
    SfRangeSlider rangeSlider = new SfRangeSlider()
    {
        ValueChanging += OnValueChanging
    }
    
    private void OnValueChanging(object sender, RangeSliderValueChangingEventArgs e)
    {
    }

    Explicit Interface Implementations

    INumericElement.OnNumberFormatChanged(String, String)

    Declaration
    void INumericElement.OnNumberFormatChanged(string oldValue, string newValue)
    Parameters
    Type Name Description
    System.String oldValue
    System.String newValue

    INumericElement.OnStepChanged()

    Declaration
    void INumericElement.OnStepChanged()

    IOrientationElement.OnOrientationChanged(SliderOrientation)

    Declaration
    void IOrientationElement.OnOrientationChanged(SliderOrientation newValue)
    Parameters
    Type Name Description
    SliderOrientation newValue

    Implements

    IDrawableLayout
    Microsoft.Maui.Graphics.IDrawable
    Microsoft.Maui.IAbsoluteLayout
    Microsoft.Maui.ILayout
    Microsoft.Maui.IView
    Microsoft.Maui.IElement
    Microsoft.Maui.ITransform
    Microsoft.Maui.IContainer
    System.Collections.Generic.IList<>
    System.Collections.Generic.ICollection<>
    System.Collections.Generic.IEnumerable<>
    System.Collections.IEnumerable
    Microsoft.Maui.ISafeAreaView
    Microsoft.Maui.IPadding
    Microsoft.Maui.IVisualTreeElement
    INumericElement
    IOrientationElement
    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved