|
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.SqlBrowser.SqlConnectionWidget</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.SqlBrowser.SqlConnectionWidget</h1> |
|
24 <p> |
|
25 Module implementing a widget showing the SQL connections. |
|
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="#SqlConnectionWidget">SqlConnectionWidget</a></td> |
|
35 <td>Class implementing a widget showing the SQL connections.</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="SqlConnectionWidget" ID="SqlConnectionWidget"></a> |
|
44 <h2>SqlConnectionWidget</h2> |
|
45 <p> |
|
46 Class implementing a widget showing the SQL connections. |
|
47 </p><h4>Signals</h4> |
|
48 <dl> |
|
49 <dt>cleared()</dt> |
|
50 <dd> |
|
51 emitted after the connection tree has been cleared |
|
52 </dd><dt>schemaRequested(QString)</dt> |
|
53 <dd> |
|
54 emitted when the schema display is requested |
|
55 </dd><dt>tableActivated(QString)</dt> |
|
56 <dd> |
|
57 emitted after the entry for a table has been activated |
|
58 </dd> |
|
59 </dl> |
|
60 <h3>Derived from</h3> |
|
61 QWidget |
|
62 <h3>Class Attributes</h3> |
|
63 <table> |
|
64 <tr><td>None</td></tr> |
|
65 </table> |
|
66 <h3>Methods</h3> |
|
67 <table> |
|
68 <tr> |
|
69 <td><a href="#SqlConnectionWidget.__init__">SqlConnectionWidget</a></td> |
|
70 <td>Constructor</td> |
|
71 </tr><tr> |
|
72 <td><a href="#SqlConnectionWidget.__currentItemChanged">__currentItemChanged</a></td> |
|
73 <td>Private slot handling a change of the current item.</td> |
|
74 </tr><tr> |
|
75 <td><a href="#SqlConnectionWidget.__dbCaption">__dbCaption</a></td> |
|
76 <td>Private method to assemble a string for the caption.</td> |
|
77 </tr><tr> |
|
78 <td><a href="#SqlConnectionWidget.__itemActivated">__itemActivated</a></td> |
|
79 <td>Private slot handling the activation of an item.</td> |
|
80 </tr><tr> |
|
81 <td><a href="#SqlConnectionWidget.__setActive">__setActive</a></td> |
|
82 <td>Private slot to set an item to active.</td> |
|
83 </tr><tr> |
|
84 <td><a href="#SqlConnectionWidget.__setBold">__setBold</a></td> |
|
85 <td>Private slot to set the font to bold.</td> |
|
86 </tr><tr> |
|
87 <td><a href="#SqlConnectionWidget.currentDatabase">currentDatabase</a></td> |
|
88 <td>Public method to get the current database.</td> |
|
89 </tr><tr> |
|
90 <td><a href="#SqlConnectionWidget.refresh">refresh</a></td> |
|
91 <td>Public slot to refresh the connection tree.</td> |
|
92 </tr><tr> |
|
93 <td><a href="#SqlConnectionWidget.showSchema">showSchema</a></td> |
|
94 <td>Public slot to show schema data of a database.</td> |
|
95 </tr> |
|
96 </table> |
|
97 <a NAME="SqlConnectionWidget.__init__" ID="SqlConnectionWidget.__init__"></a> |
|
98 <h4>SqlConnectionWidget (Constructor)</h4> |
|
99 <b>SqlConnectionWidget</b>(<i>parent = None</i>) |
|
100 <p> |
|
101 Constructor |
|
102 </p><dl> |
|
103 <dt><i>parent</i></dt> |
|
104 <dd> |
|
105 reference to the parent widget (QWidget) |
|
106 </dd> |
|
107 </dl><a NAME="SqlConnectionWidget.__currentItemChanged" ID="SqlConnectionWidget.__currentItemChanged"></a> |
|
108 <h4>SqlConnectionWidget.__currentItemChanged</h4> |
|
109 <b>__currentItemChanged</b>(<i>current, previous</i>) |
|
110 <p> |
|
111 Private slot handling a change of the current item. |
|
112 </p><dl> |
|
113 <dt><i>current</i></dt> |
|
114 <dd> |
|
115 reference to the new current item (QTreeWidgetItem) |
|
116 </dd><dt><i>previous</i></dt> |
|
117 <dd> |
|
118 reference to the previous current item (QTreeWidgetItem) |
|
119 </dd> |
|
120 </dl><a NAME="SqlConnectionWidget.__dbCaption" ID="SqlConnectionWidget.__dbCaption"></a> |
|
121 <h4>SqlConnectionWidget.__dbCaption</h4> |
|
122 <b>__dbCaption</b>(<i>db</i>) |
|
123 <p> |
|
124 Private method to assemble a string for the caption. |
|
125 </p><dl> |
|
126 <dt><i>db</i></dt> |
|
127 <dd> |
|
128 reference to the database object (QSqlDatabase) |
|
129 </dd> |
|
130 </dl><dl> |
|
131 <dt>Returns:</dt> |
|
132 <dd> |
|
133 caption string (string) |
|
134 </dd> |
|
135 </dl><a NAME="SqlConnectionWidget.__itemActivated" ID="SqlConnectionWidget.__itemActivated"></a> |
|
136 <h4>SqlConnectionWidget.__itemActivated</h4> |
|
137 <b>__itemActivated</b>(<i>itm, column</i>) |
|
138 <p> |
|
139 Private slot handling the activation of an item. |
|
140 </p><dl> |
|
141 <dt><i>itm</i></dt> |
|
142 <dd> |
|
143 reference to the item (QTreeWidgetItem) |
|
144 </dd><dt><i>column</i></dt> |
|
145 <dd> |
|
146 column that was activated (integer) |
|
147 </dd> |
|
148 </dl><a NAME="SqlConnectionWidget.__setActive" ID="SqlConnectionWidget.__setActive"></a> |
|
149 <h4>SqlConnectionWidget.__setActive</h4> |
|
150 <b>__setActive</b>(<i>itm</i>) |
|
151 <p> |
|
152 Private slot to set an item to active. |
|
153 </p><dl> |
|
154 <dt><i>itm</i></dt> |
|
155 <dd> |
|
156 reference to the item to set as the active item (QTreeWidgetItem) |
|
157 </dd> |
|
158 </dl><a NAME="SqlConnectionWidget.__setBold" ID="SqlConnectionWidget.__setBold"></a> |
|
159 <h4>SqlConnectionWidget.__setBold</h4> |
|
160 <b>__setBold</b>(<i>itm, bold</i>) |
|
161 <p> |
|
162 Private slot to set the font to bold. |
|
163 </p><dl> |
|
164 <dt><i>itm</i></dt> |
|
165 <dd> |
|
166 reference to the item to be changed (QTreeWidgetItem) |
|
167 </dd><dt><i>bold</i></dt> |
|
168 <dd> |
|
169 flag indicating bold (boolean) |
|
170 </dd> |
|
171 </dl><a NAME="SqlConnectionWidget.currentDatabase" ID="SqlConnectionWidget.currentDatabase"></a> |
|
172 <h4>SqlConnectionWidget.currentDatabase</h4> |
|
173 <b>currentDatabase</b>(<i></i>) |
|
174 <p> |
|
175 Public method to get the current database. |
|
176 </p><dl> |
|
177 <dt>Returns:</dt> |
|
178 <dd> |
|
179 reference to the current database (QSqlDatabase) |
|
180 </dd> |
|
181 </dl><a NAME="SqlConnectionWidget.refresh" ID="SqlConnectionWidget.refresh"></a> |
|
182 <h4>SqlConnectionWidget.refresh</h4> |
|
183 <b>refresh</b>(<i></i>) |
|
184 <p> |
|
185 Public slot to refresh the connection tree. |
|
186 </p><a NAME="SqlConnectionWidget.showSchema" ID="SqlConnectionWidget.showSchema"></a> |
|
187 <h4>SqlConnectionWidget.showSchema</h4> |
|
188 <b>showSchema</b>(<i></i>) |
|
189 <p> |
|
190 Public slot to show schema data of a database. |
|
191 </p> |
|
192 <div align="right"><a href="#top">Up</a></div> |
|
193 <hr /> |
|
194 </body></html> |