q5play
    Preparing search index...

    Class Color

    Index

    Constructors

    Properties

    Methods

    Constructors

    • 🎨 This constructor strictly accepts 4 numbers, which are the color components.

      Use the color function for greater flexibility, it runs this constructor internally.

      Parameters

      • c0: number
      • c1: number
      • c2: number
      • c3: number

      Returns Color

    Properties

    levels: number[]

    🎨 An array of the color's components.

    Methods

    • 🎨 Checks if this color is exactly equal to another color.

      Parameters

      Returns boolean

    • 🎨 Checks if the color is the same as another color, disregarding their alpha values.

      Parameters

      Returns boolean

    • 🎨 Produces a CSS color string representation.

      Returns string