GradientTween constructor

GradientTween({
  1. Gradient? begin,
  2. Gradient? end,
  3. bool isAgressive = true,
  4. GradientCopyWith overrideCopyWith = spectrumCopyWith,
})

An interpolation between two Gradients.

This class specializes the interpolation of Tween<Gradient> to use Gradient.lerp and bespoke IntermediateGradients.

If needed, consider overriding IntermediateGradient._copyWith by providing a custom GradientCopyWith during construction as overrideCopyWith.

See Tween for a discussion on how to use interpolation objects.

Implementation

GradientTween({
  Gradient? begin,
  Gradient? end,
  this.isAgressive = true,
  GradientCopyWith overrideCopyWith = spectrumCopyWith,
})  : _copyWith = overrideCopyWith,
      super(begin: begin, end: end);