NibAnim class
An immutable snapshot of every visual property NibMotion can animate.
Each property is nullable: null means "this animation does not touch
this property" rather than "set this property to zero/identity". During
lerp, a null value on one side falls back to the corresponding
identity value so animations only affect the properties the caller
actually specifies.
- Annotations
Constructors
-
NibAnim({double? x, double? y, double? scale, double? scaleX, double? scaleY, double? rotate, double? skewX, double? skewY, double? opacity, Color? color, BorderRadius? borderRadius, List<
BoxShadow> ? boxShadow}) -
Creates an animation snapshot. Any omitted property is left untouched
by this animation.
const
Properties
- borderRadius → BorderRadius?
-
Clip radius applied to the widget and its color/boxShadow.
final
-
boxShadow
→ List<
BoxShadow> ? -
Shadows painted behind the widget.
final
- color → Color?
-
Background color painted behind the child.
nullmeans transparent.final - hashCode → int
-
The hash code for this object.
no setteroverride
- opacity → double?
-
Opacity from
0.0(fully transparent) to1.0(fully opaque, identity).final - rotate → double?
-
Rotation around the Z axis, in turns (
1.0== 360°).final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scale → double?
-
Uniform scale applied to both axes. Identity is
1.0.final - scaleX → double?
-
Horizontal scale. Identity is
1.0.final - scaleY → double?
-
Vertical scale. Identity is
1.0.final - skewX → double?
-
Horizontal shear, in radians.
final
- skewY → double?
-
Vertical shear, in radians.
final
- x → double?
-
Horizontal offset from the widget's natural position, in pixels.
final
- y → double?
-
Vertical offset from the widget's natural position, in pixels.
final
Methods
-
copyWith(
{double? x, double? y, double? scale, double? scaleX, double? scaleY, double? rotate, double? skewX, double? skewY, double? opacity, Color? color, BorderRadius? borderRadius, List< BoxShadow> ? boxShadow}) → NibAnim - Returns a copy of this animation with the given properties replaced.
-
lerp(
NibAnim other, double t) → NibAnim -
Interpolates between this animation and
otherat positiont(0.0= this,1.0=other). -
merge(
NibAnim other) → NibAnim -
Returns a copy of this animation with every non-null property of
otheroverriding the corresponding property of this animation. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override