Blame | Letzte Änderung | Log anzeigen | RSS feed
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd"><HTML><HEAD><META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=iso-iso-8859-1"><LINK REL="Start" HREF="index.html"><LINK REL="Contents" HREF="toc.html"><LINK REL="Prev" HREF="820Adjustingtheautoscalinglimitsgracevalue.html"><LINK REL="Next" HREF="8211Customizingthepatterns.html"><STYLE TYPE="text/css"><!--BODY { font-family: serif }H1 { font-family: sans-serif }H2 { font-family: sans-serif }H3 { font-family: sans-serif }H4 { font-family: sans-serif }H5 { font-family: sans-serif }H6 { font-family: sans-serif }SUB { font-size: smaller }SUP { font-size: smaller }PRE { font-family: monospace }A { text-decoration: none }--></STYLE></HEAD><BODY><A HREF="toc.html">Contents</A><A HREF="820Adjustingtheautoscalinglimitsgracevalue.html">Previous</A><A HREF="8211Customizingthepatterns.html">Next</A><HR NOSHADE><H2><A NAME="8_21">8.21 Adding bands of pattern and color to graphs</A></H2><P> As an additional way of emphasizing certain areas of the graph it ispossible to add bands (either vertical or horizontal) to any one of thestandard X-Y coordinate system based graphs. A band is a rectangulararea that stretches one entire axis. This means that if you define aband between X-coordinates 3 and 5 the band area will occupy an areabetween the X-coordinates and the entire Y-range.</P><P> In order to access this functionality you must first make sure thatyou include the additional library file<I> jpgraph_plotband.php</I></P><P> At the time of this writing (current as of JpGraph 1.8) the tablebelow illustrates the 8 basic types of patterns available. We willshortly show you how you can customize these patterns, To keep theseexamples clear we have only used one pattern in each figure.</P><P></P><TABLE style="margin-left:-4em;"><TR><TD><DIV class="example"><BR> <A href="exframes/frame_smallstaticbandsex1.html" target="blank"><IMGborder="0" HEIGHT="150" src="img/smallstaticbandsex1.png" WIDTH="200"></A><BR><B>Figure 99:</B> <A href="exframes/frame_smallstaticbandsex1.html" target="blank">[src]</A> <P></P></DIV><P></P></TD><TD><DIV class="example"><BR> <A href="exframes/frame_smallstaticbandsex2.html" target="blank"><IMGborder="0" HEIGHT="150" src="img/smallstaticbandsex2.png" WIDTH="200"></A><BR><B>Figure 100:</B> <A href="exframes/frame_smallstaticbandsex2.html" target="blank">[src]</A> <P></P></DIV><P></P></TD></TR><TR><TD><DIV class="example"><BR> <A href="exframes/frame_smallstaticbandsex7.html" target="blank"><IMGborder="0" HEIGHT="150" src="img/smallstaticbandsex7.png" WIDTH="200"></A><BR><B>Figure 101:</B> <A href="exframes/frame_smallstaticbandsex7.html" target="blank">[src]</A> <P></P></DIV><P></P></TD><TD><DIV class="example"><BR> <A href="exframes/frame_smallstaticbandsex6.html" target="blank"><IMGborder="0" HEIGHT="150" src="img/smallstaticbandsex6.png" WIDTH="200"></A><BR><B>Figure 102:</B> <A href="exframes/frame_smallstaticbandsex6.html" target="blank">[src]</A> <P></P></DIV><P></P></TD></TR><TR><TD><DIV class="example"><BR> <A href="exframes/frame_smallstaticbandsex9.html" target="blank"><IMGborder="0" HEIGHT="150" src="img/smallstaticbandsex9.png" WIDTH="200"></A><BR><B>Figure 103:</B> <A href="exframes/frame_smallstaticbandsex9.html" target="blank">[src]</A> <P></P></DIV><P></P></TD><TD><DIV class="example"><BR> <A href="exframes/frame_smallstaticbandsex10.html" target="blank"><IMGborder="0" HEIGHT="150" src="img/smallstaticbandsex10.png" WIDTH="200"></A><BR><B>Figure 104:</B> <A href="exframes/frame_smallstaticbandsex10.html"target="blank">[src]</A> <P></P></DIV><P></P></TD></TR><TR><TD><DIV class="example"><BR> <A href="exframes/frame_smallstaticbandsex3.html" target="blank"><IMGborder="0" HEIGHT="150" src="img/smallstaticbandsex3.png" WIDTH="200"></A><BR><B>Figure 105:</B> <A href="exframes/frame_smallstaticbandsex3.html" target="blank">[src]</A> <P></P></DIV><P></P></TD><TD><DIV class="example"><BR> <A href="exframes/frame_smallstaticbandsex8.html" target="blank"><IMGborder="0" HEIGHT="150" src="img/smallstaticbandsex8.png" WIDTH="200"></A><BR><B>Figure 106:</B> <A href="exframes/frame_smallstaticbandsex8.html" target="blank">[src]</A> <P></P></DIV><P></P></TD></TR></TABLE><P> To add a one of these patterns to your graph you need to call themethod <A href="../ref/PlotBand.html#_PLOTBAND_PLOTBAND">PlotBand::PlotBand()</A> The arguments is fairly easy to understand.The pattern you would like to use is specified by using the correctconstant. You can see the name of the correct constants in the figuresabove. You also need to specify if the band should stretch along thevertical or horizontal axis as well as the min and max coordinates forthe band. As coordinates you may also use the special values "min" and"max" which automatically sets the value to the minimum/maximum valueof the scale. The specified numeric value will be automaticallytruncated to fit within the plot area.</P><P> We don't discuss the other arguments further here, instead we referyou to the class reference.</P><HR NOSHADE><A HREF="toc.html">Contents</A><A HREF="820Adjustingtheautoscalinglimitsgracevalue.html">Previous</A><A HREF="8211Customizingthepatterns.html">Next</A></BODY></HTML>