AvdPicture class

A widget that draws Android Vector Drawable data into a Picture using a PictureProvider.

Support for AVD is incomplete and experimental at this time.

Inheritance

Constructors

AvdPicture(PictureProvider pictureProvider, {Key? key, bool matchTextDirection = false, bool allowDrawingOutsideViewBox = false, WidgetBuilder? placeholderBuilder, ColorFilter? colorFilter})
Instantiates a widget that renders an AVD picture using the pictureProvider.
const
AvdPicture.asset(String assetName, {Key? key, bool matchTextDirection = false, AssetBundle? bundle, String? package, bool allowDrawingOutsideViewBox = false, WidgetBuilder? placeholderBuilder, Color? color, BlendMode colorBlendMode = BlendMode.srcIn})
Draws an AvdPicture from an asset.
AvdPicture.string(String bytes, {bool matchTextDirection = false, bool allowDrawingOutsideViewBox = false, WidgetBuilder? placeholderBuilder, Color? color, BlendMode colorBlendMode = BlendMode.srcIn, Key? key})
Draws an AvdPicture from a raw string of XML.

Properties

allowDrawingOutsideViewBox bool
If true, will allow the AVD to be drawn outside of the clip boundary of its viewBox.
final
colorFilter ColorFilter?
The color filter, if any, to apply to this widget.
final
hashCode int
The hash code for this object.
no setterinherited
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
matchTextDirection bool
If true, will horizontally flip the picture in TextDirection.rtl contexts.
final
pictureProvider PictureProvider
The PictureProvider used to resolve the AVD.
final
placeholderBuilder WidgetBuilder?
The placeholder to use while fetching, decoding, and parsing the AVD data.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<StatefulWidget>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

avdByteDecoder PictureInfoDecoder<Uint8List>
A PictureInfoDecoder for Uint8Lists that will clip to the viewBox.
final
avdByteDecoderOutsideViewBox PictureInfoDecoder<Uint8List>
A PictureInfoDecoder for Uint8Lists that will not clip to the viewBox.
final
avdStringDecoder PictureInfoDecoder<String>
A PictureInfoDecoder for strings that will clip to the viewBox.
final
avdStringDecoderOutsideViewBox PictureInfoDecoder<String>
A PictureInfoDecoder for Strings that will not clip to the viewBox.
final
defaultPlaceholderBuilder WidgetBuilder
The default placeholder for an AVD that may take time to parse or retrieve, e.g. from a network location.
getter/setter pair