Module color

A simple container for a color and its hex string representation.

Even though it is not enforced, this container is assumed to be imutable.

Functions

Color:new (red, green, blue) Creates a new instance of Color.

Fields

red The red component, a number between 0 and 255.
green The green component, a number between 0 and 255.
blue The blue component, a number between 0 and 255.
hex The hex representation, like FFFFFF for white.


Functions

Color:new (red, green, blue)
Creates a new instance of Color.

Parameters:

  • red The red component, a number between 0 and 255.
  • green The green component, a number between 0 and 255.
  • blue The blue component, a number between 0 and 255.

Fields

red
The red component, a number between 0 and 255.
green
The green component, a number between 0 and 255.
blue
The blue component, a number between 0 and 255.
hex
The hex representation, like FFFFFF for white.
generated by LDoc 1.4.2