setColors2 method

void setColors2 (
  1. List<Color> colors,
  2. int alpha
)

Sets colors with a specific alpha value.

@param colors @param alpha

Implementation

void setColors2(List<ui.Color> colors, int alpha) {
  resetColors();
  for (ui.Color color in colors) {
    addColor(ui.Color.fromARGB(alpha, color.red, color.green, color.blue));
  }
}