WormChart class

A lightweight worm chart widget.

Inheritance

Constructors

WormChart({required List<Tick> ticks, required CrosshairVariant crosshairVariant, int pipSize = 4, double zoomFactor = 0.05, Duration updateAnimationDuration = Duration.zero, LineStyle lineStyle = const LineStyle(), bool applyTickIndicatorsPadding = false, ScatterStyle highestTickStyle = const ScatterStyle(color: Color(0xFF00A79E), radius: 3), ScatterStyle lowestTickStyle = const ScatterStyle(color: Color(0xFFCC2E3D), radius: 3), ScatterStyle? lastTickStyle = const ScatterStyle(color: Color(0xFF377CFC), radius: 3), double topPadding = 10, double bottomPadding = 10, bool crossHairEnabled = false, VoidCallback? onTap, Key? key})
Initializes
const

Properties

applyTickIndicatorsPadding bool
Whether to apply padding around tick indicator dots (highest, lowest, last tick).
final
bottomPadding double
Chart's bottom padding.
final
crossHairEnabled bool
Whether the cross-hair feature is enabled or not.
final
crosshairVariant CrosshairVariant
The variant of the crosshair to be used. This is used to determine the type of crosshair to display. The default is CrosshairVariant.smallScreen. CrosshairVariant.largeScreen is mostly for web.
final
hashCode int
The hash code for this object.
no setterinherited
highestTickStyle ScatterStyle
The style of the circle which is the tick with the highest Tick.quote.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
lastTickStyle ScatterStyle?
The style of the circle showing the last tick.
final
lineStyle LineStyle
WormChart's line style.
final
lowestTickStyle ScatterStyle
The style of the circle which is the tick with the lowest Tick.quote.
final
onTap VoidCallback?
Will be called when the worm chart is tapped.
final
pipSize int
Number of decimals when showing the price of a tick on cross-hair.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
ticks List<Tick>
The ticks list to show.
final
topPadding double
Chart's top padding.
final
updateAnimationDuration Duration
The duration of sliding animation as the chart gets updated.
final
zoomFactor double
Indicates the proportion of the horizontal space that each tick is going to take.
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<WormChart>
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, int wrapWidth = 65}) 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