@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | /** |
186 | 186 | * Output a header to browser. |
187 | 187 | * |
188 | - * @param $name Name of the header |
|
188 | + * @param string $name Name of the header |
|
189 | 189 | * @param $data Data |
190 | 190 | */ |
191 | 191 | protected function writeHeader($name, $data) |
@@ -394,7 +394,7 @@ discard block |
||
394 | 394 | * Copies transparency information from $sourceImage. Optionally fills |
395 | 395 | * the image with the transparent color at (0, 0). |
396 | 396 | * |
397 | - * @param object $sourceImage |
|
397 | + * @param Image $sourceImage |
|
398 | 398 | * @param bool $fill True if you want to fill the image with transparent color |
399 | 399 | */ |
400 | 400 | public function copyTransparencyFrom($sourceImage, $fill = true) |
@@ -488,8 +488,8 @@ discard block |
||
488 | 488 | * $smaller = $image->resizeDown(100, 100, 'inside'); |
489 | 489 | * </code> |
490 | 490 | * |
491 | - * @param mixed $width The new width (smart coordinate), or null. |
|
492 | - * @param mixed $height The new height (smart coordinate), or null. |
|
491 | + * @param integer|null $width The new width (smart coordinate), or null. |
|
492 | + * @param integer|null $height The new height (smart coordinate), or null. |
|
493 | 493 | * @param string $fit 'inside', 'outside', 'fill' |
494 | 494 | * @param string $scale 'down', 'up', 'any' |
495 | 495 | * @return \WideImage\Image The resized image |
@@ -556,8 +556,8 @@ discard block |
||
556 | 556 | * </code> |
557 | 557 | * |
558 | 558 | * @param \WideImage\Image $overlay The overlay image |
559 | - * @param mixed $left Left position of the overlay, smart coordinate |
|
560 | - * @param mixed $top Top position of the overlay, smart coordinate |
|
559 | + * @param integer $left Left position of the overlay, smart coordinate |
|
560 | + * @param integer $top Top position of the overlay, smart coordinate |
|
561 | 561 | * @param int $pct The opacity of the overlay |
562 | 562 | * @return \WideImage\Image The merged image |
563 | 563 | */ |
@@ -652,8 +652,8 @@ discard block |
||
652 | 652 | * and white is fully opaque. |
653 | 653 | * |
654 | 654 | * @param \WideImage\Image $mask The mask image, greyscale |
655 | - * @param mixed $left Left coordinate, smart coordinate |
|
656 | - * @param mixed $top Top coordinate, smart coordinate |
|
655 | + * @param integer $left Left coordinate, smart coordinate |
|
656 | + * @param integer $top Top coordinate, smart coordinate |
|
657 | 657 | * @return \WideImage\Image The resulting image |
658 | 658 | **/ |
659 | 659 | public function applyMask($mask, $left = 0, $top = 0) |
@@ -708,10 +708,10 @@ discard block |
||
708 | 708 | * $cropped = $img->crop("center", "middle", 50, 30); // crops a 50x30 from the center of the image |
709 | 709 | * </code> |
710 | 710 | * |
711 | - * @param mixed $left Left-coordinate of the crop rect, smart coordinate |
|
712 | - * @param mixed $top Top-coordinate of the crop rect, smart coordinate |
|
713 | - * @param mixed $width Width of the crop rect, smart coordinate |
|
714 | - * @param mixed $height Height of the crop rect, smart coordinate |
|
711 | + * @param integer $left Left-coordinate of the crop rect, smart coordinate |
|
712 | + * @param integer $top Top-coordinate of the crop rect, smart coordinate |
|
713 | + * @param double $width Width of the crop rect, smart coordinate |
|
714 | + * @param double $height Height of the crop rect, smart coordinate |
|
715 | 715 | * @return \WideImage\Image The cropped image |
716 | 716 | **/ |
717 | 717 | public function crop($left = 0, $top = 0, $width = '100%', $height = '100%') |
@@ -956,7 +956,7 @@ discard block |
||
956 | 956 | /** |
957 | 957 | * Returns an array of serializable protected variables. Called automatically upon serialize(). |
958 | 958 | * |
959 | - * @return array |
|
959 | + * @return string[] |
|
960 | 960 | */ |
961 | 961 | public function __sleep() |
962 | 962 | { |
@@ -75,6 +75,11 @@ discard block |
||
75 | 75 | } |
76 | 76 | } |
77 | 77 | |
78 | + /** |
|
79 | + * @param string $mapper_class_name |
|
80 | + * @param string $mime_type |
|
81 | + * @param string $extension |
|
82 | + */ |
|
78 | 83 | public static function registerMapper($mapper_class_name, $mime_type, $extension) |
79 | 84 | { |
80 | 85 | self::$customMappers[$mime_type] = $mapper_class_name; |
@@ -86,6 +91,10 @@ discard block |
||
86 | 91 | return self::$customMappers; |
87 | 92 | } |
88 | 93 | |
94 | + /** |
|
95 | + * @param string $uri |
|
96 | + * @param string $format |
|
97 | + */ |
|
89 | 98 | public static function determineFormat($uri, $format = null) |
90 | 99 | { |
91 | 100 | if ($format == null) { |
@@ -108,6 +117,9 @@ discard block |
||
108 | 117 | return $format; |
109 | 118 | } |
110 | 119 | |
120 | + /** |
|
121 | + * @param string $format |
|
122 | + */ |
|
111 | 123 | public static function mimeType($format) |
112 | 124 | { |
113 | 125 | $format = strtoupper($format); |
@@ -37,7 +37,6 @@ discard block |
||
37 | 37 | * @param \WideImage\Image $image |
38 | 38 | * @param float $amount |
39 | 39 | * @param const $type |
40 | - * @param float $threshold |
|
41 | 40 | * @return \WideImage\Image |
42 | 41 | */ |
43 | 42 | public function execute($image, $amount, $type) { |
@@ -91,7 +90,6 @@ discard block |
||
91 | 90 | * @param int $r |
92 | 91 | * @param int $g |
93 | 92 | * @param int $b |
94 | - * @param int $value |
|
95 | 93 | * @return void |
96 | 94 | */ |
97 | 95 | public function colorNoise_fun(&$r, &$g, &$b, $amount) |
@@ -107,7 +105,6 @@ discard block |
||
107 | 105 | * @param int $r |
108 | 106 | * @param int $g |
109 | 107 | * @param int $b |
110 | - * @param int $value |
|
111 | 108 | * @return void |
112 | 109 | */ |
113 | 110 | public function monoNoise_fun(&$r, &$g, &$b, $amount) |
@@ -125,7 +122,6 @@ discard block |
||
125 | 122 | * @param int $r |
126 | 123 | * @param int $g |
127 | 124 | * @param int $b |
128 | - * @param int $value |
|
129 | 125 | * @return void |
130 | 126 | */ |
131 | 127 | public function saltPepperNoise_fun(&$r, &$g, &$b, $amount) |
@@ -37,8 +37,8 @@ |
||
37 | 37 | * |
38 | 38 | * @param \WideImage\Image $image |
39 | 39 | * @param \WideImage\Image $mask |
40 | - * @param smart_coordinate $left |
|
41 | - * @param smart_coordinate $top |
|
40 | + * @param integer $left |
|
41 | + * @param integer $top |
|
42 | 42 | * @return \WideImage\Image |
43 | 43 | */ |
44 | 44 | public function execute($image, $mask, $left = 0, $top = 0) |
@@ -139,6 +139,9 @@ |
||
139 | 139 | return $image; |
140 | 140 | } |
141 | 141 | |
142 | + /** |
|
143 | + * @param double $val |
|
144 | + */ |
|
142 | 145 | protected static function bit($val) |
143 | 146 | { |
144 | 147 | if ($val > 255) { |
@@ -35,6 +35,9 @@ |
||
35 | 35 | { |
36 | 36 | protected static $cache = array(); |
37 | 37 | |
38 | + /** |
|
39 | + * @param string $operationName |
|
40 | + */ |
|
38 | 41 | public static function get($operationName) |
39 | 42 | { |
40 | 43 | $lcname = strtolower($operationName); |
@@ -355,7 +355,7 @@ |
||
355 | 355 | /** |
356 | 356 | * Throws exception if the handle isn't a valid GD resource |
357 | 357 | * |
358 | - * @param mixed $handle The variable to check |
|
358 | + * @param resource $handle The variable to check |
|
359 | 359 | */ |
360 | 360 | public static function assertValidImageHandle($handle) |
361 | 361 | { |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | //static $configs; |
28 | 28 | |
29 | 29 | /** |
30 | - * @param $name |
|
30 | + * @param string $name |
|
31 | 31 | * @param string $type |
32 | 32 | * |
33 | 33 | * @return bool |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | * Load core class |
92 | 92 | * |
93 | 93 | * @access private |
94 | - * @param $name |
|
94 | + * @param string $name |
|
95 | 95 | * @return bool|string |
96 | 96 | */ |
97 | 97 | public static function loadCore($name) |
@@ -125,7 +125,7 @@ discard block |
||
125 | 125 | * Load Framework class |
126 | 126 | * |
127 | 127 | * @access private |
128 | - * @param $name |
|
128 | + * @param string $name |
|
129 | 129 | * @return bool|string |
130 | 130 | */ |
131 | 131 | public static function loadFramework($name) |
@@ -188,6 +188,9 @@ |
||
188 | 188 | 'Xmf\\Yaml' => __DIR__ . '/..' . '/xoops/xmf/src/Xmf/Yaml.php', |
189 | 189 | ); |
190 | 190 | |
191 | + /** |
|
192 | + * @return callable |
|
193 | + */ |
|
191 | 194 | public static function getInitializer(ClassLoader $loader) |
192 | 195 | { |
193 | 196 | return \Closure::bind(function () use ($loader) { |