Colors in the standard tk used by loon do not allow for alpha transparency. This function allows loon to use color palettes (e.g. l_setColorList) that produce colors with alpha transparency by simply using only the rgb.

l_colRemoveAlpha(col)

Arguments

col

a vector of colors (potentially) containing an alpha level

Examples

x <- l_colRemoveAlpha(rainbow(6)) # Also works with ordinary color string representations # since it just extracts the rgb values from the colors. x <- l_colRemoveAlpha(c("red", "blue", "green", "orange")) x
#> [1] "#FF0000" "#0000FF" "#00FF00" "#FFA500"