XImage constructor

XImage({
  1. Key? key,
  2. required String? image,
  3. BoxFit? fit,
  4. double? width,
  5. double? height,
  6. double? radius,
  7. XImageType type = XImageType.general,
  8. Color? background,
  9. bool hideIcon = false,
})

Implementation

XImage({Key? key, required this.image, this.fit, this.width, this.height, this.radius, this.type = XImageType.general, this.background, this.hideIcon = false}) : super(key: key) {
  iconSize = (this.height == null ? 40.w : this.height!) / 2;
  background = this.background ?? Colors.transparent;
}