Shape.html 50.3 KB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><HTML><HEAD><style type="text/css">
		<!--
		A:link        {font-family: helvetica, arial, geneva, sans-serif; font-size: small; text-decoration: none; color: #000000}
		A:visited     {font-family: helvetica, arial, geneva, sans-serif; font-size: small; text-decoration: none; color: #000000}
		A:hover       {font-family: helvetica, arial, geneva, sans-serif; font-size: small; text-decoration: underline; color: #FF0000}
        A.no:link        {font-family:inherit; font-size: inhreit;text-decoration: none; color: #000000}
        A.no:visited     {font-family:inherit; font-size: inherit;text-decoration: none; color: #000000}
        A.no:hover       {font-family:inherit; font-size: inherit;text-decoration: none; color: #000000}
		th            {font-family: helvetica, arial; color : black; font-size:90%; background : #b7c8b7; border-right:black solid 1pt; border-bottom:black solid 1pt;}
        td            {font-family: helvetica, arial; color : black; font-size:90%; background : white; border-right:black solid 1pt; border-bottom:black solid 1pt;}

		//-->
		</style></HEAD><hr><div style="padding-left:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;background-color:#deaa87;font-family:courier new;font-size:16pt;">Class <a class="no" name="_C_SHAPE"><b>Shape</b></a></div>
<i>(Defined in: jpgraph_canvtools.php : 69)</i><br>&nbsp;<br><table cellspaceing=0 cellpadding=4 style="border:solid #303030 1px;"><tr><td align="center" style="background:lightgray;" >&nbsp;<a href="Shape.html" style="font-family:arial;font-weight:bold;color:darkblue;">Shape</a>&nbsp;</td></tr><tr><td valign=top>&nbsp;<a href="Shape.html#_SHAPE_BEZIER">Bezier()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_CIRCLE">Circle()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_FILLEDCIRCLE">FilledCircle()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_FILLEDPOLYGON">FilledPolygon()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_FILLEDRECTANGLE">FilledRectangle()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_FILLEDROUNDEDRECTANGLE">FilledRoundedRectangle()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_INDENTEDRECTANGLE">IndentedRectangle()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_LINE">Line()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_POLYGON">Polygon()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_RECTANGLE">Rectangle()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_ROUNDEDRECTANGLE">RoundedRectangle()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_SETCOLOR">SetColor()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_SETTEXTALIGN">SetTextAlign()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE_SHADOWRECTANGLE">ShadowRectangle()</a>&nbsp;<br>
&nbsp;<a href="Shape.html#_SHAPE___CONSTRUCT">__construct()</a>&nbsp;<br>
</td></tr></table>&nbsp;<p><div style="font-weight:bold;font-family:arial;font-size:100%;">Class usage and Overview</div>This is mainly awrapper class around thye current image class used. It is meant to make it easier to work with a Canvas graph and a Canvas scale. Basically the class uses the specified scale to trasnalte coordinates which is then passed on to the standard Image routines.
 <p> &nbsp;
<div style="font-weight:bold;font-family:arial;font-size:85%;">See also related classes:</div><a href="CanvasScale.html">CanvasScale</a> <p> &nbsp;<hr><span style="font-family:arial;font-size:120%;font-weight:bold;">Class Methods</span><hr><p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_BEZIER"><span style="color:#555555;">Shape ::</span><br><b>Bezier</b>($p, $aSteps)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a bezier curve </i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$p</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Array with control points</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$aSteps</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">40</span>
</span>
</td><td>Number of line segments in curve</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a Bezier line with specified in the $p array. The points are specified according to the current scale. The positions in the array has the following meaning
<p>
(0,1) x0,y0 (First point on curver)<br>
(2,3) x,y, (Control point 1)<br>
(4,5) x,y, (Control point 2)<br>
(6,7) x,y, (End point of curve)<br>
<p>
See example in canvasbezierex1.php

&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB">$p&nbsp;</span><span style="color: #007700">=&nbsp;array(</span><span style="color: #0000BB">3</span><span style="color: #007700">,</span><span style="color: #0000BB">6</span><span style="color: #007700">,</span><span style="color: #0000BB">6</span><span style="color: #007700">,</span><span style="color: #0000BB">9</span><span style="color: #007700">,</span><span style="color: #0000BB">5</span><span style="color: #007700">,</span><span style="color: #0000BB">3</span><span style="color: #007700">,</span><span style="color: #0000BB">7</span><span style="color: #007700">,</span><span style="color: #0000BB">4</span><span style="color: #007700">);<br /><br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetColor</span><span style="color: #007700">(</span><span style="color: #DD0000">'black'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">Bezier</span><span style="color: #007700">(</span><span style="color: #0000BB">$p</span><span style="color: #007700">);<br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_CIRCLE"><span style="color:#555555;">Shape ::</span><br><b>Circle</b>($x1, $y1, $r)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a circle</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Center X-coordinate</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Center Y-coordinate</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$r</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Radius</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a circle onto the canvas
&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:90%;">See also:</div><ul><li><a href="Image.html#_IMAGE_CIRCLE">Image::Circle()</a></ul>
<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #FF8000">//&nbsp;The&nbsp;shape&nbsp;class&nbsp;is&nbsp;wrapper&nbsp;around&nbsp;the&nbsp;Imgae&nbsp;class&nbsp;which&nbsp;translates<br />//&nbsp;the&nbsp;coordinates&nbsp;for&nbsp;us<br /></span><span style="color: #0000BB">$shape&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">Shape</span><span style="color: #007700">(</span><span style="color: #0000BB">$g</span><span style="color: #007700">,</span><span style="color: #0000BB">$scale</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetColor</span><span style="color: #007700">(</span><span style="color: #DD0000">'black'</span><span style="color: #007700">);<br /><br /><br /></span><span style="color: #FF8000">//&nbsp;..&nbsp;and&nbsp;a&nbsp;circle&nbsp;(x,y,diameter)<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">Circle</span><span style="color: #007700">(</span><span style="color: #0000BB">5</span><span style="color: #007700">,</span><span style="color: #0000BB">14</span><span style="color: #007700">,</span><span style="color: #0000BB">2</span><span style="color: #007700">);<br /><br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_FILLEDCIRCLE"><span style="color:#555555;">Shape ::</span><br><b>FilledCircle</b>($x1, $y1, $r)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a filled circle to a canvas</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Center X-coordinate</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Center Y-coordinate</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$r</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Radius</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a filled circle on the canvas using the specified scale.
<p>
Note: If you are using GD1.xx you will see moire-patterns in large circles. This is due to the lack of a proper filled circle function in GD 1.xx. Using GD 2.xx will avoid this problem. 
&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:90%;">See also:</div><ul><li><a href="Image.html#_IMAGE_FILLEDCIRCLE">Image::FilledCircle()</a></ul>
<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #FF8000">//&nbsp;The&nbsp;shape&nbsp;class&nbsp;is&nbsp;wrapper&nbsp;around&nbsp;the&nbsp;Imgae&nbsp;class&nbsp;which&nbsp;translates<br />//&nbsp;the&nbsp;coordinates&nbsp;for&nbsp;us<br /></span><span style="color: #0000BB">$shape&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">Shape</span><span style="color: #007700">(</span><span style="color: #0000BB">$g</span><span style="color: #007700">,</span><span style="color: #0000BB">$scale</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetColor</span><span style="color: #007700">(</span><span style="color: #DD0000">'black'</span><span style="color: #007700">);<br /><br /><br /></span><span style="color: #FF8000">//&nbsp;..&nbsp;and&nbsp;a&nbsp;circle&nbsp;(x,y,diameter)<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">FilledCircle</span><span style="color: #007700">(</span><span style="color: #0000BB">5</span><span style="color: #007700">,</span><span style="color: #0000BB">14</span><span style="color: #007700">,</span><span style="color: #0000BB">2</span><span style="color: #007700">);<br /><br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_FILLEDPOLYGON"><span style="color:#555555;">Shape ::</span><br><b>FilledPolygon</b>($p)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a filled polygon</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$p</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Polygon array</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a filled polygon&nbsp;<br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_FILLEDRECTANGLE"><span style="color:#555555;">Shape ::</span><br><b>FilledRectangle</b>($x1, $y1, $x2, $y2)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a filled rectangle on the canvas</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right Y</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a filled rectangle on the canvas using the current sclae.
&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB"><br /></span><span style="color: #FF8000">//&nbsp;..&nbsp;add&nbsp;a&nbsp;rectangle<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetColor</span><span style="color: #007700">(</span><span style="color: #DD0000">'green'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">FilledRectangle</span><span style="color: #007700">(</span><span style="color: #0000BB">15</span><span style="color: #007700">,</span><span style="color: #0000BB">8</span><span style="color: #007700">,</span><span style="color: #0000BB">19</span><span style="color: #007700">,</span><span style="color: #0000BB">14</span><span style="color: #007700">);<br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_FILLEDROUNDEDRECTANGLE"><span style="color:#555555;">Shape ::</span><br><b>FilledRoundedRectangle</b>($x1, $y1, $x2, $y2, $r)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Create a filled rectangle with rounded corners</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$r</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">null</span>
</span>
</td><td>Corner radius</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Create a filled rectangle with rounded corners&nbsp;<br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_INDENTEDRECTANGLE"><span style="color:#555555;">Shape ::</span><br><b>IndentedRectangle</b>($xt, $yt, $w, $h, $iw, $ih, $aCorner, $aFillColor, $r)</a></div>

<span style='font-family:arial;font-size:95%;'><i>A filled rectangle with one corner 'indented'</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$xt</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$yt</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$w</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Width</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$h</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Height</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$iw</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">0</span>
</span>
</td><td>Indented width</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$ih</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">0</span>
</span>
</td><td>Indeted height</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$aCorner</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">3</span>
</span>
</td><td>Corner to indent</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$aFillColor</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #DD0000">""</span><span style="color: #0000BB"></span>
</span>
</td><td>Fill color</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$r</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">4</span>
</span>
</td><td>Corner radius</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>A rounded rectangle where one of the corner has been moved "into" the rectangle. The indention is determined by the two argument
'iw' width and 'ih' height. 
<p>
The corners (as used in the $aCorner) are numbered as 
0=Top left, 1=top right, 2=bottom right, 3=bottom left
&nbsp;<br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_LINE"><span style="color:#555555;">Shape ::</span><br><b>Line</b>($x1, $y1, $x2, $y2)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a line between</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>X1</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Y1</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>X2</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Y2</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a line between two points in the canvas using the current scale.&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:90%;">See also:</div><ul><li><a href="Image.html#_IMAGE_LINE">Image::Line()</a></ul>
<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB"><br /></span><span style="color: #FF8000">//&nbsp;Add&nbsp;a&nbsp;black&nbsp;line<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetColor</span><span style="color: #007700">(</span><span style="color: #DD0000">'black'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">Line</span><span style="color: #007700">(</span><span style="color: #0000BB">0</span><span style="color: #007700">,</span><span style="color: #0000BB">0</span><span style="color: #007700">,</span><span style="color: #0000BB">20</span><span style="color: #007700">,</span><span style="color: #0000BB">20</span><span style="color: #007700">);<br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_POLYGON"><span style="color:#555555;">Shape ::</span><br><b>Polygon</b>($p, $aClosed)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a closed polygon</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$p</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Array of points in polygon</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$aClosed</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">false</span>
</span>
</td><td>No description available</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a closed polygon&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB">$p&nbsp;</span><span style="color: #007700">=&nbsp;array(</span><span style="color: #0000BB">3</span><span style="color: #007700">,</span><span style="color: #0000BB">6</span><span style="color: #007700">,</span><span style="color: #0000BB">6</span><span style="color: #007700">,</span><span style="color: #0000BB">9</span><span style="color: #007700">,</span><span style="color: #0000BB">5</span><span style="color: #007700">,</span><span style="color: #0000BB">3</span><span style="color: #007700">,</span><span style="color: #0000BB">7</span><span style="color: #007700">,</span><span style="color: #0000BB">4</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetColor</span><span style="color: #007700">(</span><span style="color: #DD0000">'blue:0.35'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">Polygon</span><span style="color: #007700">(</span><span style="color: #0000BB">$p</span><span style="color: #007700">);</span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_RECTANGLE"><span style="color:#555555;">Shape ::</span><br><b>Rectangle</b>($x1, $y1, $x2, $y2)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a rectangle on the canvas</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right Y</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a rectangle on the canvas using the current scale.&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #FF8000">//&nbsp;..&nbsp;add&nbsp;a&nbsp;rectangle<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetColor</span><span style="color: #007700">(</span><span style="color: #DD0000">'green'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">Rectangle</span><span style="color: #007700">(</span><span style="color: #0000BB">15</span><span style="color: #007700">,</span><span style="color: #0000BB">8</span><span style="color: #007700">,</span><span style="color: #0000BB">19</span><span style="color: #007700">,</span><span style="color: #0000BB">14</span><span style="color: #007700">);<br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_ROUNDEDRECTANGLE"><span style="color:#555555;">Shape ::</span><br><b>RoundedRectangle</b>($x1, $y1, $x2, $y2, $r)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a rectangle with rounded corners</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$r</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">null</span>
</span>
</td><td>Corner radius</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a rectangle with rounded corners&nbsp;<br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_SETCOLOR"><span style="color:#555555;">Shape ::</span><br><b>SetColor</b>($aColor)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Specify color to use when drawing shapes</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$aColor</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Color specification</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Specify color to use when drawing shapes&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:90%;">See also:</div><ul><li><a href="RGB.html#_RGB_COLOR">RGB::Color()</a></ul>
<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #FF8000">//&nbsp;Add&nbsp;a&nbsp;black&nbsp;line<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetColor</span><span style="color: #007700">(</span><span style="color: #DD0000">'black'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">Line</span><span style="color: #007700">(</span><span style="color: #0000BB">0</span><span style="color: #007700">,</span><span style="color: #0000BB">0</span><span style="color: #007700">,</span><span style="color: #0000BB">20</span><span style="color: #007700">,</span><span style="color: #0000BB">20</span><span style="color: #007700">);<br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_SETTEXTALIGN"><span style="color:#555555;">Shape ::</span><br><b>SetTextAlign</b>($halign, $valign)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Specify bae point for StrokeText()</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$halign</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Horizontal position for basepoint</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$valign</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #DD0000">"bottom"</span><span style="color: #0000BB"></span>
</span>
</td><td>Vertical position for base point</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Specifies how the coordinate for the text should be interpretated. Possible values for horizontal base-position are

<ul>
<li> "left"
<li> "center"
<li> "right"
</ul>

and for vertical


<ul>
<li> "top"
<li> "center"
<li> "bottom"
</ul>
&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #FF8000">//&nbsp;Interpret&nbsp;the&nbsp;text&nbsp;coordinate&nbsp;as&nbsp;beeing&nbsp;the<br />//&nbsp;top&nbsp;left&nbsp;corner&nbsp;of&nbsp;the&nbsp;bounding&nbsp;box&nbsp;for&nbsp;the&nbsp;text<br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetTextAlign</span><span style="color: #007700">(</span><span style="color: #DD0000">'left'</span><span style="color: #007700">,</span><span style="color: #DD0000">'top'</span><span style="color: #007700">);<br /><br /></span><span style="color: #0000BB">$shape</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">StrokeText</span><span style="color: #007700">(....)<br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE_SHADOWRECTANGLE"><span style="color:#555555;">Shape ::</span><br><b>ShadowRectangle</b>($x1, $y1, $x2, $y2, $fcolor, $shadow_width, $shadow_color)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Draw a filled rectangle with a drop shadow</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y1</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Top left Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$x2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right X</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$y2</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>Bottom right Y</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$fcolor</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">false</span>
</span>
</td><td>Fill color</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$shadow_width</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">null</span>
</span>
</td><td>Shadow width</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$shadow_color</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #007700">array(</span><span style="color: #0000BB">102</span><span style="color: #007700">,</span><span style="color: #0000BB">102</span><span style="color: #007700">,</span><span style="color: #0000BB">102</span><span style="color: #007700">)</span><span style="color: #0000BB"></span>
</span>
</td><td>Shadow color</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Draw a filled rectangle with a drop shadow&nbsp;<br>
<p>
<p> &nbsp; <div style='font-family: helvetica, arial, geneva, sans-serif;margin-bottom:4px;border-left:solid black 1px;border-top:solid black 1px;border-bottom:solid black 2px;border-right:solid black 2px;font-size:120%;background:#dde9af;padding:4px;'><a class="no" name="_SHAPE___CONSTRUCT"><span style="color:#555555;">Shape ::</span><br><b>__construct</b>($aGraph, $scale)</a></div>

<span style='font-family:arial;font-size:95%;'><i>Methods to draw shapes on canvas</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$aGraph</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>No description available</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'><span style="color: #000000">
<span style="color: #0000BB">$scale</span>
</span>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:100%;font-weight:bold;'>&nbsp;</td><td>No description available</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:90%;">Description:</div>Create a new shape class used to draw siple shape onto a canvas using the specified scale.&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:90%;">See also:</div><ul><li><a href="CanvasGraph.html#_CANVASGRAPH___CONSTRUCT">CanvasGraph::__construct()</a><li><a href="CanvasScale.html#_CANVASSCALE___CONSTRUCT">CanvasScale::__construct()</a></ul>
<div style="font-weight:bold;font-family:arial;font-size:90%;"><p>Example:</div><div style="padding:5px;border:dashed gray 1px;background-color:#f3f3f3;font-family:courier new;font-size:90%;font-weight:bold;"><b><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #FF8000">//&nbsp;Setup&nbsp;a&nbsp;basic&nbsp;canvas&nbsp;we&nbsp;can&nbsp;work&nbsp;<br /></span><span style="color: #0000BB">$g&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">CanvasGraph</span><span style="color: #007700">(</span><span style="color: #0000BB">400</span><span style="color: #007700">,</span><span style="color: #0000BB">200</span><span style="color: #007700">,</span><span style="color: #DD0000">'auto'</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$g</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetMargin</span><span style="color: #007700">(</span><span style="color: #0000BB">5</span><span style="color: #007700">,</span><span style="color: #0000BB">11</span><span style="color: #007700">,</span><span style="color: #0000BB">6</span><span style="color: #007700">,</span><span style="color: #0000BB">11</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$g</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetShadow</span><span style="color: #007700">();<br /></span><span style="color: #0000BB">$g</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">SetMarginColor</span><span style="color: #007700">(</span><span style="color: #DD0000">"teal"</span><span style="color: #007700">);<br /><br /></span><span style="color: #FF8000">//&nbsp;We&nbsp;need&nbsp;to&nbsp;stroke&nbsp;the&nbsp;plotarea&nbsp;and&nbsp;margin&nbsp;before&nbsp;we&nbsp;add&nbsp;the<br />//&nbsp;text&nbsp;since&nbsp;we&nbsp;otherwise&nbsp;would&nbsp;overwrite&nbsp;the&nbsp;text.<br /></span><span style="color: #0000BB">$g</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">InitFrame</span><span style="color: #007700">();<br /><br /></span><span style="color: #FF8000">//&nbsp;Create&nbsp;a&nbsp;new&nbsp;scale<br /></span><span style="color: #0000BB">$scale&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">CanvasScale</span><span style="color: #007700">(</span><span style="color: #0000BB">$g</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$scale</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">Set</span><span style="color: #007700">(</span><span style="color: #0000BB">0</span><span style="color: #007700">,</span><span style="color: #0000BB">$xmax</span><span style="color: #007700">,</span><span style="color: #0000BB">0</span><span style="color: #007700">,</span><span style="color: #0000BB">$ymax</span><span style="color: #007700">);<br /><br /></span><span style="color: #FF8000">//&nbsp;The&nbsp;shape&nbsp;class&nbsp;is&nbsp;wrapper&nbsp;around&nbsp;the&nbsp;Imgae&nbsp;class&nbsp;which&nbsp;translates<br />//&nbsp;the&nbsp;coordinates&nbsp;for&nbsp;us<br /></span><span style="color: #0000BB">$shape&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">Shape</span><span style="color: #007700">(</span><span style="color: #0000BB">$g</span><span style="color: #007700">,</span><span style="color: #0000BB">$scale</span><span style="color: #007700">);<br /></span><span style="color: #0000BB"></span>
</span>
</b></div><br>
<p> <hr> <p></html>