TooltipBehavior class

Customizes the tooltip.

Inheritance

Constructors

TooltipBehavior({ChartTextStyle textStyle, ActivationMode activationMode, int animationDuration, bool enable, double opacity, Color borderColor, double borderWidth, double duration, bool shouldAlwaysShow, double elevation, bool canShowMarker, ChartAlignment textAlignment, Color color, String header, String format, ChartWidgetBuilder builder, Color shadowColor })

Properties

activationMode ActivationMode
Gesture for activating the tooltip. Tooltip can be activated in tap, double tap, and long press. Defaults to ActivationMode.tap [...]
final
animationDuration int
Duration for animating the tooltip. [...]
final
borderColor Color
Border color of the tooltip. [...]
final
borderWidth double
Border width of the tooltip. [...]
final
builder ChartWidgetBuilder
Builder of the tooltip. [...]
final
canShowMarker bool
Toggles the visibility of the marker in the tooltip. [...]
final
color Color
Color of the tooltip. [...]
final
duration double
Duration for displaying the tooltip. [...]
final
elevation double
Elevation of the tooltip. [...]
final
enable bool
Toggles the visibility of the tooltip. [...]
final
format String
Formats the tooltip text. By default, the tooltip will be rendered with x and y-values. You can add prefix or suffix to x, y, and series name values in the tooltip by formatting them. [...]
final
Header of the tooltip. By default, the series name will be displayed in the header. [...]
final
opacity double
Opacity of the tooltip. The value ranges from 0 to 1. [...]
final
shadowColor Color
Color of the tooltip shadow. [...]
final
shouldAlwaysShow bool
Shows or hides the tooltip. By default, the tooltip will be hidden on touch. To avoid this, set this property to true. [...]
final
textAlignment ChartAlignment
Alignment of the text in the tooltip [...]
final
textStyle ChartTextStyle
Customizes the tooltip text [...]
final
hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

hide() → void
Hides the tooltip if it is displayed.
onDoubleTap(double xPos, double yPos) → void
Performs the double-tap action of appropriate point.
override
onLongPress(double xPos, double yPos) → void
Performs the double-tap action of appropriate point.
override
onPaint(Canvas canvas) → void
Draws tooltip
override
onTouchDown(double xPos, double yPos) → void
Performs the touch-down action of appropriate point.
override
onTouchMove(double xPos, double yPos) → void
Performs the touch move action of chart.
override
onTouchUp(double xPos, double yPos) → void
Performs the touch move action of chart.
override
show(double x, double y) → void
Displays the tooltip at the specified x and y-positions.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited