AnimatedVisibility class
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- AnimatedVisibility
- Available extensions
Constructors
- AnimatedVisibility.new({required Widget child, required bool visible, required Widget builder(BuildContext context, bool animationVisible), bool autoRun = true, Key? key})
-
const
Properties
- autoRun → bool
-
final
- builder → Widget Function(BuildContext context, bool animationVisible)
-
final
- child → Widget
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- visible → bool
-
final
Methods
-
align(
Alignment alignment) → Widget -
Available on Widget, provided by the AlignmentExtension extension
-
asColoredButton(
{Color backgroundColor = Colors.blue, EdgeInsets padding = const EdgeInsets.all(12)}) → Widget -
Available on Widget, provided by the WidgetColorExtensions extension
Adds padding and a background color to create a button-like look. -
center(
) → Widget -
Available on Widget, provided by the AlignmentExtension extension
-
conditional(
bool condition) → Widget -
Available on Widget, provided by the VisibilityExtension extension
-
conditionalWrap(
bool condition, Widget wrapper(Widget child)) → Widget -
Available on Widget, provided by the WidgetModifiers extension
Conditionally wraps the widget with another widget -
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< AnimatedVisibility> -
Creates the mutable state for this widget at a given location in the tree.
override
-
customTouchControl(
{required bool enable, VoidCallback? onTapWhileDisabled}) → Widget -
Available on Widget, provided by the TouchControl extension
Enables or disables touch with a custom gesture detector -
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
-
fade(
{required bool visible, Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeInOut, bool autoRun = true}) → Widget -
Available on Widget, provided by the AnimationExtensions extension
Fades the widget in and out -
fadeScale(
{required bool visible, Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeInOut, bool autoRun = true}) → Widget -
Available on Widget, provided by the AnimationExtensions extension
Combines fade and scale animations -
fitted(
{BoxFit fit = BoxFit.contain, Alignment alignment = Alignment.center}) → Widget -
Available on Widget, provided by the FittedBoxExtensions extension
Wraps the widget with a FittedBox that adapts to the screen size. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
onContextMenu(
VoidCallback? onContextMenu) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a context menu gesture to any widget (e.g., iOS long-press context menu) -
onDoubleTap(
VoidCallback? onDoubleTap) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a double-tap gesture to any widget -
onForcePress(
{GestureForcePressStartCallback? onForcePressStart, GestureForcePressUpdateCallback? onForcePressUpdate, GestureForcePressEndCallback? onForcePressEnd}) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a force press gesture to any widget -
onHorizontalDrag(
VoidCallback? onDragStart) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a horizontal drag gesture to any widget -
onLongPress(
VoidCallback? onLongPress) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a long-press gesture to any widget -
onPan(
{GestureDragStartCallback? onPanStart, GestureDragUpdateCallback? onPanUpdate, GestureDragEndCallback? onPanEnd}) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a pan gesture (combination of horizontal and vertical drag) -
onScale(
{GestureScaleStartCallback? onScaleStart, GestureScaleUpdateCallback? onScaleUpdate, GestureScaleEndCallback? onScaleEnd}) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a scale gesture to any widget -
onSingleTap(
VoidCallback? onTap) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a tap gesture to any widget -
onTap(
VoidCallback? action) → Widget -
Available on Widget, provided by the WidgetModifiers extension
Adds a gesture detector to a widget -
onVerticalDrag(
VoidCallback? onDragStart) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds a vertical drag gesture to any widget -
paddingAll(
double value) → Widget -
Available on Widget, provided by the PaddingExtension extension
-
paddingOnly(
{double left = 0, double top = 0, double right = 0, double bottom = 0}) → Widget -
Available on Widget, provided by the PaddingExtension extension
-
paddingSymmetric(
{double vertical = 0, double horizontal = 0}) → Widget -
Available on Widget, provided by the PaddingExtension extension
-
scale(
{required bool visible, double begin = 0.0, double end = 1.0, Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeInOut, bool autoRun = true}) → Widget -
Available on Widget, provided by the AnimationExtensions extension
Scales the widget in and out -
scaleToHeight(
{required BuildContext context, double factor = 1.0}) → Widget -
Available on Widget, provided by the FittedBoxExtensions extension
Scales the widget proportionally to the screen's height. -
scaleToMaxHeight(
{required BuildContext context, double maxHeight = 800, double factor = 1.0}) → Widget -
Available on Widget, provided by the FittedBoxExtensions extension
Scales the widget conditionally based on a maximum height. -
scaleToMaxWidth(
{required BuildContext context, double maxWidth = 400, double factor = 1.0}) → Widget -
Available on Widget, provided by the FittedBoxExtensions extension
Scales the widget conditionally based on a maximum width. -
scaleToScreen(
{required BuildContext context, double widthFactor = 1.0, double heightFactor = 1.0}) → Widget -
Available on Widget, provided by the FittedBoxExtensions extension
Combines scaling for both width and height. -
scaleToWidth(
{required BuildContext context, double factor = 1.0}) → Widget -
Available on Widget, provided by the FittedBoxExtensions extension
Scales the widget proportionally to the screen's width. -
slide(
{required bool visible, Offset begin = const Offset(0, 1), Offset end = Offset.zero, Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeInOut, bool autoRun = true}) → Widget -
Available on Widget, provided by the AnimationExtensions extension
Slides the widget in from a specific direction -
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
-
touchDisabled(
{bool disable = true}) → Widget -
Available on Widget, provided by the TouchControl extension
Disables touch interactions for the widget by wrapping it withAbsorbPointer
. -
touchDisabledWithOpacity(
{bool disable = true, double disabledOpacity = 0.5}) → Widget -
Available on Widget, provided by the TouchControl extension
Disables touch interactions with visual feedback usingOpacity
. -
touchIgnored(
{bool ignore = true}) → Widget -
Available on Widget, provided by the TouchControl extension
Enables or disables touch interactions with feedback usingIgnorePointer
. -
visible(
bool isVisible) → Widget -
Available on Widget, provided by the VisibilityExtension extension
-
withBackgroundColor(
Color color) → Widget -
Available on Widget, provided by the WidgetColorExtensions extension
Wraps the widget with a background color. -
withBackgroundGradient(
List< Color> colors, {Alignment begin = Alignment.topLeft, Alignment end = Alignment.bottomRight}) → Widget -
Available on Widget, provided by the WidgetColorExtensions extension
Applies a gradient as the widget's background. -
withGestures(
{VoidCallback? onTap, VoidCallback? onDoubleTap, VoidCallback? onLongPress, GestureDragStartCallback? onPanStart, GestureDragUpdateCallback? onPanUpdate, GestureDragEndCallback? onPanEnd, GestureScaleStartCallback? onScaleStart, GestureScaleUpdateCallback? onScaleUpdate, GestureScaleEndCallback? onScaleEnd, GestureForcePressStartCallback? onForcePressStart, GestureForcePressUpdateCallback? onForcePressUpdate, GestureForcePressEndCallback? onForcePressEnd}) → Widget -
Available on Widget, provided by the GestureDetectorExtensions extension
Adds multiple gesture types to a widget -
withGlossyEffect(
{Color overlayColor = Colors.white, double glossFactor = 0.2}) → Widget -
Available on Widget, provided by the WidgetColorExtensions extension
Adds a glossy effect overlay to the widget. -
withTooltip(
String message) → Widget -
Available on Widget, provided by the WidgetModifiers extension
Adds a tooltip to any widget
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited