public function SassColour::getRed in Sassy 7
Same name and namespace in other branches
- 7.3 phpsass/script/literals/SassColour.php \SassColour::getRed()
* Returns the red component of this colour. *
Return value
integer the red component of this colour.
13 calls to SassColour::getRed()
- SassColour::getRgba in phamlp/
sass/ script/ literals/ SassColour.php - * Returns an array with the RGB and alpha components of this colour. *
- SassColour::op_bw_and in phamlp/
sass/ script/ literals/ SassColour.php - * Colour bitwise AND *
- SassColour::op_bw_or in phamlp/
sass/ script/ literals/ SassColour.php - * Colour bitwise OR *
- SassColour::op_bw_xor in phamlp/
sass/ script/ literals/ SassColour.php - * Colour bitwise XOR *
- SassColour::op_div in phamlp/
sass/ script/ literals/ SassColour.php - * Colour division *
File
- phamlp/
sass/ script/ literals/ SassColour.php, line 678
Class
- SassColour
- SassColour class. A SassScript object representing a CSS colour.
Code
public function getRed() {
if (is_null($this->red)) {
$this
->hsl2rgb();
}
return max(0, min(255, round($this->red)));
}