Bounceable class
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- Bounceable
- Available extensions
- FlexibleExpandedExtension
- OpacityRange
- SizedBoxExtension
- WidgetAnimatedContainer
- WidgetAnimatedCrossFade
- WidgetAnimatedOpacity
- WidgetAspectRatio
- WidgetBackground
- WidgetCenter
- WidgetClipShape
- WidgetDecoration
- WidgetGestureHandler
- WidgetMargin
- WidgetOffset
- WidgetOverlay
- WidgetPadding
- WidgetPositioned
- WidgetRotation
- WidgetScale
- WidgetTextStyle
- WidgetVisibility
Constructors
- Bounceable({Key? key, required VoidCallback? onTap, required Widget child, void onTapUp(TapUpDetails)?, void onTapDown(TapDownDetails)?, VoidCallback? onTapCancel, VoidCallback? onLongPress, Duration? duration = const Duration(milliseconds: 200), Duration? reverseDuration = const Duration(milliseconds: 200), Curve curve = Curves.decelerate, Curve? reverseCurve = Curves.decelerate, double scaleFactor = 0.8, HitTestBehavior? hitTestBehavior})
-
const
Properties
- child → Widget
-
final
- curve → Curve
-
The reverse curve of the scaling animation when
onTapUp.final - duration → Duration?
-
The reverse duration of the scaling animation when
onTapUp.final - hashCode → int
-
The hash code for this object.
no setterinherited
- hitTestBehavior → HitTestBehavior?
-
How the internal gesture detector should behave during hit testing.
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- onLongPress → VoidCallback?
-
final
- onTap → VoidCallback?
-
Set it to
nullto disableonTap.final - onTapCancel → VoidCallback?
-
final
- onTapDown → void Function(TapDownDetails)?
-
final
- onTapUp → void Function(TapUpDetails)?
-
final
- reverseCurve → Curve?
-
The curve of the scaling animation when
onTapDown..final - reverseDuration → Duration?
-
The duration of the scaling animation when
onTapDown.final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scaleFactor → double
-
The scale factor of the child widget. The valid range of
scaleFactoris from0.0to1.0.final
Methods
-
align(
{AlignmentGeometry alignment = Alignment.center}) → Align -
Available on Widget, provided by the WidgetAspectRatio extension
Aligns the widget using a specific alignment. -
animatedContainer(
{required Duration duration, Color? color, BoxDecoration? decoration}) → AnimatedContainer -
Available on Widget, provided by the WidgetAnimatedContainer extension
Adds an animated container effect to a widget. -
animatedCrossFade(
{required Widget firstChild, required Widget secondChild, required Duration duration}) → AnimatedCrossFade -
Available on Widget, provided by the WidgetAnimatedCrossFade extension
Adds an animated crossfade effect between two widgets. -
animatedOpacity(
{double opacity = 1.0, Duration duration = const Duration(milliseconds: 300)}) → AnimatedOpacity -
Available on Widget, provided by the WidgetAnimatedOpacity extension
Changes the opacity of Widget with Animation (default opacity:1.0, duration:Duration(milliseconds: 300)). -
aspectRatio(
double ratio) → AspectRatio -
Available on Widget, provided by the WidgetAspectRatio extension
Applies an aspect ratio to the widget. -
background(
{required Widget backgroundWidget, AlignmentGeometry alignment = Alignment.center, StackFit fit = StackFit.loose, Clip clipBehavior = Clip.none}) → Stack -
Available on Widget, provided by the WidgetBackground extension
Adds a background to the widget. -
center(
) → Center -
Available on Widget, provided by the WidgetCenter extension
Centers the widget in its parent. -
clipShape(
{Clip clipBehavior = Clip.antiAlias}) → ClipOval -
Available on Widget, provided by the WidgetClipShape extension
Clips the widget into a shape (default is oval). -
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → _BounceableState -
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
-
decorate(
{Color? color, double? borderWidth, Color? borderColor, double? borderRadius, List< BoxShadow> ? boxShadow, EdgeInsetsGeometry? padding, Clip clipBehavior = Clip.antiAlias, Gradient? gradient}) → DecoratedBox -
Available on Widget, provided by the WidgetDecoration extension
Applies decoration such as color, border, shadow, padding, etc., to the widget. -
expanded(
{int flex = 1}) → Expanded -
Available on Widget, provided by the FlexibleExpandedExtension extension
Wraps the widget with Expanded. -
flexible(
{int flex = 1}) → Flexible -
Available on Widget, provided by the FlexibleExpandedExtension extension
Wraps the widget with Flexible. -
margin(
{double all = 0.0, double vertical = 0.0, double horizontal = 0.0}) → Container -
Available on Widget, provided by the WidgetMargin extension
Applies margin to all sides or specific directions. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
offset(
{double x = 0.0, double y = 0.0}) → Transform -
Available on Widget, provided by the WidgetOffset extension
Translates (moves) the widget by the givenxandycoordinates. -
onLongPress(
VoidCallback onLongPress) → GestureDetector -
Available on Widget, provided by the WidgetGestureHandler extension
Adds a long press gesture handler to the widget. -
onPanUpdate(
{required dynamic onPanUpdate(DragUpdateDetails)}) → GestureDetector -
Available on Widget, provided by the WidgetGestureHandler extension
Adds a pan update gesture handler to the widget. -
onTap(
VoidCallback onTap) → GestureDetector -
Available on Widget, provided by the WidgetGestureHandler extension
Adds a tap handler to the widget. -
onTapBounce(
{required VoidCallback onTap, void onTapUp(TapUpDetails)?, void onTapDown(TapDownDetails)?, VoidCallback? onTapCancel, VoidCallback? onLongPress, Duration duration = const Duration(milliseconds: 200), Duration reverseDuration = const Duration(milliseconds: 200), Curve curve = Curves.decelerate, Curve reverseCurve = Curves.decelerate, double scaleFactor = 0.8}) → Widget -
Available on Widget, provided by the WidgetGestureHandler extension
Adds a bounceable effect when tapped. -
onTapRipple(
{VoidCallback? onTap, BorderRadius? borderRadius}) → InkWell -
Available on Widget, provided by the WidgetGestureHandler extension
Adds a ripple effect on tap (InkWell). -
opacity(
[double opacity = 1.0]) → Opacity -
Available on Widget, provided by the WidgetAnimatedOpacity extension
-
overlay(
{required Widget overlayWidget, AlignmentGeometry alignment = Alignment.center, StackFit fit = StackFit.loose, Clip clipBehavior = Clip.none}) → Stack -
Available on Widget, provided by the WidgetOverlay extension
Adds an overlay widget on top of the current widget. -
padding(
{double all = 0.0, double vertical = 0.0, double horizontal = 0.0}) → Padding -
Available on Widget, provided by the WidgetPadding extension
Applies padding to all sides or specific directions. -
paddingOnly(
{double top = 0, double right = 0, double bottom = 0, double left = 0}) → Padding -
Available on Widget, provided by the WidgetPadding extension
Applies padding to specific sides (top, right, bottom, left). -
positioned(
{double? top, double? bottom, double? left, double? right, double? width, double? height}) → Positioned -
Available on Widget, provided by the WidgetPositioned extension
Positions a widget inside aStackwith optional width and height constraints. -
rotate(
double angle) → Transform -
Available on Widget, provided by the WidgetRotation extension
Rotates the widget by a specified angle. -
scale(
double scale) → Transform -
Available on Widget, provided by the WidgetScale extension
Scales the widget by a specified factor. -
textStyle(
{TextStyle? style, double? fontSize, FontWeight? fontWeight, Color? color, TextDecoration? decoration, double? letterSpacing, double? wordSpacing}) → Widget -
Available on Widget, provided by the WidgetTextStyle extension
Applies a text style to the widget. -
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
-
visibility(
{bool visible = true}) → Visibility -
Available on Widget, provided by the WidgetVisibility extension
Toggles the visibility of the widget. -
withOpacity(
[double opacity = 1.0]) → Opacity -
Available on Widget, provided by the OpacityRange extension
Changes the opacity of the widget. -
withSize(
{double? width, double? height}) → SizedBox -
Available on Widget, provided by the SizedBoxExtension extension
Wraps the widget in a SizedBox with specifiedwidthand/orheight.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited