Arc Slider

Arc slider for Flutter.

Example 01

Getting Started

Installation

Add


arc_slider : ^lastest_version

to your pubspec.yaml, and run

flutter packages get

in your project's root directory.

Basic Usage

Import it to your project file

import 'package:arc_slider/arc_slider.dart';

And add it in its most basic form like it:

final slider = ArcSlider(
                      trackWidth: 14,
                      trackColor:Colors.red.
                      onChange : (double value) {
                        print(value);
                      });

ArcSlider parameters

ParameterDefaultDescription
min double0The minimum value the user can select. Must be less than or equal to max.
max double100The maximum value the user can select. Must be greater than or equal to min.
onChange OnChange(double value)Called during a drag when the user is selecting a new value for the slider by dragging.

ArcSlider width parameters

ParameterDefaultDescription
trackWidth double22The width of the slider's track.
progressBarWidth double22The width of the slider's progress bar.
thumbsize double44The size of the slider's thumb.

Arc slider color parameters

ParameterDefaultDescription
trackColor Colorwhite with opacityThe color of the slider's track.
fillColor ColorblackThe color of the slider's fill bar.
dotColor ColorblackThe color of the slider's dot.
thumbColor ColorblackThe color of the slider's thumb.

Libraries

arc_slider
Arcpainter