@@ -55,6 +55,9 @@ |
||
55 | 55 | $this->corner = $aD; |
56 | 56 | } |
57 | 57 | |
58 | + /** |
|
59 | + * @param \Amenadiel\JpGraph\Image\RotImage $aImg |
|
60 | + */ |
|
58 | 61 | public function Stroke($aImg, $aDummy1 = null, $aDummy2 = null) |
59 | 62 | { |
60 | 63 | if ($this->hide) { |
@@ -67,7 +67,7 @@ |
||
67 | 67 | * range 0 $mu < 1 where 0 is tha start point and 1 is the end point. Note that every newly computed |
68 | 68 | * point depends on all the existing points |
69 | 69 | * |
70 | - * @param $mu Position on the bezier curve |
|
70 | + * @param double $mu Position on the bezier curve |
|
71 | 71 | * @return array($x, $y) |
72 | 72 | */ |
73 | 73 | public function GetPoint($mu) |
@@ -22,6 +22,9 @@ |
||
22 | 22 | $this->Set('C'); |
23 | 23 | } |
24 | 24 | |
25 | + /** |
|
26 | + * @param string $aLocale |
|
27 | + */ |
|
25 | 28 | public function Set($aLocale) |
26 | 29 | { |
27 | 30 | if (in_array($aLocale, array_keys($this->iDayAbb))) { |
@@ -18,17 +18,27 @@ |
||
18 | 18 | // Empty. Reserved for future use |
19 | 19 | } |
20 | 20 | |
21 | + /** |
|
22 | + * @param string $aTitle |
|
23 | + */ |
|
21 | 24 | public function SetTitle($aTitle) |
22 | 25 | { |
23 | 26 | $this->iTitle = $aTitle; |
24 | 27 | } |
25 | 28 | |
29 | + /** |
|
30 | + * @param string $aDest |
|
31 | + */ |
|
26 | 32 | public function SetStrokeDest($aDest) |
27 | 33 | { |
28 | 34 | $this->iDest = $aDest; |
29 | 35 | } |
30 | 36 | |
31 | 37 | // If aHalt is true then execution can't continue. Typical used for fatal errors |
38 | + |
|
39 | + /** |
|
40 | + * @param string $aMsg |
|
41 | + */ |
|
32 | 42 | public function Raise($aMsg, $aHalt = false) |
33 | 43 | { |
34 | 44 | if ($this->iDest != '') { |
@@ -11,6 +11,10 @@ discard block |
||
11 | 11 | private static $__iImgFlg = true; |
12 | 12 | private static $__iLogFile = ''; |
13 | 13 | private static $__iTitle = 'JpGraph Error: '; |
14 | + |
|
15 | + /** |
|
16 | + * @param integer $aMsg |
|
17 | + */ |
|
14 | 18 | public static function Raise($aMsg, $aHalt = true) |
15 | 19 | { |
16 | 20 | throw new JpGraphException($aMsg); |
@@ -47,6 +51,9 @@ discard block |
||
47 | 51 | return self::$__iLogFile; |
48 | 52 | } |
49 | 53 | |
54 | + /** |
|
55 | + * @param string $aTitle |
|
56 | + */ |
|
50 | 57 | public static function SetTitle($aTitle) |
51 | 58 | { |
52 | 59 | self::$__iTitle = $aTitle; |
@@ -250,6 +250,9 @@ discard block |
||
250 | 250 | return $img; |
251 | 251 | } |
252 | 252 | |
253 | + /** |
|
254 | + * @param null|resource $aHdl |
|
255 | + */ |
|
253 | 256 | public function SetCanvasH($aHdl) |
254 | 257 | { |
255 | 258 | $this->img = $aHdl; |
@@ -635,12 +638,21 @@ discard block |
||
635 | 638 | } |
636 | 639 | |
637 | 640 | // Set text alignment |
641 | + |
|
642 | + /** |
|
643 | + * @param string $halign |
|
644 | + */ |
|
638 | 645 | public function SetTextAlign($halign, $valign = "bottom") |
639 | 646 | { |
640 | 647 | $this->text_halign = $halign; |
641 | 648 | $this->text_valign = $valign; |
642 | 649 | } |
643 | 650 | |
651 | + /** |
|
652 | + * @param double $x |
|
653 | + * @param double $y |
|
654 | + * @param string $paragraph_align |
|
655 | + */ |
|
644 | 656 | public function _StrokeBuiltinFont($x, $y, $txt, $dir, $paragraph_align, &$aBoundingBox, $aDebug = false) |
645 | 657 | { |
646 | 658 | if (is_numeric($dir) && $dir != 90 && $dir != 0) { |
@@ -739,6 +751,10 @@ discard block |
||
739 | 751 | return $a; |
740 | 752 | } |
741 | 753 | |
754 | + /** |
|
755 | + * @param integer $size |
|
756 | + * @param string $fontfile |
|
757 | + */ |
|
742 | 758 | public function imagettfbbox_fixed($size, $angle, $fontfile, $text) |
743 | 759 | { |
744 | 760 | if (!USE_LIBRARY_IMAGETTFBBOX) { |
@@ -831,6 +847,9 @@ discard block |
||
831 | 847 | return $bbox; |
832 | 848 | } |
833 | 849 | |
850 | + /** |
|
851 | + * @return double |
|
852 | + */ |
|
834 | 853 | public function GetBBoxTTF($aTxt, $aAngle = 0) |
835 | 854 | { |
836 | 855 | // Normalize the bounding box to become a minimum |
@@ -898,6 +917,11 @@ discard block |
||
898 | 917 | return $box[2] - $box[0] + 1; |
899 | 918 | } |
900 | 919 | |
920 | + /** |
|
921 | + * @param double $x |
|
922 | + * @param double $y |
|
923 | + * @param string $paragraph_align |
|
924 | + */ |
|
901 | 925 | public function _StrokeTTF($x, $y, $txt, $dir, $paragraph_align, &$aBoundingBox, $debug = false) |
902 | 926 | { |
903 | 927 | |
@@ -1167,6 +1191,9 @@ discard block |
||
1167 | 1191 | $this->current_color_name = $this->colorstack[--$this->colorstackidx]; |
1168 | 1192 | } |
1169 | 1193 | |
1194 | + /** |
|
1195 | + * @param integer $weight |
|
1196 | + */ |
|
1170 | 1197 | public function SetLineWeight($weight) |
1171 | 1198 | { |
1172 | 1199 | $old = $this->line_weight; |
@@ -1181,6 +1208,10 @@ discard block |
||
1181 | 1208 | $this->lasty = round($y); |
1182 | 1209 | } |
1183 | 1210 | |
1211 | + /** |
|
1212 | + * @param integer $s |
|
1213 | + * @param integer $e |
|
1214 | + */ |
|
1184 | 1215 | public function Arc($cx, $cy, $w, $h, $s, $e) |
1185 | 1216 | { |
1186 | 1217 | // GD Arc doesn't like negative angles |
@@ -1288,6 +1319,10 @@ discard block |
||
1288 | 1319 | } |
1289 | 1320 | |
1290 | 1321 | // Set line style dashed, dotted etc |
1322 | + |
|
1323 | + /** |
|
1324 | + * @param string $s |
|
1325 | + */ |
|
1291 | 1326 | public function SetLineStyle($s) |
1292 | 1327 | { |
1293 | 1328 | if (is_numeric($s)) { |
@@ -1503,6 +1538,13 @@ discard block |
||
1503 | 1538 | $this->FilledPolygon([$xl, $yu, $xr, $yu, $xr, $yl, $xl, $yl]); |
1504 | 1539 | } |
1505 | 1540 | |
1541 | + /** |
|
1542 | + * @param integer $xl |
|
1543 | + * @param integer $yu |
|
1544 | + * @param integer $yl |
|
1545 | + * @param string $color1 |
|
1546 | + * @param string $color2 |
|
1547 | + */ |
|
1506 | 1548 | public function FilledRectangle2($xl, $yu, $xr, $yl, $color1, $color2, $style = 1) |
1507 | 1549 | { |
1508 | 1550 | // Fill a rectangle with lines of two colors |
@@ -1536,6 +1578,10 @@ discard block |
||
1536 | 1578 | } |
1537 | 1579 | } |
1538 | 1580 | |
1581 | + /** |
|
1582 | + * @param integer $xl |
|
1583 | + * @param integer $yu |
|
1584 | + */ |
|
1539 | 1585 | public function ShadowRectangle($xl, $yu, $xr, $yl, $fcolor = false, $shadow_width = 4, $shadow_color = 'darkgray', $useAlpha = true) |
1540 | 1586 | { |
1541 | 1587 | // This is complicated by the fact that we must also handle the case where |
@@ -1572,6 +1618,10 @@ discard block |
||
1572 | 1618 | } |
1573 | 1619 | } |
1574 | 1620 | |
1621 | + /** |
|
1622 | + * @param double $xr |
|
1623 | + * @param double $yl |
|
1624 | + */ |
|
1575 | 1625 | public function FilledRoundedRectangle($xt, $yt, $xr, $yl, $r = 5) |
1576 | 1626 | { |
1577 | 1627 | if ($r == 0) { |
@@ -1603,6 +1653,10 @@ discard block |
||
1603 | 1653 | $this->FilledArc($xr - $r, $yl - $r, $r * 2, $r * 2, 0, 90); |
1604 | 1654 | } |
1605 | 1655 | |
1656 | + /** |
|
1657 | + * @param double $xr |
|
1658 | + * @param double $yl |
|
1659 | + */ |
|
1606 | 1660 | public function RoundedRectangle($xt, $yt, $xr, $yl, $r = 5) |
1607 | 1661 | { |
1608 | 1662 | if ($r == 0) { |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | private $_bottom_margin = 30; |
46 | 46 | //private $_plotwidth=0,$_plotheight=0; |
47 | 47 | private $_width = 0; |
48 | - private $_height = 0; |
|
48 | + private $_height = 0; |
|
49 | 49 | private $_line_weight = 1; |
50 | 50 | |
51 | 51 | protected $expired = true; |
@@ -53,15 +53,15 @@ discard block |
||
53 | 53 | protected $lasty = 0; |
54 | 54 | protected $obs_list = []; |
55 | 55 | protected $font_size = 12; |
56 | - protected $font_family = FF_DEFAULT; |
|
57 | - protected $font_style = FS_NORMAL; |
|
56 | + protected $font_family = FF_DEFAULT; |
|
57 | + protected $font_style = FS_NORMAL; |
|
58 | 58 | protected $font_file = ''; |
59 | 59 | protected $text_halign = "left"; |
60 | 60 | protected $text_valign = "bottom"; |
61 | 61 | protected $use_anti_aliasing = false; |
62 | 62 | protected $quality = null; |
63 | 63 | protected $colorstack = []; |
64 | - protected $colorstackidx = 0; |
|
64 | + protected $colorstackidx = 0; |
|
65 | 65 | protected $canvascolor = 'white'; |
66 | 66 | protected $langconv = null; |
67 | 67 | protected $iInterlace = false; |