eric6/Documentation/Source/eric6.E5Gui.E5MapWidget.html

changeset 7273
391d6b7b1eff
parent 6942
2602857055c5
child 7989
a21d673a8f99
equal deleted inserted replaced
7272:1779dc278077 7273:391d6b7b1eff
16 16
17 a { color: #BA6D36; } 17 a { color: #BA6D36; }
18 18
19 </style> 19 </style>
20 </head> 20 </head>
21 <body><a NAME="top" ID="top"></a> 21 <body>
22 <a NAME="top" ID="top"></a>
22 <h1>eric6.E5Gui.E5MapWidget</h1> 23 <h1>eric6.E5Gui.E5MapWidget</h1>
24
23 <p> 25 <p>
24 Module implementing a base class for showing a document map. 26 Module implementing a base class for showing a document map.
25 </p> 27 </p>
26 <h3>Global Attributes</h3> 28 <h3>Global Attributes</h3>
29
27 <table> 30 <table>
28 <tr><td>None</td></tr> 31 <tr><td>None</td></tr>
29 </table> 32 </table>
30 <h3>Classes</h3> 33 <h3>Classes</h3>
31 <table> 34
35 <table>
36
32 <tr> 37 <tr>
33 <td><a href="#E5MapWidget">E5MapWidget</a></td> 38 <td><a href="#E5MapWidget">E5MapWidget</a></td>
34 <td>Class implementing a base class for showing a document map.</td> 39 <td>Class implementing a base class for showing a document map.</td>
35 </tr> 40 </tr>
36 </table> 41 </table>
37 <h3>Functions</h3> 42 <h3>Functions</h3>
43
38 <table> 44 <table>
39 <tr><td>None</td></tr> 45 <tr><td>None</td></tr>
40 </table> 46 </table>
41 <hr /><hr /> 47 <hr />
48 <hr />
42 <a NAME="E5MapWidget" ID="E5MapWidget"></a> 49 <a NAME="E5MapWidget" ID="E5MapWidget"></a>
43 <h2>E5MapWidget</h2> 50 <h2>E5MapWidget</h2>
51
44 <p> 52 <p>
45 Class implementing a base class for showing a document map. 53 Class implementing a base class for showing a document map.
46 </p> 54 </p>
47 <h3>Derived from</h3> 55 <h3>Derived from</h3>
48 QWidget 56 QWidget
49 <h3>Class Attributes</h3> 57 <h3>Class Attributes</h3>
58
50 <table> 59 <table>
51 <tr><td>None</td></tr> 60 <tr><td>None</td></tr>
52 </table> 61 </table>
53 <h3>Class Methods</h3> 62 <h3>Class Methods</h3>
63
54 <table> 64 <table>
55 <tr><td>None</td></tr> 65 <tr><td>None</td></tr>
56 </table> 66 </table>
57 <h3>Methods</h3> 67 <h3>Methods</h3>
58 <table> 68
69 <table>
70
59 <tr> 71 <tr>
60 <td><a href="#E5MapWidget.__init__">E5MapWidget</a></td> 72 <td><a href="#E5MapWidget.__init__">E5MapWidget</a></td>
61 <td>Constructor</td> 73 <td>Constructor</td>
62 </tr><tr> 74 </tr>
75 <tr>
63 <td><a href="#E5MapWidget.__generateSliderRange">__generateSliderRange</a></td> 76 <td><a href="#E5MapWidget.__generateSliderRange">__generateSliderRange</a></td>
64 <td>Private method to generate the slider rectangle.</td> 77 <td>Private method to generate the slider rectangle.</td>
65 </tr><tr> 78 </tr>
79 <tr>
66 <td><a href="#E5MapWidget.__setSliderColor">__setSliderColor</a></td> 80 <td><a href="#E5MapWidget.__setSliderColor">__setSliderColor</a></td>
67 <td>Private method to set the slider color depending upon the background color.</td> 81 <td>Private method to set the slider color depending upon the background color.</td>
68 </tr><tr> 82 </tr>
83 <tr>
69 <td><a href="#E5MapWidget.__updateMasterViewportWidth">__updateMasterViewportWidth</a></td> 84 <td><a href="#E5MapWidget.__updateMasterViewportWidth">__updateMasterViewportWidth</a></td>
70 <td>Private method to update the master's viewport width.</td> 85 <td>Private method to update the master's viewport width.</td>
71 </tr><tr> 86 </tr>
87 <tr>
72 <td><a href="#E5MapWidget._paintIt">_paintIt</a></td> 88 <td><a href="#E5MapWidget._paintIt">_paintIt</a></td>
73 <td>Protected method for painting the widget's indicators.</td> 89 <td>Protected method for painting the widget's indicators.</td>
74 </tr><tr> 90 </tr>
91 <tr>
75 <td><a href="#E5MapWidget.backgroundColor">backgroundColor</a></td> 92 <td><a href="#E5MapWidget.backgroundColor">backgroundColor</a></td>
76 <td>Public method to get the background color.</td> 93 <td>Public method to get the background color.</td>
77 </tr><tr> 94 </tr>
95 <tr>
78 <td><a href="#E5MapWidget.calculateGeometry">calculateGeometry</a></td> 96 <td><a href="#E5MapWidget.calculateGeometry">calculateGeometry</a></td>
79 <td>Public method to recalculate the map widget's geometry.</td> 97 <td>Public method to recalculate the map widget's geometry.</td>
80 </tr><tr> 98 </tr>
99 <tr>
81 <td><a href="#E5MapWidget.generateIndicatorRect">generateIndicatorRect</a></td> 100 <td><a href="#E5MapWidget.generateIndicatorRect">generateIndicatorRect</a></td>
82 <td>Public method to generate an indicator rectangle.</td> 101 <td>Public method to generate an indicator rectangle.</td>
83 </tr><tr> 102 </tr>
103 <tr>
84 <td><a href="#E5MapWidget.isEnabled">isEnabled</a></td> 104 <td><a href="#E5MapWidget.isEnabled">isEnabled</a></td>
85 <td>Public method to check the enabled state.</td> 105 <td>Public method to check the enabled state.</td>
86 </tr><tr> 106 </tr>
107 <tr>
87 <td><a href="#E5MapWidget.isOnRightSide">isOnRightSide</a></td> 108 <td><a href="#E5MapWidget.isOnRightSide">isOnRightSide</a></td>
88 <td>Public method to test, if the map is shown on the right side of the master widget.</td> 109 <td>Public method to test, if the map is shown on the right side of the master widget.</td>
89 </tr><tr> 110 </tr>
111 <tr>
90 <td><a href="#E5MapWidget.lineDimensions">lineDimensions</a></td> 112 <td><a href="#E5MapWidget.lineDimensions">lineDimensions</a></td>
91 <td>Public method to get the line (indicator) dimensions.</td> 113 <td>Public method to get the line (indicator) dimensions.</td>
92 </tr><tr> 114 </tr>
115 <tr>
93 <td><a href="#E5MapWidget.mouseMoveEvent">mouseMoveEvent</a></td> 116 <td><a href="#E5MapWidget.mouseMoveEvent">mouseMoveEvent</a></td>
94 <td>Protected method to handle a mouse moves.</td> 117 <td>Protected method to handle a mouse moves.</td>
95 </tr><tr> 118 </tr>
119 <tr>
96 <td><a href="#E5MapWidget.mousePressEvent">mousePressEvent</a></td> 120 <td><a href="#E5MapWidget.mousePressEvent">mousePressEvent</a></td>
97 <td>Protected method to handle a mouse button press.</td> 121 <td>Protected method to handle a mouse button press.</td>
98 </tr><tr> 122 </tr>
123 <tr>
99 <td><a href="#E5MapWidget.paintEvent">paintEvent</a></td> 124 <td><a href="#E5MapWidget.paintEvent">paintEvent</a></td>
100 <td>Protected method to handle a paint event.</td> 125 <td>Protected method to handle a paint event.</td>
101 </tr><tr> 126 </tr>
127 <tr>
102 <td><a href="#E5MapWidget.position2Value">position2Value</a></td> 128 <td><a href="#E5MapWidget.position2Value">position2Value</a></td>
103 <td>Public method to convert a position into a scrollbar value.</td> 129 <td>Public method to convert a position into a scrollbar value.</td>
104 </tr><tr> 130 </tr>
131 <tr>
105 <td><a href="#E5MapWidget.scaleFactor">scaleFactor</a></td> 132 <td><a href="#E5MapWidget.scaleFactor">scaleFactor</a></td>
106 <td>Public method to determine the scrollbar's scale factor.</td> 133 <td>Public method to determine the scrollbar's scale factor.</td>
107 </tr><tr> 134 </tr>
135 <tr>
108 <td><a href="#E5MapWidget.setBackgroundColor">setBackgroundColor</a></td> 136 <td><a href="#E5MapWidget.setBackgroundColor">setBackgroundColor</a></td>
109 <td>Public method to set the widget background color.</td> 137 <td>Public method to set the widget background color.</td>
110 </tr><tr> 138 </tr>
139 <tr>
111 <td><a href="#E5MapWidget.setEnabled">setEnabled</a></td> 140 <td><a href="#E5MapWidget.setEnabled">setEnabled</a></td>
112 <td>Public method to set the enabled state.</td> 141 <td>Public method to set the enabled state.</td>
113 </tr><tr> 142 </tr>
143 <tr>
114 <td><a href="#E5MapWidget.setLineDimensions">setLineDimensions</a></td> 144 <td><a href="#E5MapWidget.setLineDimensions">setLineDimensions</a></td>
115 <td>Public method to set the line (indicator) dimensions.</td> 145 <td>Public method to set the line (indicator) dimensions.</td>
116 </tr><tr> 146 </tr>
147 <tr>
117 <td><a href="#E5MapWidget.setMapPosition">setMapPosition</a></td> 148 <td><a href="#E5MapWidget.setMapPosition">setMapPosition</a></td>
118 <td>Public method to set, whether the map should be shown to the right or left of the master widget.</td> 149 <td>Public method to set, whether the map should be shown to the right or left of the master widget.</td>
119 </tr><tr> 150 </tr>
151 <tr>
120 <td><a href="#E5MapWidget.setMaster">setMaster</a></td> 152 <td><a href="#E5MapWidget.setMaster">setMaster</a></td>
121 <td>Public method to set the map master widget.</td> 153 <td>Public method to set the map master widget.</td>
122 </tr><tr> 154 </tr>
155 <tr>
123 <td><a href="#E5MapWidget.setWidth">setWidth</a></td> 156 <td><a href="#E5MapWidget.setWidth">setWidth</a></td>
124 <td>Public method to set the widget width.</td> 157 <td>Public method to set the widget width.</td>
125 </tr><tr> 158 </tr>
159 <tr>
126 <td><a href="#E5MapWidget.sizeHint">sizeHint</a></td> 160 <td><a href="#E5MapWidget.sizeHint">sizeHint</a></td>
127 <td>Public method to give an indication about the preferred size.</td> 161 <td>Public method to give an indication about the preferred size.</td>
128 </tr><tr> 162 </tr>
163 <tr>
129 <td><a href="#E5MapWidget.value2Position">value2Position</a></td> 164 <td><a href="#E5MapWidget.value2Position">value2Position</a></td>
130 <td>Public method to convert a scrollbar value into a position.</td> 165 <td>Public method to convert a scrollbar value into a position.</td>
131 </tr><tr> 166 </tr>
167 <tr>
132 <td><a href="#E5MapWidget.wheelEvent">wheelEvent</a></td> 168 <td><a href="#E5MapWidget.wheelEvent">wheelEvent</a></td>
133 <td>Protected slot handling mouse wheel events.</td> 169 <td>Protected slot handling mouse wheel events.</td>
134 </tr><tr> 170 </tr>
171 <tr>
135 <td><a href="#E5MapWidget.width">width</a></td> 172 <td><a href="#E5MapWidget.width">width</a></td>
136 <td>Public method to get the widget's width.</td> 173 <td>Public method to get the widget's width.</td>
137 </tr> 174 </tr>
138 </table> 175 </table>
139 <h3>Static Methods</h3> 176 <h3>Static Methods</h3>
177
140 <table> 178 <table>
141 <tr><td>None</td></tr> 179 <tr><td>None</td></tr>
142 </table> 180 </table>
181
143 <a NAME="E5MapWidget.__init__" ID="E5MapWidget.__init__"></a> 182 <a NAME="E5MapWidget.__init__" ID="E5MapWidget.__init__"></a>
144 <h4>E5MapWidget (Constructor)</h4> 183 <h4>E5MapWidget (Constructor)</h4>
145 <b>E5MapWidget</b>(<i>parent=None</i>) 184 <b>E5MapWidget</b>(<i>parent=None</i>)
185
146 <p> 186 <p>
147 Constructor 187 Constructor
148 </p><dl> 188 </p>
189 <dl>
190
149 <dt><i>parent</i></dt> 191 <dt><i>parent</i></dt>
150 <dd> 192 <dd>
151 reference to the parent widget (QWidget) 193 reference to the parent widget (QWidget)
152 </dd> 194 </dd>
153 </dl><a NAME="E5MapWidget.__generateSliderRange" ID="E5MapWidget.__generateSliderRange"></a> 195 </dl>
196 <a NAME="E5MapWidget.__generateSliderRange" ID="E5MapWidget.__generateSliderRange"></a>
154 <h4>E5MapWidget.__generateSliderRange</h4> 197 <h4>E5MapWidget.__generateSliderRange</h4>
155 <b>__generateSliderRange</b>(<i>scrollbar</i>) 198 <b>__generateSliderRange</b>(<i>scrollbar</i>)
199
156 <p> 200 <p>
157 Private method to generate the slider rectangle. 201 Private method to generate the slider rectangle.
158 </p><dl> 202 </p>
203 <dl>
204
159 <dt><i>scrollbar</i></dt> 205 <dt><i>scrollbar</i></dt>
160 <dd> 206 <dd>
161 reference to the vertical scrollbar (QScrollBar) 207 reference to the vertical scrollbar (QScrollBar)
162 </dd> 208 </dd>
163 </dl><dl> 209 </dl>
210 <dl>
164 <dt>Returns:</dt> 211 <dt>Returns:</dt>
165 <dd> 212 <dd>
166 slider rectangle (QRect) 213 slider rectangle (QRect)
167 </dd> 214 </dd>
168 </dl><a NAME="E5MapWidget.__setSliderColor" ID="E5MapWidget.__setSliderColor"></a> 215 </dl>
216 <a NAME="E5MapWidget.__setSliderColor" ID="E5MapWidget.__setSliderColor"></a>
169 <h4>E5MapWidget.__setSliderColor</h4> 217 <h4>E5MapWidget.__setSliderColor</h4>
170 <b>__setSliderColor</b>(<i></i>) 218 <b>__setSliderColor</b>(<i></i>)
219
171 <p> 220 <p>
172 Private method to set the slider color depending upon the background 221 Private method to set the slider color depending upon the background
173 color. 222 color.
174 </p><a NAME="E5MapWidget.__updateMasterViewportWidth" ID="E5MapWidget.__updateMasterViewportWidth"></a> 223 </p>
224 <a NAME="E5MapWidget.__updateMasterViewportWidth" ID="E5MapWidget.__updateMasterViewportWidth"></a>
175 <h4>E5MapWidget.__updateMasterViewportWidth</h4> 225 <h4>E5MapWidget.__updateMasterViewportWidth</h4>
176 <b>__updateMasterViewportWidth</b>(<i></i>) 226 <b>__updateMasterViewportWidth</b>(<i></i>)
227
177 <p> 228 <p>
178 Private method to update the master's viewport width. 229 Private method to update the master's viewport width.
179 </p><a NAME="E5MapWidget._paintIt" ID="E5MapWidget._paintIt"></a> 230 </p>
231 <a NAME="E5MapWidget._paintIt" ID="E5MapWidget._paintIt"></a>
180 <h4>E5MapWidget._paintIt</h4> 232 <h4>E5MapWidget._paintIt</h4>
181 <b>_paintIt</b>(<i>painter</i>) 233 <b>_paintIt</b>(<i>painter</i>)
234
182 <p> 235 <p>
183 Protected method for painting the widget's indicators. 236 Protected method for painting the widget's indicators.
184 </p><p> 237 </p>
238 <p>
185 Note: This method should be implemented by subclasses. 239 Note: This method should be implemented by subclasses.
186 </p><dl> 240 </p>
241 <dl>
242
187 <dt><i>painter</i></dt> 243 <dt><i>painter</i></dt>
188 <dd> 244 <dd>
189 reference to the painter object (QPainter) 245 reference to the painter object (QPainter)
190 </dd> 246 </dd>
191 </dl><a NAME="E5MapWidget.backgroundColor" ID="E5MapWidget.backgroundColor"></a> 247 </dl>
248 <a NAME="E5MapWidget.backgroundColor" ID="E5MapWidget.backgroundColor"></a>
192 <h4>E5MapWidget.backgroundColor</h4> 249 <h4>E5MapWidget.backgroundColor</h4>
193 <b>backgroundColor</b>(<i></i>) 250 <b>backgroundColor</b>(<i></i>)
251
194 <p> 252 <p>
195 Public method to get the background color. 253 Public method to get the background color.
196 </p><dl> 254 </p>
255 <dl>
197 <dt>Returns:</dt> 256 <dt>Returns:</dt>
198 <dd> 257 <dd>
199 background color (QColor) 258 background color (QColor)
200 </dd> 259 </dd>
201 </dl><a NAME="E5MapWidget.calculateGeometry" ID="E5MapWidget.calculateGeometry"></a> 260 </dl>
261 <a NAME="E5MapWidget.calculateGeometry" ID="E5MapWidget.calculateGeometry"></a>
202 <h4>E5MapWidget.calculateGeometry</h4> 262 <h4>E5MapWidget.calculateGeometry</h4>
203 <b>calculateGeometry</b>(<i></i>) 263 <b>calculateGeometry</b>(<i></i>)
264
204 <p> 265 <p>
205 Public method to recalculate the map widget's geometry. 266 Public method to recalculate the map widget's geometry.
206 </p><a NAME="E5MapWidget.generateIndicatorRect" ID="E5MapWidget.generateIndicatorRect"></a> 267 </p>
268 <a NAME="E5MapWidget.generateIndicatorRect" ID="E5MapWidget.generateIndicatorRect"></a>
207 <h4>E5MapWidget.generateIndicatorRect</h4> 269 <h4>E5MapWidget.generateIndicatorRect</h4>
208 <b>generateIndicatorRect</b>(<i>position</i>) 270 <b>generateIndicatorRect</b>(<i>position</i>)
271
209 <p> 272 <p>
210 Public method to generate an indicator rectangle. 273 Public method to generate an indicator rectangle.
211 </p><dl> 274 </p>
275 <dl>
276
212 <dt><i>position</i></dt> 277 <dt><i>position</i></dt>
213 <dd> 278 <dd>
214 indicator position (integer) 279 indicator position (integer)
215 </dd> 280 </dd>
216 </dl><dl> 281 </dl>
282 <dl>
217 <dt>Returns:</dt> 283 <dt>Returns:</dt>
218 <dd> 284 <dd>
219 indicator rectangle (QRect) 285 indicator rectangle (QRect)
220 </dd> 286 </dd>
221 </dl><a NAME="E5MapWidget.isEnabled" ID="E5MapWidget.isEnabled"></a> 287 </dl>
288 <a NAME="E5MapWidget.isEnabled" ID="E5MapWidget.isEnabled"></a>
222 <h4>E5MapWidget.isEnabled</h4> 289 <h4>E5MapWidget.isEnabled</h4>
223 <b>isEnabled</b>(<i></i>) 290 <b>isEnabled</b>(<i></i>)
291
224 <p> 292 <p>
225 Public method to check the enabled state. 293 Public method to check the enabled state.
226 </p><dl> 294 </p>
295 <dl>
227 <dt>Returns:</dt> 296 <dt>Returns:</dt>
228 <dd> 297 <dd>
229 flag indicating the enabled state (boolean) 298 flag indicating the enabled state (boolean)
230 </dd> 299 </dd>
231 </dl><a NAME="E5MapWidget.isOnRightSide" ID="E5MapWidget.isOnRightSide"></a> 300 </dl>
301 <a NAME="E5MapWidget.isOnRightSide" ID="E5MapWidget.isOnRightSide"></a>
232 <h4>E5MapWidget.isOnRightSide</h4> 302 <h4>E5MapWidget.isOnRightSide</h4>
233 <b>isOnRightSide</b>(<i></i>) 303 <b>isOnRightSide</b>(<i></i>)
304
234 <p> 305 <p>
235 Public method to test, if the map is shown on the right side of the 306 Public method to test, if the map is shown on the right side of the
236 master widget. 307 master widget.
237 </p><dl> 308 </p>
309 <dl>
238 <dt>Returns:</dt> 310 <dt>Returns:</dt>
239 <dd> 311 <dd>
240 flag indicating that the map is to the right of the master 312 flag indicating that the map is to the right of the master
241 widget 313 widget
242 </dd> 314 </dd>
243 </dl><dl> 315 </dl>
316 <dl>
244 <dt>Return Type:</dt> 317 <dt>Return Type:</dt>
245 <dd> 318 <dd>
246 bool 319 bool
247 </dd> 320 </dd>
248 </dl><a NAME="E5MapWidget.lineDimensions" ID="E5MapWidget.lineDimensions"></a> 321 </dl>
322 <a NAME="E5MapWidget.lineDimensions" ID="E5MapWidget.lineDimensions"></a>
249 <h4>E5MapWidget.lineDimensions</h4> 323 <h4>E5MapWidget.lineDimensions</h4>
250 <b>lineDimensions</b>(<i></i>) 324 <b>lineDimensions</b>(<i></i>)
325
251 <p> 326 <p>
252 Public method to get the line (indicator) dimensions. 327 Public method to get the line (indicator) dimensions.
253 </p><dl> 328 </p>
329 <dl>
254 <dt>Returns:</dt> 330 <dt>Returns:</dt>
255 <dd> 331 <dd>
256 tuple with border width (integer) and line height (integer) 332 tuple with border width (integer) and line height (integer)
257 </dd> 333 </dd>
258 </dl><a NAME="E5MapWidget.mouseMoveEvent" ID="E5MapWidget.mouseMoveEvent"></a> 334 </dl>
335 <a NAME="E5MapWidget.mouseMoveEvent" ID="E5MapWidget.mouseMoveEvent"></a>
259 <h4>E5MapWidget.mouseMoveEvent</h4> 336 <h4>E5MapWidget.mouseMoveEvent</h4>
260 <b>mouseMoveEvent</b>(<i>event</i>) 337 <b>mouseMoveEvent</b>(<i>event</i>)
338
261 <p> 339 <p>
262 Protected method to handle a mouse moves. 340 Protected method to handle a mouse moves.
263 </p><dl> 341 </p>
342 <dl>
343
264 <dt><i>event</i></dt> 344 <dt><i>event</i></dt>
265 <dd> 345 <dd>
266 reference to the mouse event (QMouseEvent) 346 reference to the mouse event (QMouseEvent)
267 </dd> 347 </dd>
268 </dl><a NAME="E5MapWidget.mousePressEvent" ID="E5MapWidget.mousePressEvent"></a> 348 </dl>
349 <a NAME="E5MapWidget.mousePressEvent" ID="E5MapWidget.mousePressEvent"></a>
269 <h4>E5MapWidget.mousePressEvent</h4> 350 <h4>E5MapWidget.mousePressEvent</h4>
270 <b>mousePressEvent</b>(<i>event</i>) 351 <b>mousePressEvent</b>(<i>event</i>)
352
271 <p> 353 <p>
272 Protected method to handle a mouse button press. 354 Protected method to handle a mouse button press.
273 </p><dl> 355 </p>
356 <dl>
357
274 <dt><i>event</i></dt> 358 <dt><i>event</i></dt>
275 <dd> 359 <dd>
276 reference to the mouse event (QMouseEvent) 360 reference to the mouse event (QMouseEvent)
277 </dd> 361 </dd>
278 </dl><a NAME="E5MapWidget.paintEvent" ID="E5MapWidget.paintEvent"></a> 362 </dl>
363 <a NAME="E5MapWidget.paintEvent" ID="E5MapWidget.paintEvent"></a>
279 <h4>E5MapWidget.paintEvent</h4> 364 <h4>E5MapWidget.paintEvent</h4>
280 <b>paintEvent</b>(<i>event</i>) 365 <b>paintEvent</b>(<i>event</i>)
366
281 <p> 367 <p>
282 Protected method to handle a paint event. 368 Protected method to handle a paint event.
283 </p><dl> 369 </p>
370 <dl>
371
284 <dt><i>event</i></dt> 372 <dt><i>event</i></dt>
285 <dd> 373 <dd>
286 paint event (QPaintEvent) 374 paint event (QPaintEvent)
287 </dd> 375 </dd>
288 </dl><a NAME="E5MapWidget.position2Value" ID="E5MapWidget.position2Value"></a> 376 </dl>
377 <a NAME="E5MapWidget.position2Value" ID="E5MapWidget.position2Value"></a>
289 <h4>E5MapWidget.position2Value</h4> 378 <h4>E5MapWidget.position2Value</h4>
290 <b>position2Value</b>(<i>position, slider=False</i>) 379 <b>position2Value</b>(<i>position, slider=False</i>)
380
291 <p> 381 <p>
292 Public method to convert a position into a scrollbar value. 382 Public method to convert a position into a scrollbar value.
293 </p><dl> 383 </p>
384 <dl>
385
294 <dt><i>position</i></dt> 386 <dt><i>position</i></dt>
295 <dd> 387 <dd>
296 scrollbar position to convert (integer) 388 scrollbar position to convert (integer)
297 </dd><dt><i>slider</i></dt> 389 </dd>
390 <dt><i>slider</i></dt>
298 <dd> 391 <dd>
299 flag indicating to calculate the result for the slider 392 flag indicating to calculate the result for the slider
300 (boolean) 393 (boolean)
301 </dd> 394 </dd>
302 </dl><dl> 395 </dl>
396 <dl>
303 <dt>Returns:</dt> 397 <dt>Returns:</dt>
304 <dd> 398 <dd>
305 scrollbar value (integer) 399 scrollbar value (integer)
306 </dd> 400 </dd>
307 </dl><a NAME="E5MapWidget.scaleFactor" ID="E5MapWidget.scaleFactor"></a> 401 </dl>
402 <a NAME="E5MapWidget.scaleFactor" ID="E5MapWidget.scaleFactor"></a>
308 <h4>E5MapWidget.scaleFactor</h4> 403 <h4>E5MapWidget.scaleFactor</h4>
309 <b>scaleFactor</b>(<i>slider=False</i>) 404 <b>scaleFactor</b>(<i>slider=False</i>)
405
310 <p> 406 <p>
311 Public method to determine the scrollbar's scale factor. 407 Public method to determine the scrollbar's scale factor.
312 </p><dl> 408 </p>
409 <dl>
410
313 <dt><i>slider</i></dt> 411 <dt><i>slider</i></dt>
314 <dd> 412 <dd>
315 flag indicating to calculate the result for the slider 413 flag indicating to calculate the result for the slider
316 (boolean) 414 (boolean)
317 </dd> 415 </dd>
318 </dl><dl> 416 </dl>
417 <dl>
319 <dt>Returns:</dt> 418 <dt>Returns:</dt>
320 <dd> 419 <dd>
321 scale factor (float) 420 scale factor (float)
322 </dd> 421 </dd>
323 </dl><a NAME="E5MapWidget.setBackgroundColor" ID="E5MapWidget.setBackgroundColor"></a> 422 </dl>
423 <a NAME="E5MapWidget.setBackgroundColor" ID="E5MapWidget.setBackgroundColor"></a>
324 <h4>E5MapWidget.setBackgroundColor</h4> 424 <h4>E5MapWidget.setBackgroundColor</h4>
325 <b>setBackgroundColor</b>(<i>color</i>) 425 <b>setBackgroundColor</b>(<i>color</i>)
426
326 <p> 427 <p>
327 Public method to set the widget background color. 428 Public method to set the widget background color.
328 </p><dl> 429 </p>
430 <dl>
431
329 <dt><i>color</i></dt> 432 <dt><i>color</i></dt>
330 <dd> 433 <dd>
331 color for the background (QColor) 434 color for the background (QColor)
332 </dd> 435 </dd>
333 </dl><a NAME="E5MapWidget.setEnabled" ID="E5MapWidget.setEnabled"></a> 436 </dl>
437 <a NAME="E5MapWidget.setEnabled" ID="E5MapWidget.setEnabled"></a>
334 <h4>E5MapWidget.setEnabled</h4> 438 <h4>E5MapWidget.setEnabled</h4>
335 <b>setEnabled</b>(<i>enable</i>) 439 <b>setEnabled</b>(<i>enable</i>)
440
336 <p> 441 <p>
337 Public method to set the enabled state. 442 Public method to set the enabled state.
338 </p><dl> 443 </p>
444 <dl>
445
339 <dt><i>enable</i></dt> 446 <dt><i>enable</i></dt>
340 <dd> 447 <dd>
341 flag indicating the enabled state (boolean) 448 flag indicating the enabled state (boolean)
342 </dd> 449 </dd>
343 </dl><a NAME="E5MapWidget.setLineDimensions" ID="E5MapWidget.setLineDimensions"></a> 450 </dl>
451 <a NAME="E5MapWidget.setLineDimensions" ID="E5MapWidget.setLineDimensions"></a>
344 <h4>E5MapWidget.setLineDimensions</h4> 452 <h4>E5MapWidget.setLineDimensions</h4>
345 <b>setLineDimensions</b>(<i>border, height</i>) 453 <b>setLineDimensions</b>(<i>border, height</i>)
454
346 <p> 455 <p>
347 Public method to set the line (indicator) dimensions. 456 Public method to set the line (indicator) dimensions.
348 </p><dl> 457 </p>
458 <dl>
459
349 <dt><i>border</i></dt> 460 <dt><i>border</i></dt>
350 <dd> 461 <dd>
351 border width on each side in x-direction (integer) 462 border width on each side in x-direction (integer)
352 </dd><dt><i>height</i></dt> 463 </dd>
464 <dt><i>height</i></dt>
353 <dd> 465 <dd>
354 height of the line in pixels (integer) 466 height of the line in pixels (integer)
355 </dd> 467 </dd>
356 </dl><a NAME="E5MapWidget.setMapPosition" ID="E5MapWidget.setMapPosition"></a> 468 </dl>
469 <a NAME="E5MapWidget.setMapPosition" ID="E5MapWidget.setMapPosition"></a>
357 <h4>E5MapWidget.setMapPosition</h4> 470 <h4>E5MapWidget.setMapPosition</h4>
358 <b>setMapPosition</b>(<i>onRight</i>) 471 <b>setMapPosition</b>(<i>onRight</i>)
472
359 <p> 473 <p>
360 Public method to set, whether the map should be shown to the right or 474 Public method to set, whether the map should be shown to the right or
361 left of the master widget. 475 left of the master widget.
362 </p><dl> 476 </p>
477 <dl>
478
363 <dt><i>onRight</i> (bool)</dt> 479 <dt><i>onRight</i> (bool)</dt>
364 <dd> 480 <dd>
365 flag indicating to show the map on the right side of 481 flag indicating to show the map on the right side of
366 the master widget 482 the master widget
367 </dd> 483 </dd>
368 </dl><a NAME="E5MapWidget.setMaster" ID="E5MapWidget.setMaster"></a> 484 </dl>
485 <a NAME="E5MapWidget.setMaster" ID="E5MapWidget.setMaster"></a>
369 <h4>E5MapWidget.setMaster</h4> 486 <h4>E5MapWidget.setMaster</h4>
370 <b>setMaster</b>(<i>master</i>) 487 <b>setMaster</b>(<i>master</i>)
488
371 <p> 489 <p>
372 Public method to set the map master widget. 490 Public method to set the map master widget.
373 </p><dl> 491 </p>
492 <dl>
493
374 <dt><i>master</i></dt> 494 <dt><i>master</i></dt>
375 <dd> 495 <dd>
376 map master widget (QAbstractScrollArea) 496 map master widget (QAbstractScrollArea)
377 </dd> 497 </dd>
378 </dl><a NAME="E5MapWidget.setWidth" ID="E5MapWidget.setWidth"></a> 498 </dl>
499 <a NAME="E5MapWidget.setWidth" ID="E5MapWidget.setWidth"></a>
379 <h4>E5MapWidget.setWidth</h4> 500 <h4>E5MapWidget.setWidth</h4>
380 <b>setWidth</b>(<i>width</i>) 501 <b>setWidth</b>(<i>width</i>)
502
381 <p> 503 <p>
382 Public method to set the widget width. 504 Public method to set the widget width.
383 </p><dl> 505 </p>
506 <dl>
507
384 <dt><i>width</i></dt> 508 <dt><i>width</i></dt>
385 <dd> 509 <dd>
386 widget width (integer) 510 widget width (integer)
387 </dd> 511 </dd>
388 </dl><a NAME="E5MapWidget.sizeHint" ID="E5MapWidget.sizeHint"></a> 512 </dl>
513 <a NAME="E5MapWidget.sizeHint" ID="E5MapWidget.sizeHint"></a>
389 <h4>E5MapWidget.sizeHint</h4> 514 <h4>E5MapWidget.sizeHint</h4>
390 <b>sizeHint</b>(<i></i>) 515 <b>sizeHint</b>(<i></i>)
516
391 <p> 517 <p>
392 Public method to give an indication about the preferred size. 518 Public method to give an indication about the preferred size.
393 </p><dl> 519 </p>
520 <dl>
394 <dt>Returns:</dt> 521 <dt>Returns:</dt>
395 <dd> 522 <dd>
396 preferred size (QSize) 523 preferred size (QSize)
397 </dd> 524 </dd>
398 </dl><a NAME="E5MapWidget.value2Position" ID="E5MapWidget.value2Position"></a> 525 </dl>
526 <a NAME="E5MapWidget.value2Position" ID="E5MapWidget.value2Position"></a>
399 <h4>E5MapWidget.value2Position</h4> 527 <h4>E5MapWidget.value2Position</h4>
400 <b>value2Position</b>(<i>value, slider=False</i>) 528 <b>value2Position</b>(<i>value, slider=False</i>)
529
401 <p> 530 <p>
402 Public method to convert a scrollbar value into a position. 531 Public method to convert a scrollbar value into a position.
403 </p><dl> 532 </p>
533 <dl>
534
404 <dt><i>value</i></dt> 535 <dt><i>value</i></dt>
405 <dd> 536 <dd>
406 value to convert (integer) 537 value to convert (integer)
407 </dd><dt><i>slider</i></dt> 538 </dd>
539 <dt><i>slider</i></dt>
408 <dd> 540 <dd>
409 flag indicating to calculate the result for the slider 541 flag indicating to calculate the result for the slider
410 (boolean) 542 (boolean)
411 </dd> 543 </dd>
412 </dl><dl> 544 </dl>
545 <dl>
413 <dt>Returns:</dt> 546 <dt>Returns:</dt>
414 <dd> 547 <dd>
415 position (integer) 548 position (integer)
416 </dd> 549 </dd>
417 </dl><a NAME="E5MapWidget.wheelEvent" ID="E5MapWidget.wheelEvent"></a> 550 </dl>
551 <a NAME="E5MapWidget.wheelEvent" ID="E5MapWidget.wheelEvent"></a>
418 <h4>E5MapWidget.wheelEvent</h4> 552 <h4>E5MapWidget.wheelEvent</h4>
419 <b>wheelEvent</b>(<i>event</i>) 553 <b>wheelEvent</b>(<i>event</i>)
554
420 <p> 555 <p>
421 Protected slot handling mouse wheel events. 556 Protected slot handling mouse wheel events.
422 </p><dl> 557 </p>
558 <dl>
559
423 <dt><i>event</i></dt> 560 <dt><i>event</i></dt>
424 <dd> 561 <dd>
425 reference to the wheel event (QWheelEvent) 562 reference to the wheel event (QWheelEvent)
426 </dd> 563 </dd>
427 </dl><a NAME="E5MapWidget.width" ID="E5MapWidget.width"></a> 564 </dl>
565 <a NAME="E5MapWidget.width" ID="E5MapWidget.width"></a>
428 <h4>E5MapWidget.width</h4> 566 <h4>E5MapWidget.width</h4>
429 <b>width</b>(<i></i>) 567 <b>width</b>(<i></i>)
568
430 <p> 569 <p>
431 Public method to get the widget's width. 570 Public method to get the widget's width.
432 </p><dl> 571 </p>
572 <dl>
433 <dt>Returns:</dt> 573 <dt>Returns:</dt>
434 <dd> 574 <dd>
435 widget width (integer) 575 widget width (integer)
436 </dd> 576 </dd>
437 </dl> 577 </dl>

eric ide

mercurial