Hex6Color

Chameleon\Colors\Hex6Color

Class Hex6Color

Represents a color in the RGB system but constructed via a hex string (#rrggbb). No alpha channel!

  • Class name: Hex6Color
  • Namespace: Chameleon\Colors
  • Fully qualified class name: Chameleon\Colors\Hex6Color
  • Extends: Chameleon\Colors\RGBColor

Methods

__construct()

void Hex6Color::__construct(string $hexString)

Class constructor

Arguments

  • $hexString string - <p>The 6-digit hexstring, e.g. #fe0da7</p>

__toString()

string Hex6Color::__toString()

Get string representation of this color

Format: #rrggbb

Arguments

None.


getHex()

string Hex6Color::getHex()

Get hexadecimal value for this color Format: #rrggbb

Arguments

None.


setHex()

void Hex6Color::setHex(string $hexString)

Set hexadecimal value for this color

Arguments

  • $hexString string - <p>The hexadecimal color value, Fomat: #rrggbb</p>

fromRGBA()

void Hex6Color::fromRGBA(\Chameleon\Colors\RGBAColor $rgba)

{@inheritdoc}

  • static

    Arguments

  • $rgba Chameleon\Colors\RGBAColor - No description available.