DecorationImage constructor Null safety

const DecorationImage(
  1. {required ImageProvider image,
  2. ColorFilter? colorFilter,
  3. BoxFit? fit,
  4. @Default(Alignment.center) Alignment alignment,
  5. Rect? centerSlice,
  6. @Default(ImageRepeat.noRepeat) ImageRepeat repeat,
  7. @Default(false) bool matchTextDirection,
  8. @Default(1.0) double scale,
  9. @Default(1.0) double opacity,
  10. @Default(FilterQuality.low) FilterQuality filterQuality,
  11. @Default(false) bool invertColors,
  12. @Default(false) bool isAntiAlias}
)

Implementation

const factory DecorationImage({
  required ImageProvider image,
  ColorFilter? colorFilter,
  BoxFit? fit,
  @Default(Alignment.center) Alignment alignment,
  Rect? centerSlice,
  @Default(ImageRepeat.noRepeat) ImageRepeat repeat,
  @Default(false) bool matchTextDirection,
  @Default(1.0) double scale,
  @Default(1.0) double opacity,
  @Default(FilterQuality.low) FilterQuality filterQuality,
  @Default(false) bool invertColors,
  @Default(false) bool isAntiAlias,
}) = _DecorationImage;