get

operator fun get(index: Int): Int

Get the color in colors at the specified index. Checks if index is a valid index of colors and if so, returns the color stored there, if not, returns 0 (black).


operator fun get(vararg indices: Int): List<Int>

Get multiple colors from colors. Accepts a variable number of arguments (a single argument will be caught by the get() operator above). If no indices are provided, this will return an empty list. If an index is not a valid index in colors, 0 is added to the list. The returned list contains the colors in the order specified.


operator fun get(indices: IntRange): List<Int>

Get multiple colors from colors. If an index in the range is not a valid index in colors, 0 is added to the list.