copyWith method

DiscordColor copyWith({
  1. int? r,
  2. int? g,
  3. int? b,
})

Create a new DiscordColor identical to this one with one or more channels replaced.

Implementation

DiscordColor copyWith({int? r, int? g, int? b}) => DiscordColor.fromRgb(
      r ?? this.r,
      g ?? this.g,
      b ?? this.b,
    );