WidgetSpin constructor

const WidgetSpin({
  1. Key? key,
  2. int spinCount = 1,
  3. bool is3D = false,
  4. bool isReversed = false,
  5. SpinAxis spinAxis = SpinAxis.y,
  6. Alignment alignment = Alignment.center,
  7. bool repeat = false,
  8. Duration duration = const Duration(seconds: 1),
  9. Curve curve = Curves.linear,
  10. AnimationController? controller,
  11. required Widget child,
})

Creates a WidgetSpin with default values.

The spinCount is the number of spins the widget will have per duration cicle.

The is3D is if the widget will have perspective.

The spinAxis is the axis (x, y or z) in chich the spin will be applied to the widget.

The alignment is the aligment of the spin.

The repeat is if the animation spin will be repeated.

The duration is the duration of the spinCount.

The curve is the curve animation of the spin

The controller is the animation controller to control the spin widget

The child is the widget to apply the spin animation.

Implementation

const WidgetSpin({
  super.key,
  this.spinCount = 1,
  this.is3D = false,
  this.isReversed = false,
  this.spinAxis = SpinAxis.y,
  this.alignment = Alignment.center,
  this.repeat = false,
  this.duration = const Duration(seconds: 1),
  this.curve = Curves.linear,
  this.controller,
  required this.child,
});