onChanged property

  1. @override
ValueChanged<double>? onChanged
final

Signature for a callback that report that a value was changed for a marker pointer.

This snippet shows how to call onChanged function inSfLinearGauge.


SfLinearGauge(
markerPointers: [
LinearWidgetPointer(
   value: _pointerValue,
   child: Container(
      height: 20,
      width: 20,
      color: Colors.red),
   onChanged: (double value){
     setState((){
        _pointerValue = value;
     })
   }
)])

Implementation

@override
final ValueChanged<double>? onChanged;