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="9123Modifyingtheboxaroundtheplot.html"><LINK REL="Next" HREF="9125AddingiconstoGanttgraphs.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="9123Modifyingtheboxaroundtheplot.html">Previous</A><A HREF="9125AddingiconstoGanttgraphs.html">Next</A><HR NOSHADE><H3><A NAME="9_12_4">9.12.4 Horizontal grids and alternating line colors</A></H3><P> In order to make large charts easier to read it is possible tospecify alternating an horizontal grid and optional alternating linecolors in the background for Gantt charts. The horizontal grid isaccessed through the<I> Graph::hgrid</I> property and the line (used inthe grid) is accessed through the<I> Graph::hgrid::line</I>sub-property</P><P> In order to specify the alternating line colors the<I>SetRowFillColor()</I> method is used. For example, to use alternatingblue background with blue grid line the following lines would have tobe added to the graph script<DIV class="phpscript"><CODE><FONT color="#000000"><FONT color="#0000BB"> </FONT><FONT color="#FF8000">// Setup a horizontal grid<BR></FONT><FONT color="#0000BB">$graph</FONT><FONT color="#007700">-></FONT><FONTcolor="#0000BB">hgrid</FONT><FONT color="#007700">-></FONT><FONT color="#0000BB">Show</FONT><FONT color="#007700">();<BR></FONT><FONT color="#0000BB">$graph</FONT><FONT color="#007700">-></FONT><FONTcolor="#0000BB">hgrid</FONT><FONT color="#007700">-></FONT><FONT color="#0000BB">line</FONT><FONT color="#007700">-></FONT><FONT color="#0000BB">SetColor</FONT><FONTcolor="#007700">(</FONT><FONT color="#DD0000">'lightblue'</FONT><FONT color="#007700">);<BR></FONT><FONT color="#0000BB">$graph</FONT><FONT color="#007700">-></FONT><FONTcolor="#0000BB">hgrid</FONT><FONT color="#007700">-></FONT><FONT color="#0000BB">SetRowFillColor</FONT><FONT color="#007700">(</FONT><FONT color="#DD0000">'darkblue@0.9'</FONT><FONT color="#007700">);</FONT><FONT color="#0000BB"></FONT></FONT></CODE></DIV></P><P> Below is an example of a Gantt graph using this formatting<DIV class="example"><BR> <A href="exframes/frame_gantthgridex1.html" target="blank"><IMG border="0"HEIGHT="253" src="img/img/img/img/img/img/gantthgridex1.png" WIDTH="500"></A><BR><B>Figure 169:</B> Adding a horizontal grid to the graph <A href="exframes/frame_gantthgridex1.html"target="blank">[src]</A> <P></P></DIV></P><P></P><HR NOSHADE><A HREF="toc.html">Contents</A><A HREF="9123Modifyingtheboxaroundtheplot.html">Previous</A><A HREF="9125AddingiconstoGanttgraphs.html">Next</A></BODY></HTML>