Constructors
-
Color.hex(String hex)
-
Constructs a Color from a hex string. Must start with a '#' and contain up to 6 hex characters.
const
factory
-
Color.hsl(int hue, int saturation, int lightness)
-
Constructs a Color from hue, saturation and lightness values
const
factory
-
Color.hsla(int hue, int saturation, int lightness, double alpha)
-
Constructs a Color from hue, saturation, lightness and alpha values
const
factory
-
Color.named(String name)
-
Constructs a Color from a web color name. Consider using
Colors.<name>
instead.
const
factory
-
Color.rgb(int red, int green, int blue)
-
Constructs a Color from red, green and blue values
const
factory
-
Color.rgba(int red, int green, int blue, double alpha)
-
Constructs a Color from red, green, blue and alpha values
const
factory
-
Color.value(int value)
-
Constructs a Color from an integer value.
const
factory
Properties
-
hashCode
→ int
-
The hash code for this object.
no setterinherited
-
runtimeType
→ Type
-
A representation of the runtime type of the object.
no setterinherited
-
value
→ String
-
The color css value
no setter
Methods
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
toString()
→ String
-
A string representation of this object.
inherited