5 <link rel="stylesheet" href="styles.css"> |
5 <link rel="stylesheet" href="styles.css"> |
6 </head> |
6 </head> |
7 <body> |
7 <body> |
8 <a NAME="top" ID="top"></a> |
8 <a NAME="top" ID="top"></a> |
9 <h1>Plugin_Time_Tracker.TimeTracker.TimeTrackerWidget</h1> |
9 <h1>Plugin_Time_Tracker.TimeTracker.TimeTrackerWidget</h1> |
10 |
|
11 <p> |
10 <p> |
12 Module implementing the time tracker widget. |
11 Module implementing the time tracker widget. |
13 </p> |
12 </p> |
|
13 |
14 <h3>Global Attributes</h3> |
14 <h3>Global Attributes</h3> |
15 |
|
16 <table> |
15 <table> |
17 <tr><td>None</td></tr> |
16 <tr><td>None</td></tr> |
18 </table> |
17 </table> |
|
18 |
19 <h3>Classes</h3> |
19 <h3>Classes</h3> |
20 |
20 <table> |
21 <table> |
|
22 |
|
23 <tr> |
21 <tr> |
24 <td><a href="#TimeTrackerWidget">TimeTrackerWidget</a></td> |
22 <td><a href="#TimeTrackerWidget">TimeTrackerWidget</a></td> |
25 <td>Class implementing the time tracker widget.</td> |
23 <td>Class implementing the time tracker widget.</td> |
26 </tr> |
24 </tr> |
27 </table> |
25 </table> |
|
26 |
28 <h3>Functions</h3> |
27 <h3>Functions</h3> |
29 |
|
30 <table> |
28 <table> |
31 <tr><td>None</td></tr> |
29 <tr><td>None</td></tr> |
32 </table> |
30 </table> |
|
31 |
33 <hr /> |
32 <hr /> |
34 <hr /> |
33 <hr /> |
35 <a NAME="TimeTrackerWidget" ID="TimeTrackerWidget"></a> |
34 <a NAME="TimeTrackerWidget" ID="TimeTrackerWidget"></a> |
36 <h2>TimeTrackerWidget</h2> |
35 <h2>TimeTrackerWidget</h2> |
37 |
|
38 <p> |
36 <p> |
39 Class implementing the time tracker widget. |
37 Class implementing the time tracker widget. |
40 </p> |
38 </p> |
|
39 |
41 <h3>Derived from</h3> |
40 <h3>Derived from</h3> |
42 QWidget, Ui_TimeTrackerWidget |
41 QWidget, Ui_TimeTrackerWidget |
43 <h3>Class Attributes</h3> |
42 <h3>Class Attributes</h3> |
44 |
43 <table> |
45 <table> |
44 <tr><td>CommentColumn</td></tr> |
46 <tr><td>CommentColumn</td></tr><tr><td>DurationColumn</td></tr><tr><td>TaskColumn</td></tr> |
45 <tr><td>DurationColumn</td></tr> |
47 </table> |
46 <tr><td>TaskColumn</td></tr> |
|
47 </table> |
|
48 |
48 <h3>Class Methods</h3> |
49 <h3>Class Methods</h3> |
49 |
|
50 <table> |
50 <table> |
51 <tr><td>None</td></tr> |
51 <tr><td>None</td></tr> |
52 </table> |
52 </table> |
|
53 |
53 <h3>Methods</h3> |
54 <h3>Methods</h3> |
54 |
55 <table> |
55 <table> |
|
56 |
|
57 <tr> |
56 <tr> |
58 <td><a href="#TimeTrackerWidget.__init__">TimeTrackerWidget</a></td> |
57 <td><a href="#TimeTrackerWidget.__init__">TimeTrackerWidget</a></td> |
59 <td>Constructor</td> |
58 <td>Constructor</td> |
60 </tr> |
59 </tr> |
61 <tr> |
60 <tr> |
160 </dd> |
160 </dd> |
161 </dl> |
161 </dl> |
162 <a NAME="TimeTrackerWidget.__addEntry" ID="TimeTrackerWidget.__addEntry"></a> |
162 <a NAME="TimeTrackerWidget.__addEntry" ID="TimeTrackerWidget.__addEntry"></a> |
163 <h4>TimeTrackerWidget.__addEntry</h4> |
163 <h4>TimeTrackerWidget.__addEntry</h4> |
164 <b>__addEntry</b>(<i></i>) |
164 <b>__addEntry</b>(<i></i>) |
165 |
|
166 <p> |
165 <p> |
167 Private slot to manually add an entry. |
166 Private slot to manually add an entry. |
168 </p> |
167 </p> |
|
168 |
169 <a NAME="TimeTrackerWidget.__deleteSelectedEntries" ID="TimeTrackerWidget.__deleteSelectedEntries"></a> |
169 <a NAME="TimeTrackerWidget.__deleteSelectedEntries" ID="TimeTrackerWidget.__deleteSelectedEntries"></a> |
170 <h4>TimeTrackerWidget.__deleteSelectedEntries</h4> |
170 <h4>TimeTrackerWidget.__deleteSelectedEntries</h4> |
171 <b>__deleteSelectedEntries</b>(<i></i>) |
171 <b>__deleteSelectedEntries</b>(<i></i>) |
172 |
|
173 <p> |
172 <p> |
174 Private slot to delete the selected tracker entries. |
173 Private slot to delete the selected tracker entries. |
175 </p> |
174 </p> |
|
175 |
176 <a NAME="TimeTrackerWidget.__editEntry" ID="TimeTrackerWidget.__editEntry"></a> |
176 <a NAME="TimeTrackerWidget.__editEntry" ID="TimeTrackerWidget.__editEntry"></a> |
177 <h4>TimeTrackerWidget.__editEntry</h4> |
177 <h4>TimeTrackerWidget.__editEntry</h4> |
178 <b>__editEntry</b>(<i></i>) |
178 <b>__editEntry</b>(<i></i>) |
179 |
|
180 <p> |
179 <p> |
181 Private slot to edit the selected tracker entry. |
180 Private slot to edit the selected tracker entry. |
182 </p> |
181 </p> |
|
182 |
183 <a NAME="TimeTrackerWidget.__exportEntries" ID="TimeTrackerWidget.__exportEntries"></a> |
183 <a NAME="TimeTrackerWidget.__exportEntries" ID="TimeTrackerWidget.__exportEntries"></a> |
184 <h4>TimeTrackerWidget.__exportEntries</h4> |
184 <h4>TimeTrackerWidget.__exportEntries</h4> |
185 <b>__exportEntries</b>(<i>ids=None</i>) |
185 <b>__exportEntries</b>(<i>ids=None</i>) |
186 |
|
187 <p> |
186 <p> |
188 Private method to export all or selected entries. |
187 Private method to export all or selected entries. |
189 </p> |
188 </p> |
|
189 |
190 <dl> |
190 <dl> |
191 |
191 |
192 <dt><i>ids</i> (list of int)</dt> |
192 <dt><i>ids</i> (list of int)</dt> |
193 <dd> |
193 <dd> |
194 list of IDs to export or all if empty |
194 list of IDs to export or all if empty |
195 </dd> |
195 </dd> |
196 </dl> |
196 </dl> |
197 <a NAME="TimeTrackerWidget.__exportSelectedEntries" ID="TimeTrackerWidget.__exportSelectedEntries"></a> |
197 <a NAME="TimeTrackerWidget.__exportSelectedEntries" ID="TimeTrackerWidget.__exportSelectedEntries"></a> |
198 <h4>TimeTrackerWidget.__exportSelectedEntries</h4> |
198 <h4>TimeTrackerWidget.__exportSelectedEntries</h4> |
199 <b>__exportSelectedEntries</b>(<i></i>) |
199 <b>__exportSelectedEntries</b>(<i></i>) |
200 |
|
201 <p> |
200 <p> |
202 Private slot to export the selected tracker entries. |
201 Private slot to export the selected tracker entries. |
203 </p> |
202 </p> |
|
203 |
204 <a NAME="TimeTrackerWidget.__importEntries" ID="TimeTrackerWidget.__importEntries"></a> |
204 <a NAME="TimeTrackerWidget.__importEntries" ID="TimeTrackerWidget.__importEntries"></a> |
205 <h4>TimeTrackerWidget.__importEntries</h4> |
205 <h4>TimeTrackerWidget.__importEntries</h4> |
206 <b>__importEntries</b>(<i></i>) |
206 <b>__importEntries</b>(<i></i>) |
207 |
|
208 <p> |
207 <p> |
209 Private slot to import tracker entries. |
208 Private slot to import tracker entries. |
210 </p> |
209 </p> |
|
210 |
211 <a NAME="TimeTrackerWidget.__insertEntry" ID="TimeTrackerWidget.__insertEntry"></a> |
211 <a NAME="TimeTrackerWidget.__insertEntry" ID="TimeTrackerWidget.__insertEntry"></a> |
212 <h4>TimeTrackerWidget.__insertEntry</h4> |
212 <h4>TimeTrackerWidget.__insertEntry</h4> |
213 <b>__insertEntry</b>(<i>entry, index=-1</i>) |
213 <b>__insertEntry</b>(<i>entry, index=-1</i>) |
214 |
|
215 <p> |
214 <p> |
216 Private method to insert a tracker entry into the list. |
215 Private method to insert a tracker entry into the list. |
217 </p> |
216 </p> |
|
217 |
218 <dl> |
218 <dl> |
219 |
219 |
220 <dt><i>entry</i> (TimeTrackEntry)</dt> |
220 <dt><i>entry</i> (TimeTrackEntry)</dt> |
221 <dd> |
221 <dd> |
222 reference to the tracker entry |
222 reference to the tracker entry |
227 </dd> |
227 </dd> |
228 </dl> |
228 </dl> |
229 <a NAME="TimeTrackerWidget.__mergeDuplicates" ID="TimeTrackerWidget.__mergeDuplicates"></a> |
229 <a NAME="TimeTrackerWidget.__mergeDuplicates" ID="TimeTrackerWidget.__mergeDuplicates"></a> |
230 <h4>TimeTrackerWidget.__mergeDuplicates</h4> |
230 <h4>TimeTrackerWidget.__mergeDuplicates</h4> |
231 <b>__mergeDuplicates</b>(<i></i>) |
231 <b>__mergeDuplicates</b>(<i></i>) |
232 |
|
233 <p> |
232 <p> |
234 Private slot to merge duplicate entries. |
233 Private slot to merge duplicate entries. |
235 </p> |
234 </p> |
|
235 |
236 <a NAME="TimeTrackerWidget.__removeDuplicates" ID="TimeTrackerWidget.__removeDuplicates"></a> |
236 <a NAME="TimeTrackerWidget.__removeDuplicates" ID="TimeTrackerWidget.__removeDuplicates"></a> |
237 <h4>TimeTrackerWidget.__removeDuplicates</h4> |
237 <h4>TimeTrackerWidget.__removeDuplicates</h4> |
238 <b>__removeDuplicates</b>(<i></i>) |
238 <b>__removeDuplicates</b>(<i></i>) |
239 |
|
240 <p> |
239 <p> |
241 Private slot to remove duplicate entries. |
240 Private slot to remove duplicate entries. |
242 </p> |
241 </p> |
|
242 |
243 <a NAME="TimeTrackerWidget.__resizeColumns" ID="TimeTrackerWidget.__resizeColumns"></a> |
243 <a NAME="TimeTrackerWidget.__resizeColumns" ID="TimeTrackerWidget.__resizeColumns"></a> |
244 <h4>TimeTrackerWidget.__resizeColumns</h4> |
244 <h4>TimeTrackerWidget.__resizeColumns</h4> |
245 <b>__resizeColumns</b>(<i></i>) |
245 <b>__resizeColumns</b>(<i></i>) |
246 |
|
247 <p> |
246 <p> |
248 Private slot to resize the columns of the entries list. |
247 Private slot to resize the columns of the entries list. |
249 </p> |
248 </p> |
|
249 |
250 <a NAME="TimeTrackerWidget.__saveEntries" ID="TimeTrackerWidget.__saveEntries"></a> |
250 <a NAME="TimeTrackerWidget.__saveEntries" ID="TimeTrackerWidget.__saveEntries"></a> |
251 <h4>TimeTrackerWidget.__saveEntries</h4> |
251 <h4>TimeTrackerWidget.__saveEntries</h4> |
252 <b>__saveEntries</b>(<i></i>) |
252 <b>__saveEntries</b>(<i></i>) |
253 |
|
254 <p> |
253 <p> |
255 Private slot to save the tracker entries. |
254 Private slot to save the tracker entries. |
256 </p> |
255 </p> |
|
256 |
257 <a NAME="TimeTrackerWidget.clear" ID="TimeTrackerWidget.clear"></a> |
257 <a NAME="TimeTrackerWidget.clear" ID="TimeTrackerWidget.clear"></a> |
258 <h4>TimeTrackerWidget.clear</h4> |
258 <h4>TimeTrackerWidget.clear</h4> |
259 <b>clear</b>(<i></i>) |
259 <b>clear</b>(<i></i>) |
260 |
|
261 <p> |
260 <p> |
262 Public method to clear all the data. |
261 Public method to clear all the data. |
263 </p> |
262 </p> |
|
263 |
264 <a NAME="TimeTrackerWidget.on_commentCombo_editTextChanged" ID="TimeTrackerWidget.on_commentCombo_editTextChanged"></a> |
264 <a NAME="TimeTrackerWidget.on_commentCombo_editTextChanged" ID="TimeTrackerWidget.on_commentCombo_editTextChanged"></a> |
265 <h4>TimeTrackerWidget.on_commentCombo_editTextChanged</h4> |
265 <h4>TimeTrackerWidget.on_commentCombo_editTextChanged</h4> |
266 <b>on_commentCombo_editTextChanged</b>(<i>txt</i>) |
266 <b>on_commentCombo_editTextChanged</b>(<i>txt</i>) |
267 |
|
268 <p> |
267 <p> |
269 Private slot handling changes of the comment of the current entry. |
268 Private slot handling changes of the comment of the current entry. |
270 </p> |
269 </p> |
|
270 |
271 <dl> |
271 <dl> |
272 |
272 |
273 <dt><i>txt</i> (str)</dt> |
273 <dt><i>txt</i> (str)</dt> |
274 <dd> |
274 <dd> |
275 new comment |
275 new comment |
276 </dd> |
276 </dd> |
277 </dl> |
277 </dl> |
278 <a NAME="TimeTrackerWidget.on_entriesList_customContextMenuRequested" ID="TimeTrackerWidget.on_entriesList_customContextMenuRequested"></a> |
278 <a NAME="TimeTrackerWidget.on_entriesList_customContextMenuRequested" ID="TimeTrackerWidget.on_entriesList_customContextMenuRequested"></a> |
279 <h4>TimeTrackerWidget.on_entriesList_customContextMenuRequested</h4> |
279 <h4>TimeTrackerWidget.on_entriesList_customContextMenuRequested</h4> |
280 <b>on_entriesList_customContextMenuRequested</b>(<i>pos</i>) |
280 <b>on_entriesList_customContextMenuRequested</b>(<i>pos</i>) |
281 |
|
282 <p> |
281 <p> |
283 Private slot to create the context menu and show it. |
282 Private slot to create the context menu and show it. |
284 </p> |
283 </p> |
|
284 |
285 <dl> |
285 <dl> |
286 |
286 |
287 <dt><i>pos</i> (QPoint)</dt> |
287 <dt><i>pos</i> (QPoint)</dt> |
288 <dd> |
288 <dd> |
289 position the menu should be shown at |
289 position the menu should be shown at |
290 </dd> |
290 </dd> |
291 </dl> |
291 </dl> |
292 <a NAME="TimeTrackerWidget.on_newButton_clicked" ID="TimeTrackerWidget.on_newButton_clicked"></a> |
292 <a NAME="TimeTrackerWidget.on_newButton_clicked" ID="TimeTrackerWidget.on_newButton_clicked"></a> |
293 <h4>TimeTrackerWidget.on_newButton_clicked</h4> |
293 <h4>TimeTrackerWidget.on_newButton_clicked</h4> |
294 <b>on_newButton_clicked</b>(<i></i>) |
294 <b>on_newButton_clicked</b>(<i></i>) |
295 |
|
296 <p> |
295 <p> |
297 Private slot to end the current timer and start a new one. |
296 Private slot to end the current timer and start a new one. |
298 </p> |
297 </p> |
|
298 |
299 <a NAME="TimeTrackerWidget.on_pauseButton_toggled" ID="TimeTrackerWidget.on_pauseButton_toggled"></a> |
299 <a NAME="TimeTrackerWidget.on_pauseButton_toggled" ID="TimeTrackerWidget.on_pauseButton_toggled"></a> |
300 <h4>TimeTrackerWidget.on_pauseButton_toggled</h4> |
300 <h4>TimeTrackerWidget.on_pauseButton_toggled</h4> |
301 <b>on_pauseButton_toggled</b>(<i>checked</i>) |
301 <b>on_pauseButton_toggled</b>(<i>checked</i>) |
302 |
|
303 <p> |
302 <p> |
304 Private slot to pause the current timing. |
303 Private slot to pause the current timing. |
305 </p> |
304 </p> |
|
305 |
306 <dl> |
306 <dl> |
307 |
307 |
308 <dt><i>checked</i> (bool)</dt> |
308 <dt><i>checked</i> (bool)</dt> |
309 <dd> |
309 <dd> |
310 flag indicating the checked status of the button |
310 flag indicating the checked status of the button |
311 </dd> |
311 </dd> |
312 </dl> |
312 </dl> |
313 <a NAME="TimeTrackerWidget.on_taskCombo_editTextChanged" ID="TimeTrackerWidget.on_taskCombo_editTextChanged"></a> |
313 <a NAME="TimeTrackerWidget.on_taskCombo_editTextChanged" ID="TimeTrackerWidget.on_taskCombo_editTextChanged"></a> |
314 <h4>TimeTrackerWidget.on_taskCombo_editTextChanged</h4> |
314 <h4>TimeTrackerWidget.on_taskCombo_editTextChanged</h4> |
315 <b>on_taskCombo_editTextChanged</b>(<i>txt</i>) |
315 <b>on_taskCombo_editTextChanged</b>(<i>txt</i>) |
316 |
|
317 <p> |
316 <p> |
318 Private slot handling changes of the task description of the current |
317 Private slot handling changes of the task description of the current |
319 entry. |
318 entry. |
320 </p> |
319 </p> |
|
320 |
321 <dl> |
321 <dl> |
322 |
322 |
323 <dt><i>txt</i> (str)</dt> |
323 <dt><i>txt</i> (str)</dt> |
324 <dd> |
324 <dd> |
325 new task description |
325 new task description |
326 </dd> |
326 </dd> |
327 </dl> |
327 </dl> |
328 <a NAME="TimeTrackerWidget.setCurrentEntry" ID="TimeTrackerWidget.setCurrentEntry"></a> |
328 <a NAME="TimeTrackerWidget.setCurrentEntry" ID="TimeTrackerWidget.setCurrentEntry"></a> |
329 <h4>TimeTrackerWidget.setCurrentEntry</h4> |
329 <h4>TimeTrackerWidget.setCurrentEntry</h4> |
330 <b>setCurrentEntry</b>(<i>entry</i>) |
330 <b>setCurrentEntry</b>(<i>entry</i>) |
331 |
|
332 <p> |
331 <p> |
333 Public method to set the current entry. |
332 Public method to set the current entry. |
334 </p> |
333 </p> |
|
334 |
335 <dl> |
335 <dl> |
336 |
336 |
337 <dt><i>entry</i> (TimeTrackEntry)</dt> |
337 <dt><i>entry</i> (TimeTrackEntry)</dt> |
338 <dd> |
338 <dd> |
339 current entry |
339 current entry |
340 </dd> |
340 </dd> |
341 </dl> |
341 </dl> |
342 <a NAME="TimeTrackerWidget.showTrackerEntries" ID="TimeTrackerWidget.showTrackerEntries"></a> |
342 <a NAME="TimeTrackerWidget.showTrackerEntries" ID="TimeTrackerWidget.showTrackerEntries"></a> |
343 <h4>TimeTrackerWidget.showTrackerEntries</h4> |
343 <h4>TimeTrackerWidget.showTrackerEntries</h4> |
344 <b>showTrackerEntries</b>(<i>entries</i>) |
344 <b>showTrackerEntries</b>(<i>entries</i>) |
345 |
|
346 <p> |
345 <p> |
347 Public method to show the tracker entries of the current project. |
346 Public method to show the tracker entries of the current project. |
348 </p> |
347 </p> |
|
348 |
349 <dl> |
349 <dl> |
350 |
350 |
351 <dt><i>entries</i> (list of TimeTrackEntry)</dt> |
351 <dt><i>entries</i> (list of TimeTrackEntry)</dt> |
352 <dd> |
352 <dd> |
353 list of tracker entries |
353 list of tracker entries |