struct

DotPrison::Colour

Inherits Struct < Value < Object

Constructors

new(r, g, b, a = 255)

Create by specifying the red, green, blue, and optionally alpha values

Source

Class methods

parse(str : String) : self | Nil

Create from the stored value, or nil on invalid values

Source

Instance methods

a

Alpha value 0..255

Source
b

Blue value 0..255

Source
g

Green value 0..255

Source
r

Red value 0..255

Source
to_s(io : IO)

Same as #inspect(io).

Source