Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
|||
| 1 | <?php |
| 2 | declare(strict_types=1); |
| 3 | /** |
| 4 | * Pop PHP Framework (https://www.popphp.org/) |
| 5 | * |
| 6 | * @link https://github.com/popphp/popphp-framework |
| 7 | * @author Nick Sagona, III <dev@noladev.com> |
| 8 | * @copyright Copyright (c) 2009-2027 NOLA Interactive, LLC. |
| 9 | * @license https://www.popphp.org/license New BSD License |
| 10 | */ |
| 11 | |
| 12 | /** |
| 13 | * @namespace |
| 14 | */ |
| 15 | namespace Pop\Image\Type; |
| 16 | |
| 17 | |
| 18 | use Pop\Color\Color; |
| 19 | |
| 20 | /** |
| 21 | * Type interface |
| 22 | * |
| 23 | * @category Pop |
| 24 | * @package Pop\Image |
| 25 | * @author Nick Sagona, III <dev@noladev.com> |
| 26 | * @copyright Copyright (c) 2009-2027 NOLA Interactive, LLC. |
| 27 | * @license https://www.popphp.org/license New BSD License |
| 28 | * @version 5.0.0 |
| 29 | */ |
| 30 | interface TypeInterface |
| 31 | { |
| 32 | |
| 33 | /** |
| 34 | * Get the opacity |
| 35 | * |
| 36 | * @return int|float|null |
| 37 | */ |
| 38 | public function getOpacity(): int|float|null; |
| 39 | |
| 40 | /** |
| 41 | * Get fill color |
| 42 | * |
| 43 | * @return Color\ColorInterface |
| 44 | */ |
| 45 | public function getFillColor(): Color\ColorInterface; |
| 46 | |
| 47 | /** |
| 48 | * Get stroke color |
| 49 | * |
| 50 | * @return Color\ColorInterface |
| 51 | */ |
| 52 | public function getStrokeColor(): Color\ColorInterface; |
| 53 | |
| 54 | /** |
| 55 | * Get stroke width |
| 56 | * |
| 57 | * @return int |
| 58 | */ |
| 59 | public function getStrokeWidth(): int; |
| 60 | |
| 61 | /** |
| 62 | * Set fill color |
| 63 | * |
| 64 | * @param Color\ColorInterface $color |
| 65 | * @return TypeInterface |
| 66 | */ |
| 67 | public function setFillColor(Color\ColorInterface $color): TypeInterface; |
| 68 | |
| 69 | /** |
| 70 | * Set stroke color |
| 71 | * |
| 72 | * @param Color\ColorInterface $color |
| 73 | * @return TypeInterface |
| 74 | */ |
| 75 | public function setStrokeColor(Color\ColorInterface $color): TypeInterface; |
| 76 | |
| 77 | /** |
| 78 | * Set stroke width |
| 79 | * |
| 80 | * @param int $w |
| 81 | * @return TypeInterface |
| 82 | */ |
| 83 | public function setStrokeWidth(int $w): TypeInterface; |
| 84 | |
| 85 | /** |
| 86 | * Set the font size |
| 87 | * |
| 88 | * @param int $size |
| 89 | * @return TypeInterface |
| 90 | */ |
| 91 | public function size(int $size): TypeInterface; |
| 92 | |
| 93 | /** |
| 94 | * Set the font |
| 95 | * |
| 96 | * @param string $font |
| 97 | * @return TypeInterface |
| 98 | */ |
| 99 | public function font(string $font): TypeInterface; |
| 100 | |
| 101 | /** |
| 102 | * Set the X-position |
| 103 | * |
| 104 | * @param int $x |
| 105 | * @return TypeInterface |
| 106 | */ |
| 107 | public function x(int $x): TypeInterface; |
| 108 | |
| 109 | /** |
| 110 | * Set the Y-position |
| 111 | * |
| 112 | * @param int $y |
| 113 | * @return TypeInterface |
| 114 | */ |
| 115 | public function y(int $y): TypeInterface; |
| 116 | |
| 117 | /** |
| 118 | * Set both the X- and Y-positions |
| 119 | * |
| 120 | * @param int $x |
| 121 | * @param int $y |
| 122 | * @return TypeInterface |
| 123 | */ |
| 124 | public function xy(int $x, int $y): TypeInterface; |
| 125 | |
| 126 | /** |
| 127 | * Set the rotation of the text |
| 128 | * |
| 129 | * @param int $degrees |
| 130 | * @return TypeInterface |
| 131 | */ |
| 132 | public function rotate(int $degrees): TypeInterface; |
| 133 | |
| 134 | /** |
| 135 | * Set the opacity |
| 136 | * |
| 137 | * @param int|float $opacity |
| 138 | * @return TypeInterface |
| 139 | */ |
| 140 | public function setOpacity(int|float $opacity): TypeInterface; |
| 141 | |
| 142 | } |