withAlpha method

HSLColor withAlpha(
  1. double alpha
)

Returns a copy of this color with the alpha parameter replaced with the given value.

Implementation

HSLColor withAlpha(double alpha) {
  return HSLColor.fromAHSL(alpha, hue, saturation, lightness);
}