lighter method

PColor lighter(
  1. double ratio
)

Returns a lighter color.

Implementation

PColor lighter(double ratio) {
  final hsv = this.hsv;
  var v2 = (hsv.v * ratio).clamp(0.0, 1.0);
  var color2 = PColorRGB.fromHSV(hsv.h, hsv.s, v2, alpha: alpha);
  return color2;
}