HexColor class final

A 6-digit hex value plus an opacity percentage.

Annotations

Constructors

HexColor(int hex, {double opacity = 100})
Creates a color from a 0xRRGGBB hex value and an opacity percent.
const
HexColor.fromColor(Color color)
The color's alpha becomes opacity.

Properties

hashCode → int
The hash code for this object.
no setteroverride
hex → int
The color, as 0xRRGGBB.
final
hexString → String
hex as six upper-case digits, such as 3B5BDB.
no setter
opacity → double
The opacity, in percent from 0 to 100.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toColor() → Color
This color as Flutter draws it, with opacity as its alpha.
toString() → String
A string representation of this object.
override

Operators

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