public function ColorCMY::__construct in Color Field 8.2
Create a new CMYK color.
Parameters
float $cyan: The cyan.
float $magenta: The magenta.
float $yellow: The yellow.
float $opacity: The opacity.
File
- src/
ColorCMY.php, line 43
Class
- ColorCMY
- ColorCMY represents the CMY color format.
Namespace
Drupal\color_fieldCode
public function __construct($cyan, $magenta, $yellow, $opacity) {
$this->cyan = $cyan;
$this->magenta = $magenta;
$this->yellow = $yellow;
$this->opacity = floatval($opacity);
}