HslColor class
An HSL based color object.
Notice, although HslColor also implements Color, red, green and blue are calculated when called. For better performance, you shall use rgb to convert it to Color and access the converted Color if you have to access red, green and/or blue multiple times.
- Implemented types
Constructors
Properties
- alpha → num
-
The opacity of color.
final
- blue → num
-
The blue component.
Note: it is a shortcut of
rgb().blue
, so the performance might not be goodno setteroverride - green → num
-
The green component.
Note: it is a shortcut of
rgb().green
, so the performance might not be goodno setteroverride - hashCode → int
-
The hash code for this object.
no setteroverride
- hue → num
-
The hue of the color.
final
- lightness → num
-
The lightness of the color.
final
- red → num
-
The red component.
Note: it is a shortcut of
rgb().red
, so the performance might not be goodno setteroverride - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- saturation → num
-
The saturation of the color.
final
Methods
-
hsl(
) → HslColor -
Convert to HslColor
override
-
hsv(
) → HsvColor -
Convert to HsvColor
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
rgb(
) → Color - Convert to RGB based Color.
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object o) → bool -
The equality operator.
override