|
1 <?xml version="1.0" encoding="utf-8"?> |
|
2 <!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' |
|
3 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'> |
|
4 <html><head> |
|
5 <title>eric4.DataViews.CodeMetricsDialog</title> |
|
6 <style> |
|
7 body { |
|
8 background:white; |
|
9 margin: 0em 1em 10em 1em; |
|
10 color: black; |
|
11 } |
|
12 |
|
13 h1 { color: white; background: #4FA4FF; } |
|
14 h2 { color: white; background: #4FA4FF; } |
|
15 h3 { color: white; background: #00557F; } |
|
16 h4 { color: white; background: #00557F; } |
|
17 |
|
18 a { color: #AA5500; } |
|
19 |
|
20 </style> |
|
21 </head> |
|
22 <body><a NAME="top" ID="top"></a> |
|
23 <h1>eric4.DataViews.CodeMetricsDialog</h1> |
|
24 <p> |
|
25 Module implementing a code metrics dialog. |
|
26 </p> |
|
27 <h3>Global Attributes</h3> |
|
28 <table> |
|
29 <tr><td>None</td></tr> |
|
30 </table> |
|
31 <h3>Classes</h3> |
|
32 <table> |
|
33 <tr> |
|
34 <td><a href="#CodeMetricsDialog">CodeMetricsDialog</a></td> |
|
35 <td>Class implementing a dialog to display the code metrics.</td> |
|
36 </tr> |
|
37 </table> |
|
38 <h3>Functions</h3> |
|
39 <table> |
|
40 <tr><td>None</td></tr> |
|
41 </table> |
|
42 <hr /><hr /> |
|
43 <a NAME="CodeMetricsDialog" ID="CodeMetricsDialog"></a> |
|
44 <h2>CodeMetricsDialog</h2> |
|
45 <p> |
|
46 Class implementing a dialog to display the code metrics. |
|
47 </p> |
|
48 <h3>Derived from</h3> |
|
49 QDialog, Ui_CodeMetricsDialog |
|
50 <h3>Class Attributes</h3> |
|
51 <table> |
|
52 <tr><td>None</td></tr> |
|
53 </table> |
|
54 <h3>Methods</h3> |
|
55 <table> |
|
56 <tr> |
|
57 <td><a href="#CodeMetricsDialog.__init__">CodeMetricsDialog</a></td> |
|
58 <td>Constructor</td> |
|
59 </tr><tr> |
|
60 <td><a href="#CodeMetricsDialog.__createResultItem">__createResultItem</a></td> |
|
61 <td>Private slot to create a new item in the result list.</td> |
|
62 </tr><tr> |
|
63 <td><a href="#CodeMetricsDialog.__createSummaryItem">__createSummaryItem</a></td> |
|
64 <td>Private slot to create a new item in the summary list.</td> |
|
65 </tr><tr> |
|
66 <td><a href="#CodeMetricsDialog.__finish">__finish</a></td> |
|
67 <td>Private slot called when the action finished or the user pressed the button.</td> |
|
68 </tr><tr> |
|
69 <td><a href="#CodeMetricsDialog.__getValues">__getValues</a></td> |
|
70 <td>Private method to extract the code metric values.</td> |
|
71 </tr><tr> |
|
72 <td><a href="#CodeMetricsDialog.__resizeResultColumns">__resizeResultColumns</a></td> |
|
73 <td>Private method to resize the list columns.</td> |
|
74 </tr><tr> |
|
75 <td><a href="#CodeMetricsDialog.__resizeSummaryColumns">__resizeSummaryColumns</a></td> |
|
76 <td>Private method to resize the list columns.</td> |
|
77 </tr><tr> |
|
78 <td><a href="#CodeMetricsDialog.__resultCollapse">__resultCollapse</a></td> |
|
79 <td>Private slot to collapse all entries of the resultlist.</td> |
|
80 </tr><tr> |
|
81 <td><a href="#CodeMetricsDialog.__resultExpand">__resultExpand</a></td> |
|
82 <td>Private slot to expand all entries of the resultlist.</td> |
|
83 </tr><tr> |
|
84 <td><a href="#CodeMetricsDialog.__showContextMenu">__showContextMenu</a></td> |
|
85 <td>Private slot to show the context menu of the listview.</td> |
|
86 </tr><tr> |
|
87 <td><a href="#CodeMetricsDialog.on_buttonBox_clicked">on_buttonBox_clicked</a></td> |
|
88 <td>Private slot called by a button of the button box clicked.</td> |
|
89 </tr><tr> |
|
90 <td><a href="#CodeMetricsDialog.start">start</a></td> |
|
91 <td>Public slot to start the code metrics determination.</td> |
|
92 </tr> |
|
93 </table> |
|
94 <a NAME="CodeMetricsDialog.__init__" ID="CodeMetricsDialog.__init__"></a> |
|
95 <h4>CodeMetricsDialog (Constructor)</h4> |
|
96 <b>CodeMetricsDialog</b>(<i>parent = None</i>) |
|
97 <p> |
|
98 Constructor |
|
99 </p><dl> |
|
100 <dt><i>parent</i></dt> |
|
101 <dd> |
|
102 parent widget (QWidget) |
|
103 </dd> |
|
104 </dl><a NAME="CodeMetricsDialog.__createResultItem" ID="CodeMetricsDialog.__createResultItem"></a> |
|
105 <h4>CodeMetricsDialog.__createResultItem</h4> |
|
106 <b>__createResultItem</b>(<i>parent, strings</i>) |
|
107 <p> |
|
108 Private slot to create a new item in the result list. |
|
109 </p><dl> |
|
110 <dt><i>parent</i></dt> |
|
111 <dd> |
|
112 parent of the new item (QTreeWidget or QTreeWidgetItem) |
|
113 </dd><dt><i>strings</i></dt> |
|
114 <dd> |
|
115 strings to be displayed (list of strings) |
|
116 </dd> |
|
117 </dl><dl> |
|
118 <dt>Returns:</dt> |
|
119 <dd> |
|
120 the generated item |
|
121 </dd> |
|
122 </dl><a NAME="CodeMetricsDialog.__createSummaryItem" ID="CodeMetricsDialog.__createSummaryItem"></a> |
|
123 <h4>CodeMetricsDialog.__createSummaryItem</h4> |
|
124 <b>__createSummaryItem</b>(<i>col0, col1</i>) |
|
125 <p> |
|
126 Private slot to create a new item in the summary list. |
|
127 </p><dl> |
|
128 <dt><i>col0</i></dt> |
|
129 <dd> |
|
130 string for column 0 (string) |
|
131 </dd><dt><i>col1</i></dt> |
|
132 <dd> |
|
133 string for column 1 (string) |
|
134 </dd> |
|
135 </dl><a NAME="CodeMetricsDialog.__finish" ID="CodeMetricsDialog.__finish"></a> |
|
136 <h4>CodeMetricsDialog.__finish</h4> |
|
137 <b>__finish</b>(<i></i>) |
|
138 <p> |
|
139 Private slot called when the action finished or the user pressed the button. |
|
140 </p><a NAME="CodeMetricsDialog.__getValues" ID="CodeMetricsDialog.__getValues"></a> |
|
141 <h4>CodeMetricsDialog.__getValues</h4> |
|
142 <b>__getValues</b>(<i>loc, stats, identifier</i>) |
|
143 <p> |
|
144 Private method to extract the code metric values. |
|
145 </p><dl> |
|
146 <dt><i>loc</i></dt> |
|
147 <dd> |
|
148 reference to the locale object (QLocale) |
|
149 </dd><dt><i>stats</i></dt> |
|
150 <dd> |
|
151 reference to the code metric statistics object |
|
152 </dd><dt><i>identifier</i></dt> |
|
153 <dd> |
|
154 identifier to get values for |
|
155 </dd> |
|
156 </dl><dl> |
|
157 <dt>Returns:</dt> |
|
158 <dd> |
|
159 list of values suitable for display (list of strings) |
|
160 </dd> |
|
161 </dl><a NAME="CodeMetricsDialog.__resizeResultColumns" ID="CodeMetricsDialog.__resizeResultColumns"></a> |
|
162 <h4>CodeMetricsDialog.__resizeResultColumns</h4> |
|
163 <b>__resizeResultColumns</b>(<i></i>) |
|
164 <p> |
|
165 Private method to resize the list columns. |
|
166 </p><a NAME="CodeMetricsDialog.__resizeSummaryColumns" ID="CodeMetricsDialog.__resizeSummaryColumns"></a> |
|
167 <h4>CodeMetricsDialog.__resizeSummaryColumns</h4> |
|
168 <b>__resizeSummaryColumns</b>(<i></i>) |
|
169 <p> |
|
170 Private method to resize the list columns. |
|
171 </p><a NAME="CodeMetricsDialog.__resultCollapse" ID="CodeMetricsDialog.__resultCollapse"></a> |
|
172 <h4>CodeMetricsDialog.__resultCollapse</h4> |
|
173 <b>__resultCollapse</b>(<i></i>) |
|
174 <p> |
|
175 Private slot to collapse all entries of the resultlist. |
|
176 </p><a NAME="CodeMetricsDialog.__resultExpand" ID="CodeMetricsDialog.__resultExpand"></a> |
|
177 <h4>CodeMetricsDialog.__resultExpand</h4> |
|
178 <b>__resultExpand</b>(<i></i>) |
|
179 <p> |
|
180 Private slot to expand all entries of the resultlist. |
|
181 </p><a NAME="CodeMetricsDialog.__showContextMenu" ID="CodeMetricsDialog.__showContextMenu"></a> |
|
182 <h4>CodeMetricsDialog.__showContextMenu</h4> |
|
183 <b>__showContextMenu</b>(<i>coord</i>) |
|
184 <p> |
|
185 Private slot to show the context menu of the listview. |
|
186 </p><dl> |
|
187 <dt><i>coord</i></dt> |
|
188 <dd> |
|
189 the position of the mouse pointer (QPoint) |
|
190 </dd> |
|
191 </dl><a NAME="CodeMetricsDialog.on_buttonBox_clicked" ID="CodeMetricsDialog.on_buttonBox_clicked"></a> |
|
192 <h4>CodeMetricsDialog.on_buttonBox_clicked</h4> |
|
193 <b>on_buttonBox_clicked</b>(<i>button</i>) |
|
194 <p> |
|
195 Private slot called by a button of the button box clicked. |
|
196 </p><dl> |
|
197 <dt><i>button</i></dt> |
|
198 <dd> |
|
199 button that was clicked (QAbstractButton) |
|
200 </dd> |
|
201 </dl><a NAME="CodeMetricsDialog.start" ID="CodeMetricsDialog.start"></a> |
|
202 <h4>CodeMetricsDialog.start</h4> |
|
203 <b>start</b>(<i>fn</i>) |
|
204 <p> |
|
205 Public slot to start the code metrics determination. |
|
206 </p><dl> |
|
207 <dt><i>fn</i></dt> |
|
208 <dd> |
|
209 file or list of files or directory to be show |
|
210 the code metrics for (string or list of strings) |
|
211 </dd> |
|
212 </dl> |
|
213 <div align="right"><a href="#top">Up</a></div> |
|
214 <hr /> |
|
215 </body></html> |