HTMLColor class
- Implemented types
Properties
- alpha → double?
-
Alpha channel: 0..1
final
- blue → int
-
Blue channel: 0..255
final
- brightness → int
-
Brightness of the color.
no setter
- green → int
-
Green channel: 0..255
final
- hasAlpha → bool
-
Returns
true
if this color has alpha channel lower than 1.no setter - hashCode → int
-
The hash code for this object.
no setteroverride
- red → int
-
Red channel: 0..255
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
brighter(
[int? amount, HTMLColor? def]) → HTMLColor? -
Returns a brighter color using
amount
(from 0 to 255) to increase bright. -
compareTo(
HTMLColor other) → int -
Compares using brightness: from brighter to darker.
override
-
copyWith(
{int? red, int? green, int? blue, double? alpha}) → HTMLColor - Creates a copy of this instance, overwriting the passed parameters.
-
darker(
[int? amount, HTMLColor? def]) → HTMLColor? -
Returns a darker color using
amount
(from 0 to 255) to decrease bright. -
getBrighterSpace(
) → int - Returns the amount of space for a brighter color.
-
getDarkerSpace(
) → int - Returns the amount of space for a darker color.
-
greyScale(
) → HTMLColor - Returns a grey scale version of this color.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
[bool forceRGBA = false]) → String -
Converts to a HTML Color string. If alpha is present uses
rgba()
format.override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Properties
- COLOR_PATTERN_ARGS → RegExp
-
final
- COLOR_PATTERN_HEX3 → RegExp
-
final
- COLOR_PATTERN_HEX6 → RegExp
-
final
- COLOR_PATTERN_RGBA → RegExp
-
final