LinearGradientSpec class

Linear gradient parameters in core space.

  • angle in degrees (0° = +X axis; same as your current usage)
  • width 0..50 (matches your editor semantics)

Constructors

LinearGradientSpec({required Color32 color1, required Color32 color2, double angle = 0, double width = 0})
const
LinearGradientSpec.fromJson(Map<String, dynamic> json)
factory

Properties

angle → double
final
color1 → int
final
color2 → int
final
hashCode → int
The hash code for this object.
no setteroverride
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
width → double
final

Methods

copyWith({Color32? color1, Color32? color2, double? angle, double? width}) → LinearGradientSpec
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, dynamic>
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
override

Constants

transparent → const LinearGradientSpec