FSvgPicture.string constructor

const FSvgPicture.string(
  1. String string, {
  2. Key? key,
  3. double? width,
  4. double? height,
  5. BoxFit fit = BoxFit.contain,
  6. AlignmentGeometry alignment = Alignment.center,
  7. bool matchTextDirection = false,
  8. bool allowDrawingOutsideViewBox = false,
  9. WidgetBuilder? placeholderBuilder,
  10. ColorFilter? colorFilter,
  11. String? semanticsLabel,
  12. bool excludeFromSemantics = false,
  13. Clip clipBehavior = Clip.hardEdge,
  14. SvgErrorWidgetBuilder? errorBuilder,
  15. SvgTheme? theme,
  16. ColorMapper? colorMapper,
  17. RenderingStrategy renderingStrategy = RenderingStrategy.picture,
  18. Color? backgroundColor,
  19. double playbackRate = 1.0,
  20. bool autoPlay = true,
  21. Duration? initialTime,
})

Creates an auto-detected SVG from a raw SVG string.

Implementation

const FSvgPicture.string(
  String string, {
  super.key,
  this.width,
  this.height,
  this.fit = BoxFit.contain,
  this.alignment = Alignment.center,
  this.matchTextDirection = false,
  this.allowDrawingOutsideViewBox = false,
  this.placeholderBuilder,
  this.colorFilter,
  this.semanticsLabel,
  this.excludeFromSemantics = false,
  this.clipBehavior = Clip.hardEdge,
  this.errorBuilder,
  this.theme,
  this.colorMapper,
  this.renderingStrategy = RenderingStrategy.picture,
  this.backgroundColor,
  this.playbackRate = 1.0,
  this.autoPlay = true,
  this.initialTime,
}) : _sourceType = _FSvgSourceType.string,
     _svgString = string,
     _assetName = null,
     _assetBundle = null,
     _package = null,
     _url = null,
     _headers = null,
     _httpClient = null,
     _file = null,
     _bytes = null;