WheelSegment constructor

WheelSegment(
  1. String label,
  2. int value, {
  3. Color? color,
  4. String? path,
  5. Image? image,
  6. double? probability,
})

Creates a new WheelSegment.

Implementation

WheelSegment(
  this.label,
  this.value, {
  Color? color,
  this.path,
  this.image,
  this.probability,
}) : color = color ??
          Colors.primaries[Random().nextInt(Colors.primaries.length)];