Subversion-Projekte lars-tiefland.php_share

Revision

Blame | Letzte Änderung | Log anzeigen | RSS feed

<style type="text/css">
                <!--
                A:link        {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: none; color: #0000ff}
                A:visited     {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: none; color: #0000ff}
                A:hover       {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: underline; color: #FF0000}
                th            {font-family: helvetica, arial; color : blue; font-size:85%; background : lightgrey; border-right:black solid 1pt; border-bottom:black solid 1pt;}
                //-->
                </style><hr><a name="_C_CANVASRECTANGLETEXT"><div style="background-color:yellow;font-family:courier new;"></a>CLASS <b>CanvasRectangleText</b></div>
<i>(Defined in: jpgraph_canvtools.php : 375)</i><table border=1><tr><td>&nbsp;<a href="CanvasRectangleText.html" style="font-family:arial;font-weight:bold;color:darkblue;">CanvasRectangleText</a>&nbsp;</td></tr><tr><td valign=top>&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_CANVASRECTANGLETEXT">CanvasRectangleText()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_PARAGRAPHALIGN">ParagraphAlign()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_POS">Pos()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SET">Set()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETAUTOMARGIN">SetAutoMargin()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETCOLOR">SetColor()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETCORNERRADIUS">SetCornerRadius()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETFILLCOLOR">SetFillColor()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETFONT">SetFont()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETFONTCOLOR">SetFontColor()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETPOS">SetPos()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETSHADOW">SetShadow()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETTXT">SetTxt()</a>&nbsp;<br>
&nbsp;<a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_STROKE">Stroke()</a>&nbsp;<br>
</td></tr></table>&nbsp;<p><div style="font-weight:bold;font-family:arial;font-size:100%;">Class usage and Overview</div>YOu can use this class to convieniently draw a text on canvas. The text may have multiple lines wher each line is separated by a "\n" (newline) character. 
<p>
The text may also be enclosed in a rounded (possibly filled) rectangle.
 <p> &nbsp;
<div style="font-weight:bold;font-family:arial;font-size:85%;">See also related classes:</div><a href="CanvasGraph.html">CanvasGraph</a> and <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; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_CANVASRECTANGLETEXT"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;CanvasRectangleText($aTxt,$xl,$yt,$w,$h)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Draws a text paragraph inside a rounded, possibly filled, rectangle</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:90%;font-weight:bold;'><font color="#000000">
$aTxt</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
''</font>
</td><td>Text</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Top left X</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Top left Y</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Width</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Height</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Draws a text paragraph inside a rounded, possible filled, rectangle.&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">

<br />$t&nbsp;=&nbsp;new&nbsp;CanvasRectangleText();
<br />$t-&gt;SetFillColor('lightgreen');
<br />$t-&gt;SetFontColor('navy');
<br />$t-&gt;SetFont(FF_ARIAL,FS_NORMAL,16);
<br />$t-&gt;Set("\n\n\n\n\n\n\n\n\n\n\nTTF&nbsp;Fonts",0.5,19,26,32);
<br />$t-&gt;Stroke($g-&gt;img,$scale);
<br /></font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_PARAGRAPHALIGN"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;ParagraphAlign($aParaAlign)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify paragraph alignment for the text</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:90%;font-weight:bold;'><font color="#000000">
$aParaAlign</font>

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

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify paragraph alignment for the text. Alignments can be: 

<ul>
<li> "left"
<li> "center"
<li> "right"
</ul>&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">

<br />$g&nbsp;=&nbsp;new&nbsp;CanvasGraph(550,450);
<br />$scale&nbsp;=&nbsp;new&nbsp;CanvasScale($g);
<br />$scale-&gt;Set(0,27,0,53);
<br />//
<br />$t&nbsp;=&nbsp;new&nbsp;CanvasRectangleText();
<br />$t-&gt;SetFillColor('lightgreen');
<br />$t-&gt;SetFontColor('navy');
<br />$t-&gt;SetFont(FF_ARIAL,FS_NORMAL,16);
<br />$t-&gt;ParagraphAlign('center');
<br />$t-&gt;Set("First&nbsp;line\nSecond&nbsp;line",0.5,19,26,32);
<br />$t-&gt;Stroke($g-&gt;img,$scale);
<br /></font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_POS"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;Pos($xl,$yt,$w,$h)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify position for text</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:90%;font-weight:bold;'><font color="#000000">
$xl</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Top left X</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Top left Y</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Width</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Height</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Set position for text. All coordinates will be translaed according to the current scale used.
&nbsp;<br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SET"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;Set($aTxt,$xl,$yt,$w,$h)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify the text and position</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:90%;font-weight:bold;'><font color="#000000">
$aTxt</font>

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

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

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

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

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

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Width</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Height</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify the text and position. All coordinates will be translated using the specified scale when stroked.&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;SetShadow('');
<br />$t-&gt;SetFont(FF_ARIAL,FS_BOLD,18);
<br />$t-&gt;Set('Family',1,1,8);
<br />$t-&gt;Stroke($g-&gt;img,$scale);</font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETAUTOMARGIN"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetAutoMargin($aMargin)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify auto margin when no specific size is specified</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:90%;font-weight:bold;'><font color="#000000">
$aMargin</font>

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

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify auto margin when no specific size is specified. This margin is used to add extra space around the text and the border around the text.&nbsp;<br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETCOLOR"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetColor($aColor)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Set border color for rectangle</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:90%;font-weight:bold;'><font color="#000000">
$aColor</font>

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

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Set border color for rectangle&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:85%;">See also</div><a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETFONTCOLOR">CanvasRectangleText::SetFontColor</a> and <a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETFILLCOLOR">CanvasRectangleText::SetFillColor</a>
<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;SetColor('navy');</font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETCORNERRADIUS"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetCornerRadius($aRad)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Set radius for 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:90%;font-weight:bold;'><font color="#000000">
$aRad</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
5</font>
</td><td>Radius in pixels</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify the radius for the rounded corners. Specifying the value as 0 will give normal square corners.

&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;SetCornerRadius(15);</font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETFILLCOLOR"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetFillColor($aFillColor)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify fill color for rectangle</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:90%;font-weight:bold;'><font color="#000000">
$aFillColor</font>

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

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify fill color for rectangle&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;SetFillColor('#12A73C');
<br />
<br /></font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETFONT"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetFont($FontFam,$aFontStyle,$aFontSize)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify font</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:90%;font-weight:bold;'><font color="#000000">
$FontFam</font>

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

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

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

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
12</font>
</td><td>Font size</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify font&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;SetFont(FF_ARIAL,FS_BOLD,24);</font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETFONTCOLOR"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetFontColor($aColor)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify text (font) color</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:90%;font-weight:bold;'><font color="#000000">
$aColor</font>

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

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Set color for text. Use SetColor() to specify border colro and SetFillColor() to set fill color.&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:85%;">See also</div><a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETCOLOR">CanvasRectangleText::SetColor</a> and <a href="CanvasRectangleText.html#_CANVASRECTANGLETEXT_SETFILLCOLOR">CanvasRectangleText::SetFillColor</a>
<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;SetFontCOlor('black')</font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETPOS"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetPos($xl,$yt,$w,$h)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify position</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:90%;font-weight:bold;'><font color="#000000">
$xl</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Top left X</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Top left Y</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Width</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
0</font>
</td><td>Height</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify position. All coordinates will be transalted with the specified scale when stroked.&nbsp;<br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETSHADOW"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetShadow($aColor,$aWidth)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Add 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:90%;font-weight:bold;'><font color="#000000">
$aColor</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
'gray'</font>
</td><td>Color of shadow</td></tr>

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

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
3</font>
</td><td>Width of shadow</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Add a drop shadow to the rounded reactangle surranding the text&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;SetShadow();&nbsp;&nbsp;//&nbsp;Use&nbsp;default&nbsp;values
<br /></font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_SETTXT"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetTxt($aTxt)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify text string</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:90%;font-weight:bold;'><font color="#000000">
$aTxt</font>

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

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Set text string to be displayed. The text string may have multiple lines separated by a newline character "\n"&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;Set("This&nbsp;is&nbsp;a&nbsp;text!");
<br /></font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_CANVASRECTANGLETEXT_STROKE"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;Stroke($aImg,$scale)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Stroke text to 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:90%;font-weight:bold;'><font color="#000000">
$aImg</font>

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

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

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

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Stroke text to canvas&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:85%;">See also</div><a href="CanvasScale.html#_CANVASSCALE_CANVASSCALE">CanvasScale::CanvasScale</a>
<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$t-&gt;Stroke($graph-&gt;img,$scale);
<br /></font>
</span><br>
<p> <hr> <p>