RatingBarFlutter constructor

RatingBarFlutter({
  1. Key? key,
  2. int maxRating = 5,
  3. required RatingCallback? onRatingChanged,
  4. required IconData filledIcon,
  5. required IconData emptyIcon,
  6. IconData? halfFilledIcon,
  7. bool isHalfAllowed = false,
  8. Alignment aligns = Alignment.centerLeft,
  9. double initialRating = 0.0,
  10. Color? filledColor,
  11. Color emptyColor = Colors.grey,
  12. Color? halfFilledColor,
  13. double size = 40,
})

Implementation

RatingBarFlutter({
  Key? key,
  this.maxRating = 5,
  required this.onRatingChanged,
  required this.filledIcon,
  required this.emptyIcon,
  this.halfFilledIcon,
  this.isHalfAllowed = false,
  this.aligns = Alignment.centerLeft,
  this.initialRating = 0.0,
  this.filledColor,
  this.emptyColor = Colors.grey,
  this.halfFilledColor,
  this.size = 40,
})  : _readOnly = false,
      assert(!isHalfAllowed || halfFilledIcon != null),
      super(key: key);