NeumorphicToggle constructor

const NeumorphicToggle({
  1. NeumorphicToggleStyle? style = const NeumorphicToggleStyle(),
  2. Key? key,
  3. required List<ToggleElement> children,
  4. required Widget thumb,
  5. EdgeInsets padding = const EdgeInsets.all(2),
  6. Duration duration = const Duration(milliseconds: 200),
  7. int selectedIndex = 0,
  8. Curve alphaAnimationCurve = Curves.linear,
  9. Curve movingCurve = Curves.linear,
  10. dynamic onAnimationChangedFinished(
    1. int
    )?,
  11. ValueChanged<int>? onChanged,
  12. double height = 40,
  13. double? width,
  14. bool isEnabled = true,
  15. bool displayForegroundOnlyIfSelected = true,
})

Implementation

const NeumorphicToggle({
  this.style = const NeumorphicToggleStyle(),
  Key? key,
  required this.children,
  required this.thumb,
  this.padding = const EdgeInsets.all(2),
  this.duration = const Duration(milliseconds: 200),
  this.selectedIndex = 0,
  this.alphaAnimationCurve = Curves.linear,
  this.movingCurve = Curves.linear,
  this.onAnimationChangedFinished,
  this.onChanged,
  this.height = 40,
  this.width,
  this.isEnabled = true,
  this.displayForegroundOnlyIfSelected = true,
}) : super(key: key);