TooltipBase class abstract
If you need to customize Tooltip, use the tooltipChild parameter with the value of a class that inherits from TooltipBase (configure it according to your needs).
Reference example: example/example-2 ; example/example-3
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- TooltipBase
- Mixed in types
Constructors
-
TooltipBase({Key? key, required String message, required double height, bool? ignorePointer, Color? triangleColor, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, Decoration? decoration, TextStyle? textStyle, required Animation<
double> animation, required Offset target, required double allOffset, required PreferOrientation preferOri, required OverlayEntry entry, required Size targetSize, required Function customDismiss})
Properties
- allOffset → double
-
final
-
animation
→ Animation<
double> -
final
- customDismiss → Function
-
final
- decoration → Decoration?
-
final
- entry → OverlayEntry
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- height → double
-
final
- ignorePointer → bool
-
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- margin → EdgeInsetsGeometry?
-
final
- message → String
-
final
- padding → EdgeInsetsGeometry?
-
final
- preferOri → PreferOrientation
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- target → Offset
-
final
- targetSize → Size
-
final
- textStyle → TextStyle?
-
final
- triangleColor → Color?
-
final
Methods
-
clickTooltip(
Function customDismiss) → void - Click on the tooltip event
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → _TooltipBaseState -
Creates the mutable state for this widget at a given location in the tree.
override
-
customTipPainter(
) → Widget -
Custom tooltip edge widgets.
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
-
getCustomAnimation(
{required Animation< double> animation}) → Widget - Customized transition animation
-
getDefaultComputed(
Animation< double> ? animation) → Widget -
你可以根据preferOri参数返回合适的Widget.
override
-
getDefaultTooltip(
PreferOrientation preferOri, Animation< double> ? animation) → Widget -
Handling Tooltip widget sequence.
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