Color

constructor(red: UByte, green: UByte, blue: UByte, opacity: Float = 1.0f)(source)

creates a Color


constructor(hex: UInt, opacity: Float = 1.0f)(source)

Creates a new Color using the hex representation.

val c = Color(0xff0000)

Parameters

hex

representation of the color

opacity

of the color