Jyxo\Color::getHex PHP Method

getHex() public method

Returns the current color as a six-digit hexadecimal number.
public getHex ( ) : string
return string
    public function getHex() : string
    {
        return str_pad(dechex($this->red), 2, '0', STR_PAD_LEFT) . str_pad(dechex($this->green), 2, '0', STR_PAD_LEFT) . str_pad(dechex($this->blue), 2, '0', STR_PAD_LEFT);
    }