| @@ 136-144 (lines=9) @@ | ||
| 133 | * |
|
| 134 | * @return Avtr |
|
| 135 | */ |
|
| 136 | public function letterCount(int $count): Avtr |
|
| 137 | { |
|
| 138 | if ($count < 1 || $count > 2) { |
|
| 139 | $count = 2; |
|
| 140 | } |
|
| 141 | $this->config['letter_count'] = $count; |
|
| 142 | ||
| 143 | return $this; |
|
| 144 | } |
|
| 145 | ||
| 146 | /** |
|
| 147 | * Sets the background colour. |
|
| @@ 170-179 (lines=10) @@ | ||
| 167 | * |
|
| 168 | * @return Avtr |
|
| 169 | */ |
|
| 170 | public function size(int $size): Avtr |
|
| 171 | { |
|
| 172 | if ($size < 0) { |
|
| 173 | $size = 100; |
|
| 174 | } |
|
| 175 | ||
| 176 | $this->config['size'] = $size; |
|
| 177 | ||
| 178 | return $this; |
|
| 179 | } |
|
| 180 | ||
| 181 | /** |
|
| 182 | * Sets whether or not the square image should have rounded corners. |
|