WxAnchor class

An area that responds to touch. Has a configurable shape and can be configured to clip overlay that extend outside its bounds or not.

Inheritance

Constructors

WxAnchor({Key? key, BorderRadius borderRadius = BorderRadius.zero, Curve? curve, Duration? duration, VoidCallback? onTap, GestureTapUpCallback? onTapUp, GestureTapDownCallback? onTapDown, VoidCallback? onTapCancel, VoidCallback? onDoubleTap, VoidCallback? onLongPress, ValueChanged<bool>? onHover, ValueChanged<bool>? onFocus, double? scale, double? opacity, bool? overlay, Color? overlayColor, double? overlayOpacity, Size? overlayExtent, Color? textColor, TextStyle? textStyle, TextAlign? textAlign, Color? iconColor, double? iconOpacity, double? iconSize, MouseCursor? mouseCursor, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, WxAnchorStyle? style, WxAnchorStyle? focusedStyle, WxAnchorStyle? hoveredStyle, WxAnchorStyle? pressedStyle, WxAnchorStyle? disabledStyle, WidgetEventController? eventsController, FocusNode? focusNode, bool autofocus = false, bool? focusable, bool? feedback, bool? disabled, Widget? child})
Creates a rectangle shape area that responds to touch.
WxAnchor.circle({Key? key, Curve? curve, Duration? duration, VoidCallback? onTap, GestureTapUpCallback? onTapUp, GestureTapDownCallback? onTapDown, VoidCallback? onTapCancel, VoidCallback? onDoubleTap, VoidCallback? onLongPress, ValueChanged<bool>? onHover, ValueChanged<bool>? onFocus, double? scale, double? opacity, bool? overlay, Color? overlayColor, double? overlayOpacity, double? overlayRadius, Color? textColor, TextStyle? textStyle, TextAlign? textAlign, Color? iconColor, double? iconOpacity, double? iconSize, MouseCursor? mouseCursor, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, WxAnchorStyle? style, WxAnchorStyle? focusedStyle, WxAnchorStyle? hoveredStyle, WxAnchorStyle? pressedStyle, WxAnchorStyle? disabledStyle, WidgetEventController? eventsController, FocusNode? focusNode, bool autofocus = false, bool? focusable, bool? feedback, bool? disabled, Widget? child})
Creates a circle shaped area that responds to touch.
WxAnchor.raw({Key? key, Curve? curve, Duration? duration, VoidCallback? onTap, GestureTapUpCallback? onTapUp, GestureTapDownCallback? onTapDown, VoidCallback? onTapCancel, VoidCallback? onDoubleTap, VoidCallback? onLongPress, ValueChanged<bool>? onHover, ValueChanged<bool>? onFocus, double? scale, double? opacity, bool? overlay, ShapeBorder? overlayShape, Color? overlayColor, double? overlayOpacity, Size? overlayExtent, Color? textColor, TextStyle? textStyle, TextAlign? textAlign, Color? iconColor, double? iconOpacity, double? iconSize, MouseCursor? mouseCursor, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, WxAnchorStyle? style, WxAnchorStyle? focusedStyle, WxAnchorStyle? hoveredStyle, WxAnchorStyle? pressedStyle, WxAnchorStyle? disabledStyle, WidgetEventController? eventsController, FocusNode? focusNode, bool autofocus = false, bool? focusable, bool? feedback, bool? disabled, Widget? child})
Creates an area that responds to touch.
const

Properties

autofocus bool
True if this widget will be selected as the initial focus when no other node in its scope is currently focused.
final
child Widget?
The widget below this widget in the tree.
final
curve Curve?
The curve to apply when animating the parameters of this widget.
final
disabled bool?
Whether or not this widget is disabled for interaction.
final
disabledStyle WxAnchorStyle?
The style to be resolved when events includes WxAnchorEvent.disabled.
final
duration Duration?
The duration over which to animate the parameters of this widget.
final
effectiveStyle WxAnchorStyle
no setter
eventsController WidgetEventController?
Used by widgets that expose their internal event for the sake of extensions that add support for additional events.
final
feedback bool?
Whether detected gestures should disable acoustic and/or haptic feedback.
final
focusable bool?
If true, this widget may request the primary focus.
final
focusedStyle WxAnchorStyle?
The style to be resolved when events includes WxAnchorEvent.focused.
final
focusNode FocusNode?
An optional focus node to use as the focus node for this widget.
final
hashCode int
The hash code for this object.
no setterinherited
hoveredStyle WxAnchorStyle?
The style to be resolved when events includes WxAnchorEvent.hovered.
final
iconColor Color?
Color to be used for the icon's inside the anchor.
final
iconOpacity double?
Opacity to be apply to iconColor.
final
iconSize double?
The size of the icon's inside the anchor, in logical pixels.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
margin EdgeInsetsGeometry?
Empty space to surround the outside anchor.
final
mouseCursor MouseCursor?
The cursor for a mouse pointer when it enters or is hovering over the widget.
final
onDoubleTap VoidCallback?
Called when the user double taps
final
onFocus ValueChanged<bool>?
Handler called when the focus changes.
final
onHover ValueChanged<bool>?
Called when a pointer enters or exits the anchor area.
final
onLongPress VoidCallback?
Called when the user long-presses
final
onTap VoidCallback?
Called when the user taps
final
onTapCancel VoidCallback?
Called when the user cancels a tap that was started on
final
onTapDown GestureTapDownCallback?
Called when the user taps down
final
onTapUp GestureTapUpCallback?
Called when the user releases a tap that was started on
final
opacity double?
The child opacity of the anchor when pressed, hovered over, or focused.
final
overlay bool?
Whether the overlay is enabled or not
final
overlayColor Color?
The overlay color of the anchor when pressed, hovered over, or focused.
final
overlayExtent Size?
The extent of the overlay.
final
overlayOpacity double?
The overlay opacity of the anchor when pressed, hovered over, or focused.
final
overlayShape ShapeBorder?
The shape (e.g., circle, rectangle) to use for the overlay drawn around this part of the anchor when pressed, hovered over, or focused.
final
padding EdgeInsetsGeometry?
The padding between the contents of the anchor and the outside anchor.
final
pressedStyle WxAnchorStyle?
The style to be resolved when events includes WxAnchorEvent.pressed.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scale double?
The child scale of the anchor when pressed, hovered over, or focused.
final
style WxAnchorStyle?
The WxAnchorStyle to apply
final
textAlign TextAlign?
The align to be applied to the anchor's child. This only has an effect on widgets that respect the DefaultTextStyle, such as Text.
final
textColor Color?
The text color to be applied to child.
final
textStyle TextStyle?
The style to be applied to the anchor's child.
final

Methods

build(BuildContext context) Widget
Describes the part of the user interface represented by this widget.
override
createElement() StatelessElement
Creates a StatelessElement to manage this widget's location in the tree.
inherited
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.
override
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