| 1 |
lars |
1 |
<style type="text/css">
|
|
|
2 |
<!--
|
|
|
3 |
A:link {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: none; color: #0000ff}
|
|
|
4 |
A:visited {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: none; color: #0000ff}
|
|
|
5 |
A:hover {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: underline; color: #FF0000}
|
|
|
6 |
th {font-family: helvetica, arial; color : blue; font-size:85%; background : lightgrey; border-right:black solid 1pt; border-bottom:black solid 1pt;}
|
|
|
7 |
//-->
|
|
|
8 |
</style><hr><a name="_C_GANTTACTIVITYINFO"><div style="background-color:yellow;font-family:courier new;"></a>CLASS <b>GanttActivityInfo</b></div>
|
|
|
9 |
<i>(Defined in: jpgraph_gantt.php : 142)</i><table border=1><tr><td> <a href="GanttActivityInfo.html" style="font-family:arial;font-weight:bold;color:darkblue;">GanttActivityInfo</a> </td></tr><tr><td valign=top> <a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_HIDE">Hide()</a> <br>
|
|
|
10 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SETBACKGROUNDCOLOR">SetBackgroundColor()</a> <br>
|
|
|
11 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SETCOLOR">SetColor()</a> <br>
|
|
|
12 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SETCOLTITLES">SetColTitles()</a> <br>
|
|
|
13 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SETCOLUMNMARGIN">SetColumnMargin()</a> <br>
|
|
|
14 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SETFONT">SetFont()</a> <br>
|
|
|
15 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SETFONTCOLOR">SetFontColor()</a> <br>
|
|
|
16 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SETHEADERALIGN">SetHeaderAlign()</a> <br>
|
|
|
17 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SETSTYLE">SetStyle()</a> <br>
|
|
|
18 |
<a href="GanttActivityInfo.html#_GANTTACTIVITYINFO_SHOW">Show()</a> <br>
|
|
|
19 |
</td></tr></table> <p><div style="font-weight:bold;font-family:arial;font-size:100%;">Class usage and Overview</div>This class is responsible for handling the titles of the columns in the left section of the Gantt graph, i.e. the information columns for each activity.
|
|
|
20 |
<p>
|
|
|
21 |
It is instantiated in the scale and is accessed through the Gantt scale for example as in
|
|
|
22 |
<p>
|
|
|
23 |
<code>
|
|
|
24 |
$graph->scale->actinfo->SetColTitles(
|
|
|
25 |
array('Note','Name','Duration','Start','Finish'),array(30,100));
|
|
|
26 |
$graph->scale->actinfo->SetBackgroundColor('green:0.5@0.5');
|
|
|
27 |
$graph->scale->actinfo->SetFont(FF_ARIAL,FS_NORMAL,10);
|
|
|
28 |
$graph->scale->actinfo->vgrid->SetStyle('solid');
|
|
|
29 |
$graph->scale->actinfo->vgrid->SetColor('gray');
|
|
|
30 |
</code>
|
|
|
31 |
<p>
|
|
|
32 |
It is optional to use titles for the columns, so if you don't want to use titles you never have to add the above lines to a Gantt graph (but it sure looks nicer if you do ... )
|
|
|
33 |
<p>
|
|
|
34 |
<hr><span style="font-family:arial;font-size:120%;font-weight:bold;">Class Methods</span><hr><p>
|
|
|
35 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_HIDE"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
|
|
|
36 |
function Hide($aF)</font>
|
|
|
37 |
</b></div></a></span>
|
|
|
38 |
|
|
|
39 |
<span style='font-family:arial;font-size:90%;'><i>Hide titles</i></span><p>
|
|
|
40 |
|
|
|
41 |
<table cellspacing=0 style='border:black solid 1pt;' width=100%>
|
|
|
42 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
43 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
44 |
$aF</font>
|
|
|
45 |
|
|
|
46 |
</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
47 |
true</font>
|
|
|
48 |
</td><td>TRUE=Hide titles</td></tr>
|
|
|
49 |
</table>
|
|
|
50 |
|
|
|
51 |
<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Hide titles <br>
|
|
|
52 |
|
|
|
53 |
<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">
|
|
|
54 |
// Hide the titles
<br />$graph->scale->actinfo->Hide();</font>
|
|
|
55 |
</span><br>
|
|
|
56 |
<p>
|
|
|
57 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_SETBACKGROUNDCOLOR"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
|
|
|
58 |
function SetBackgroundColor($aColor)</font>
|
|
|
59 |
</b></div></a></span>
|
|
|
60 |
|
|
|
61 |
|
|
|
62 |
|
|
|
63 |
|
|
|
64 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
65 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
66 |
$aColor</font>
|
|
|
67 |
|
|
|
68 |
|
|
|
69 |
</table>
|
|
|
70 |
|
|
|
71 |
|
|
|
72 |
|
|
|
73 |
|
|
|
74 |
$graph->scale->actinfo->SetBackgroundColor('green:0.5@0.5');</font>
|
|
|
75 |
</span><br>
|
|
|
76 |
<p>
|
|
|
77 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_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">
|
|
|
78 |
function SetColor($aColor)</font>
|
|
|
79 |
</b></div></a></span>
|
|
|
80 |
|
|
|
81 |
|
|
|
82 |
|
|
|
83 |
|
|
|
84 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
85 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
86 |
$aColor</font>
|
|
|
87 |
|
|
|
88 |
|
|
|
89 |
</table>
|
|
|
90 |
|
|
|
91 |
|
|
|
92 |
|
|
|
93 |
|
|
|
94 |
$graph->scale->actinfo->SetColor('navy');</font>
|
|
|
95 |
</span><br>
|
|
|
96 |
<p>
|
|
|
97 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_SETCOLTITLES"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
|
|
|
98 |
function SetColTitles($aTitles,$aWidth)</font>
|
|
|
99 |
</b></div></a></span>
|
|
|
100 |
|
|
|
101 |
|
|
|
102 |
|
|
|
103 |
|
|
|
104 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
105 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
106 |
$aTitles</font>
|
|
|
107 |
|
|
|
108 |
|
|
|
109 |
|
|
|
110 |
|
|
|
111 |
$aWidth</font>
|
|
|
112 |
|
|
|
113 |
|
|
|
114 |
null</font>
|
|
|
115 |
</td><td>Optional width for each column</td></tr>
|
|
|
116 |
</table>
|
|
|
117 |
|
|
|
118 |
|
|
|
119 |
<p>
|
|
|
120 |
It is perfectly legal to just specify the explicit width of the first few columns and have the rest of them become automatically sized. See eamplebelow.
|
|
|
121 |
<br>
|
|
|
122 |
|
|
|
123 |
|
|
|
124 |
// Specify some titles and explicitely set the size of the
<br />// first two columns.
<br />$graph->scale->actinfo->SetColTitles(
<br /> array('Note','Name','Duration','Start','Finish'),array(30,100));
<br /></font>
|
|
|
125 |
</span><br>
|
|
|
126 |
<p>
|
|
|
127 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_SETCOLUMNMARGIN"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
|
|
|
128 |
function SetColumnMargin($aLeft,$aRight)</font>
|
|
|
129 |
</b></div></a></span>
|
|
|
130 |
|
|
|
131 |
<span style='font-family:arial;font-size:90%;'><i>Specify extra margin to the left and right of the text in each column</i></span><p>
|
|
|
132 |
|
|
|
133 |
<table cellspacing=0 style='border:black solid 1pt;' width=100%>
|
|
|
134 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
135 |
|
|
|
136 |
$aLeft</font>
|
|
|
137 |
|
|
|
138 |
</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'> </td><td>Left margin (in pixels)</td></tr>
|
|
|
139 |
|
|
|
140 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
141 |
$aRight</font>
|
|
|
142 |
|
|
|
143 |
</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'> </td><td>Right margin (in pixels)</td></tr>
|
|
|
144 |
|
|
|
145 |
|
|
|
146 |
<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify extra margin to the left and right of the text in each column <br>
|
|
|
147 |
|
|
|
148 |
<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">
|
|
|
149 |
$graph->scale->actinfo->SetColumnMargin(30,30);
<br /></font>
|
|
|
150 |
|
|
|
151 |
<p>
|
|
|
152 |
|
|
|
153 |
function SetFont($aFFamily,$aFStyle,$aFSize)</font>
|
|
|
154 |
</b></div></a></span>
|
|
|
155 |
|
|
|
156 |
<span style='font-family:arial;font-size:90%;'><i>Specify title font</i></span><p>
|
|
|
157 |
|
|
|
158 |
<table cellspacing=0 style='border:black solid 1pt;' width=100%>
|
|
|
159 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
160 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
161 |
|
|
|
162 |
|
|
|
163 |
|
|
|
164 |
|
|
|
165 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
166 |
$aFStyle</font>
|
|
|
167 |
|
|
|
168 |
|
|
|
169 |
FS_NORMAL</font>
|
|
|
170 |
|
|
|
171 |
|
|
|
172 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
173 |
|
|
|
174 |
|
|
|
175 |
</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
176 |
10</font>
|
|
|
177 |
|
|
|
178 |
</table>
|
|
|
179 |
|
|
|
180 |
|
|
|
181 |
|
|
|
182 |
<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">
|
|
|
183 |
$graph->scale->actinfo->SetFont(FF_ARIAL,FS_NORMAL,10);</font>
|
|
|
184 |
</span><br>
|
|
|
185 |
|
|
|
186 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_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">
|
|
|
187 |
|
|
|
188 |
</b></div></a></span>
|
|
|
189 |
|
|
|
190 |
<span style='font-family:arial;font-size:90%;'><i>Specify title font color</i></span><p>
|
|
|
191 |
|
|
|
192 |
<table cellspacing=0 style='border:black solid 1pt;' width=100%>
|
|
|
193 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
194 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
195 |
|
|
|
196 |
|
|
|
197 |
|
|
|
198 |
</table>
|
|
|
199 |
|
|
|
200 |
<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify title font color <br>
|
|
|
201 |
|
|
|
202 |
|
|
|
203 |
$graph->scale->actinfo->SetFontColor('navy');</font>
|
|
|
204 |
</span><br>
|
|
|
205 |
|
|
|
206 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_SETHEADERALIGN"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
|
|
|
207 |
|
|
|
208 |
</b></div></a></span>
|
|
|
209 |
|
|
|
210 |
<span style='font-family:arial;font-size:90%;'><i>Adjust headers left, right or centered</i></span><p>
|
|
|
211 |
|
|
|
212 |
<table cellspacing=0 style='border:black solid 1pt;' width=100%>
|
|
|
213 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
214 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
215 |
|
|
|
216 |
|
|
|
217 |
|
|
|
218 |
</table>
|
|
|
219 |
|
|
|
220 |
<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Adjust headers left, right or centered. By default headers are centered. <br>
|
|
|
221 |
|
|
|
222 |
|
|
|
223 |
$graph->scale->actinfo->SetHeaderAlign('left');</font>
|
|
|
224 |
</span><br>
|
|
|
225 |
|
|
|
226 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_SETSTYLE"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
|
|
|
227 |
|
|
|
228 |
</b></div></a></span>
|
|
|
229 |
|
|
|
230 |
<span style='font-family:arial;font-size:90%;'><i>Enable 3D header style</i></span><p>
|
|
|
231 |
|
|
|
232 |
<table cellspacing=0 style='border:black solid 1pt;' width=100%>
|
|
|
233 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
234 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
235 |
|
|
|
236 |
|
|
|
237 |
|
|
|
238 |
</table>
|
|
|
239 |
|
|
|
240 |
<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Enable 3D header style. This is enabled by default. <br>
|
|
|
241 |
|
|
|
242 |
|
|
|
243 |
// No 3D style for titles
<br />$graph->scale->actinfo->SetStyle(0);</font>
|
|
|
244 |
</span><br>
|
|
|
245 |
|
|
|
246 |
<p> <p> <span style='font-size:110%;'><a name="_GANTTACTIVITYINFO_SHOW"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
|
|
|
247 |
|
|
|
248 |
</b></div></a></span>
|
|
|
249 |
|
|
|
250 |
<span style='font-family:arial;font-size:90%;'><i>Show titles</i></span><p>
|
|
|
251 |
|
|
|
252 |
<table cellspacing=0 style='border:black solid 1pt;' width=100%>
|
|
|
253 |
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
|
|
|
254 |
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
255 |
$aF</font>
|
|
|
256 |
|
|
|
257 |
</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
|
|
|
258 |
|
|
|
259 |
</td><td>TRUE=Show headers</td></tr>
|
|
|
260 |
</table>
|
|
|
261 |
|
|
|
262 |
<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Show titles. If you specify titles they are by default displayed. <br>
|
|
|
263 |
|
|
|
264 |
<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">
|
|
|
265 |
// Hide the titles
<br />$graph->scale->actinfo->Show(false);</font>
|
|
|
266 |
</span><br>
|
|
|
267 |
<p> <hr> <p>
|