TouchScaleResolver class abstract
An abstract class that defines how the scale value should be calculated during a touch-based scaling interaction.
Constructors
- TouchScaleResolver()
-
const
- TouchScaleResolver.percent()
-
Creates a resolver that always returns the given scale factor.
constfactory
- TouchScaleResolver.pixels()
-
Creates a resolver from a pixel-based offset from the widget center.
constfactory
- TouchScaleResolver.stevens({double exponent, double referenceSize, double scalingFactor})
-
Stevens' Power Law: Perceived intensity = k * (stimulus intensity)^n.
For touch feedback, exponent n ~= 0.3-0.5 is appropriate.
constfactory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
transform(
Size size, double value) → double - Calculates the scale to apply based on the intrinsic widget size.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited