DefaultCandlestickPainter class

Default implementation of FlCandlestickPainter.

It draws the candlestick shape with a line and a body (just like a standard candlestick chart).

You can customize the appearance of the candlestick using CandlestickStyleProvider.

Inheritance

Constructors

DefaultCandlestickPainter.new({CandlestickStyleProvider? candlestickStyleProvider})

Properties

candlestickStyleProvider CandlestickStyleProvider
final
hashCode int
The hash code for this object.
no setterinherited
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stringify bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited

Methods

getMainColor({required CandlestickSpot spot, required int spotIndex}) Color
Used to show default UIs, for example defaultCandlestickTooltipItem
override
hitTest(CandlestickSpot spot, double touchedX, double spotX, double extraTouchThreshold) → (bool, double)
Used to implement touch behaviour of this dot, for example, it behaves like a square of getSize Check DefaultCandlestickPainter.hitTest for an example of an implementation
inherited
lerp(FlCandlestickPainter a, FlCandlestickPainter b, double t) FlCandlestickPainter
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
paint(Canvas canvas, ValueInCanvasProvider xInCanvasProvider, ValueInCanvasProvider yInCanvasProvider, CandlestickSpot spot, int spotIndex) → void
This method should be overridden to draw the candlestick shape
override
toString() String
A string representation of this object.
inherited

Operators

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