|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric6.Plugins.VcsPlugins.vcsMercurial.HisteditExtension.HgHisteditPlanEditor</title> |
|
4 <meta charset="UTF-8"> |
|
5 <style> |
|
6 body { |
|
7 background: #EDECE6; |
|
8 margin: 0em 1em 10em 1em; |
|
9 color: black; |
|
10 } |
|
11 |
|
12 h1 { color: white; background: #85774A; } |
|
13 h2 { color: white; background: #85774A; } |
|
14 h3 { color: white; background: #9D936E; } |
|
15 h4 { color: white; background: #9D936E; } |
|
16 |
|
17 a { color: #BA6D36; } |
|
18 |
|
19 </style> |
|
20 </head> |
|
21 <body><a NAME="top" ID="top"></a> |
|
22 <h1>eric6.Plugins.VcsPlugins.vcsMercurial.HisteditExtension.HgHisteditPlanEditor</h1> |
|
23 <p> |
|
24 Module implementing a dialog to edit the history modification plan. |
|
25 </p> |
|
26 <h3>Global Attributes</h3> |
|
27 <table> |
|
28 <tr><td>None</td></tr> |
|
29 </table> |
|
30 <h3>Classes</h3> |
|
31 <table> |
|
32 <tr> |
|
33 <td><a href="#HgHisteditPlanActionComboBox">HgHisteditPlanActionComboBox</a></td> |
|
34 <td>Class implementing a combo box to select the action in the plan tree.</td> |
|
35 </tr><tr> |
|
36 <td><a href="#HgHisteditPlanEditor">HgHisteditPlanEditor</a></td> |
|
37 <td>Class implementing a dialog to edit the history modification plan.</td> |
|
38 </tr> |
|
39 </table> |
|
40 <h3>Functions</h3> |
|
41 <table> |
|
42 <tr><td>None</td></tr> |
|
43 </table> |
|
44 <hr /><hr /> |
|
45 <a NAME="HgHisteditPlanActionComboBox" ID="HgHisteditPlanActionComboBox"></a> |
|
46 <h2>HgHisteditPlanActionComboBox</h2> |
|
47 <p> |
|
48 Class implementing a combo box to select the action in the plan tree. |
|
49 </p> |
|
50 <h3>Derived from</h3> |
|
51 QComboBox |
|
52 <h3>Class Attributes</h3> |
|
53 <table> |
|
54 <tr><td>None</td></tr> |
|
55 </table> |
|
56 <h3>Class Methods</h3> |
|
57 <table> |
|
58 <tr><td>None</td></tr> |
|
59 </table> |
|
60 <h3>Methods</h3> |
|
61 <table> |
|
62 <tr> |
|
63 <td><a href="#HgHisteditPlanActionComboBox.__init__">HgHisteditPlanActionComboBox</a></td> |
|
64 <td>Constructor</td> |
|
65 </tr><tr> |
|
66 <td><a href="#HgHisteditPlanActionComboBox.__changeItem">__changeItem</a></td> |
|
67 <td>Private slot to handle the selection of a plan action.</td> |
|
68 </tr><tr> |
|
69 <td><a href="#HgHisteditPlanActionComboBox.showPopup">showPopup</a></td> |
|
70 <td>Public method to show the list of items of the combo box.</td> |
|
71 </tr> |
|
72 </table> |
|
73 <h3>Static Methods</h3> |
|
74 <table> |
|
75 <tr><td>None</td></tr> |
|
76 </table> |
|
77 <a NAME="HgHisteditPlanActionComboBox.__init__" ID="HgHisteditPlanActionComboBox.__init__"></a> |
|
78 <h4>HgHisteditPlanActionComboBox (Constructor)</h4> |
|
79 <b>HgHisteditPlanActionComboBox</b>(<i>item, column</i>) |
|
80 <p> |
|
81 Constructor |
|
82 </p><dl> |
|
83 <dt><i>item</i> (QTreeWidgetItem)</dt> |
|
84 <dd> |
|
85 reference to the item |
|
86 </dd><dt><i>column</i> (int)</dt> |
|
87 <dd> |
|
88 column number inside the tree widget item |
|
89 </dd> |
|
90 </dl><a NAME="HgHisteditPlanActionComboBox.__changeItem" ID="HgHisteditPlanActionComboBox.__changeItem"></a> |
|
91 <h4>HgHisteditPlanActionComboBox.__changeItem</h4> |
|
92 <b>__changeItem</b>(<i>index</i>) |
|
93 <p> |
|
94 Private slot to handle the selection of a plan action. |
|
95 </p><p> |
|
96 This method sets the text of the associated item for the specified |
|
97 cell in order to be able to retrieve it with a call of the text() |
|
98 method of the item. |
|
99 </p><dl> |
|
100 <dt><i>index</i> (int)</dt> |
|
101 <dd> |
|
102 index of the selected action |
|
103 </dd> |
|
104 </dl><a NAME="HgHisteditPlanActionComboBox.showPopup" ID="HgHisteditPlanActionComboBox.showPopup"></a> |
|
105 <h4>HgHisteditPlanActionComboBox.showPopup</h4> |
|
106 <b>showPopup</b>(<i></i>) |
|
107 <p> |
|
108 Public method to show the list of items of the combo box. |
|
109 </p><p> |
|
110 This is reimplemented in order to set the associated item as the |
|
111 current item of the tree widget. |
|
112 </p> |
|
113 <div align="right"><a href="#top">Up</a></div> |
|
114 <hr /><hr /> |
|
115 <a NAME="HgHisteditPlanEditor" ID="HgHisteditPlanEditor"></a> |
|
116 <h2>HgHisteditPlanEditor</h2> |
|
117 <p> |
|
118 Class implementing a dialog to edit the history modification plan. |
|
119 </p> |
|
120 <h3>Derived from</h3> |
|
121 QDialog, Ui_HgHisteditPlanEditor |
|
122 <h3>Class Attributes</h3> |
|
123 <table> |
|
124 <tr><td>None</td></tr> |
|
125 </table> |
|
126 <h3>Class Methods</h3> |
|
127 <table> |
|
128 <tr><td>None</td></tr> |
|
129 </table> |
|
130 <h3>Methods</h3> |
|
131 <table> |
|
132 <tr> |
|
133 <td><a href="#HgHisteditPlanEditor.__init__">HgHisteditPlanEditor</a></td> |
|
134 <td>Constructor</td> |
|
135 </tr><tr> |
|
136 <td><a href="#HgHisteditPlanEditor.__addActionCombo">__addActionCombo</a></td> |
|
137 <td>Private method to add an edit action combo to an item.</td> |
|
138 </tr><tr> |
|
139 <td><a href="#HgHisteditPlanEditor.__assembleEditPlan">__assembleEditPlan</a></td> |
|
140 <td>Private method to assemble the edit plan into text suitable for the histedit file.</td> |
|
141 </tr><tr> |
|
142 <td><a href="#HgHisteditPlanEditor.__createPlanItem">__createPlanItem</a></td> |
|
143 <td>Private method to create an edit plan tree item.</td> |
|
144 </tr><tr> |
|
145 <td><a href="#HgHisteditPlanEditor.__readFile">__readFile</a></td> |
|
146 <td>Private method to read the file containing the edit plan and populate the dialog.</td> |
|
147 </tr><tr> |
|
148 <td><a href="#HgHisteditPlanEditor.__resizeSections">__resizeSections</a></td> |
|
149 <td>Private method to resize the tree widget sections.</td> |
|
150 </tr><tr> |
|
151 <td><a href="#HgHisteditPlanEditor.__updateButtons">__updateButtons</a></td> |
|
152 <td>Private method to set the enabled state of the up and down buttons.</td> |
|
153 </tr><tr> |
|
154 <td><a href="#HgHisteditPlanEditor.on_buttonBox_accepted">on_buttonBox_accepted</a></td> |
|
155 <td>Private slot called by the buttonBox accepted signal.</td> |
|
156 </tr><tr> |
|
157 <td><a href="#HgHisteditPlanEditor.on_buttonBox_rejected">on_buttonBox_rejected</a></td> |
|
158 <td>Private slot called by the buttonBox rejected signal.</td> |
|
159 </tr><tr> |
|
160 <td><a href="#HgHisteditPlanEditor.on_downButton_clicked">on_downButton_clicked</a></td> |
|
161 <td>Private slot to move the current entry down one line.</td> |
|
162 </tr><tr> |
|
163 <td><a href="#HgHisteditPlanEditor.on_planTreeWidget_currentItemChanged">on_planTreeWidget_currentItemChanged</a></td> |
|
164 <td>Private slot handling the change of the current edit plan item.</td> |
|
165 </tr><tr> |
|
166 <td><a href="#HgHisteditPlanEditor.on_upButton_clicked">on_upButton_clicked</a></td> |
|
167 <td>Private slot to move the current entry up one line.</td> |
|
168 </tr> |
|
169 </table> |
|
170 <h3>Static Methods</h3> |
|
171 <table> |
|
172 <tr><td>None</td></tr> |
|
173 </table> |
|
174 <a NAME="HgHisteditPlanEditor.__init__" ID="HgHisteditPlanEditor.__init__"></a> |
|
175 <h4>HgHisteditPlanEditor (Constructor)</h4> |
|
176 <b>HgHisteditPlanEditor</b>(<i>fileName, parent=None</i>) |
|
177 <p> |
|
178 Constructor |
|
179 </p><dl> |
|
180 <dt><i>fileName</i> (str)</dt> |
|
181 <dd> |
|
182 name of the file containing the history edit plan |
|
183 to be edited |
|
184 </dd><dt><i>parent</i> (QWidget)</dt> |
|
185 <dd> |
|
186 reference to the parent widget |
|
187 </dd> |
|
188 </dl><a NAME="HgHisteditPlanEditor.__addActionCombo" ID="HgHisteditPlanEditor.__addActionCombo"></a> |
|
189 <h4>HgHisteditPlanEditor.__addActionCombo</h4> |
|
190 <b>__addActionCombo</b>(<i>item</i>) |
|
191 <p> |
|
192 Private method to add an edit action combo to an item. |
|
193 </p><dl> |
|
194 <dt><i>item</i> (QTreeWidgetItem)</dt> |
|
195 <dd> |
|
196 reference to the tree widget item |
|
197 </dd> |
|
198 </dl><a NAME="HgHisteditPlanEditor.__assembleEditPlan" ID="HgHisteditPlanEditor.__assembleEditPlan"></a> |
|
199 <h4>HgHisteditPlanEditor.__assembleEditPlan</h4> |
|
200 <b>__assembleEditPlan</b>(<i></i>) |
|
201 <p> |
|
202 Private method to assemble the edit plan into text suitable for the |
|
203 histedit file. |
|
204 </p><dl> |
|
205 <dt>Returns:</dt> |
|
206 <dd> |
|
207 assembled edit plan text |
|
208 </dd> |
|
209 </dl><dl> |
|
210 <dt>Return Type:</dt> |
|
211 <dd> |
|
212 str |
|
213 </dd> |
|
214 </dl><a NAME="HgHisteditPlanEditor.__createPlanItem" ID="HgHisteditPlanEditor.__createPlanItem"></a> |
|
215 <h4>HgHisteditPlanEditor.__createPlanItem</h4> |
|
216 <b>__createPlanItem</b>(<i>text</i>) |
|
217 <p> |
|
218 Private method to create an edit plan tree item. |
|
219 </p><a NAME="HgHisteditPlanEditor.__readFile" ID="HgHisteditPlanEditor.__readFile"></a> |
|
220 <h4>HgHisteditPlanEditor.__readFile</h4> |
|
221 <b>__readFile</b>(<i></i>) |
|
222 <p> |
|
223 Private method to read the file containing the edit plan and |
|
224 populate the dialog. |
|
225 </p><a NAME="HgHisteditPlanEditor.__resizeSections" ID="HgHisteditPlanEditor.__resizeSections"></a> |
|
226 <h4>HgHisteditPlanEditor.__resizeSections</h4> |
|
227 <b>__resizeSections</b>(<i></i>) |
|
228 <p> |
|
229 Private method to resize the tree widget sections. |
|
230 </p><a NAME="HgHisteditPlanEditor.__updateButtons" ID="HgHisteditPlanEditor.__updateButtons"></a> |
|
231 <h4>HgHisteditPlanEditor.__updateButtons</h4> |
|
232 <b>__updateButtons</b>(<i></i>) |
|
233 <p> |
|
234 Private method to set the enabled state of the up and down buttons. |
|
235 </p><a NAME="HgHisteditPlanEditor.on_buttonBox_accepted" ID="HgHisteditPlanEditor.on_buttonBox_accepted"></a> |
|
236 <h4>HgHisteditPlanEditor.on_buttonBox_accepted</h4> |
|
237 <b>on_buttonBox_accepted</b>(<i></i>) |
|
238 <p> |
|
239 Private slot called by the buttonBox accepted signal. |
|
240 </p><a NAME="HgHisteditPlanEditor.on_buttonBox_rejected" ID="HgHisteditPlanEditor.on_buttonBox_rejected"></a> |
|
241 <h4>HgHisteditPlanEditor.on_buttonBox_rejected</h4> |
|
242 <b>on_buttonBox_rejected</b>(<i></i>) |
|
243 <p> |
|
244 Private slot called by the buttonBox rejected signal. |
|
245 </p><a NAME="HgHisteditPlanEditor.on_downButton_clicked" ID="HgHisteditPlanEditor.on_downButton_clicked"></a> |
|
246 <h4>HgHisteditPlanEditor.on_downButton_clicked</h4> |
|
247 <b>on_downButton_clicked</b>(<i></i>) |
|
248 <p> |
|
249 Private slot to move the current entry down one line. |
|
250 </p><a NAME="HgHisteditPlanEditor.on_planTreeWidget_currentItemChanged" ID="HgHisteditPlanEditor.on_planTreeWidget_currentItemChanged"></a> |
|
251 <h4>HgHisteditPlanEditor.on_planTreeWidget_currentItemChanged</h4> |
|
252 <b>on_planTreeWidget_currentItemChanged</b>(<i>current, previous</i>) |
|
253 <p> |
|
254 Private slot handling the change of the current edit plan item. |
|
255 </p><dl> |
|
256 <dt><i>current</i> (QTreeWidgetItem)</dt> |
|
257 <dd> |
|
258 reference to the current edit plan item |
|
259 </dd><dt><i>previous</i> (QTreeWidgetItem)</dt> |
|
260 <dd> |
|
261 reference to the previous current edit plan item |
|
262 </dd> |
|
263 </dl><a NAME="HgHisteditPlanEditor.on_upButton_clicked" ID="HgHisteditPlanEditor.on_upButton_clicked"></a> |
|
264 <h4>HgHisteditPlanEditor.on_upButton_clicked</h4> |
|
265 <b>on_upButton_clicked</b>(<i></i>) |
|
266 <p> |
|
267 Private slot to move the current entry up one line. |
|
268 </p> |
|
269 <div align="right"><a href="#top">Up</a></div> |
|
270 <hr /> |
|
271 </body></html> |