SvgImage.asset constructor

SvgImage.asset(
  1. String assetName, {
  2. AssetBundle? bundle,
  3. String? package,
  4. bool matchTextDirection = false,
  5. double? width,
  6. double? height,
  7. BoxFit fit = BoxFit.contain,
  8. AlignmentGeometry alignment = Alignment.center,
  9. bool allowDrawingOutsideViewBox = false,
  10. WidgetBuilder? placeholderBuilder,
  11. Color? color,
  12. BlendMode colorBlendMode = BlendMode.srcIn,
  13. String? semanticsLabel,
  14. bool excludeFromSemantics = false,
  15. Clip clipBehavior = Clip.hardEdge,
  16. bool cacheColorFilter = false,
  17. SvgTheme? theme,
  18. Key? key,
})

Implementation

SvgImage.asset(
  String assetName, {
  AssetBundle? bundle,
  String? package,
  this.matchTextDirection = false,
  this.width,
  this.height,
  this.fit = BoxFit.contain,
  this.alignment = Alignment.center,
  this.allowDrawingOutsideViewBox = false,
  this.placeholderBuilder,
  this.color,
  this.colorBlendMode = BlendMode.srcIn,
  this.semanticsLabel,
  this.excludeFromSemantics = false,
  this.clipBehavior = Clip.hardEdge,
  this.cacheColorFilter = false,
  this.theme,
  Key? key,
})  : svgProvider = SvgAsset(
        assetName,
        bundle: bundle,
        package: package,
      ),
      super(key: key);