Color.from_int


Description:

public Color.from_int (int color)

Constructs a new Granite.Drawing.Color from an integer.

This constructor should be used when deserializing the previously serialized color by Granite.Drawing.Color.to_int.

For more details on what format the color integer representation has, see Granite.Drawing.Color.to_int.

If you would like to deserialize the A, R, G and B values from the integer without creating a new instance of Granite.Drawing.Color, you can use the available *_from_int static method collection such as Granite.Drawing.Color.alpha_from_int.

Parameters:

color

the integer specyfying the color