InteractiveViewerBoundary class

Builds an InteractiveViewer and provides callbacks that are called when a horizontal boundary has been hit.

The callbacks are called when an interaction ends by listening to the InteractiveViewer.onInteractionEnd callback.

Inheritance

Constructors

InteractiveViewerBoundary({required Widget child, required double boundaryWidth, TransformationController? controller, ScaleChanged? onScaleChanged, VoidCallback? onLeftBoundaryHit, VoidCallback? onRightBoundaryHit, VoidCallback? onNoBoundaryHit, double? maxScale, double? minScale})
const

Properties

boundaryWidth double
The max width this widget can have.
final
child Widget
final
controller TransformationController?
The TransformationController for the InteractiveViewer.
final
hashCode int
The hash code for this object.
no setterinherited
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
maxScale double?
final
minScale double?
final
onLeftBoundaryHit VoidCallback?
Called when the left boundary has been hit after an interaction ended.
final
onNoBoundaryHit VoidCallback?
Called when no boundary has been hit after an interaction ended.
final
onRightBoundaryHit VoidCallback?
Called when the right boundary has been hit after an interaction ended.
final
onScaleChanged ScaleChanged?
Called when the scale changed after an interaction ended.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() InteractiveViewerBoundaryState
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
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