SVGAsset constructor

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

Implementation

SVGAsset(
  String assetName, {
  super.key,
  double? size,
  double? height,
  double? width,
  super.matchTextDirection = false,
  super.bundle,
  super.package,
  super.fit = BoxFit.contain,
  super.alignment = Alignment.center,
  super.allowDrawingOutsideViewBox = false,
  super.placeholderBuilder,
  super.semanticsLabel,
  super.excludeFromSemantics = false,
  super.clipBehavior = Clip.hardEdge,
  super.cacheColorFilter = false,
  super.theme,
  ColorFilter? colorFilter,
  BlendMode colorBlendMode = BlendMode.srcIn,
  Color? color,
}) : super.asset(assetName,
          colorFilter: colorFilter ?? _getColorFilter(color, colorBlendMode),
          width: width ?? size,
          height: height ?? size);