194 <td><a href="#PreviewModel.__init__">PreviewModel</a></td> |
194 <td><a href="#PreviewModel.__init__">PreviewModel</a></td> |
195 <td>Constructor</td> |
195 <td>Constructor</td> |
196 </tr> |
196 </tr> |
197 <tr> |
197 <tr> |
198 <td><a href="#PreviewModel.columnCount">columnCount</a></td> |
198 <td><a href="#PreviewModel.columnCount">columnCount</a></td> |
199 <td></td> |
199 <td>Public Qt slot to get the column count.</td> |
200 </tr> |
200 </tr> |
201 <tr> |
201 <tr> |
202 <td><a href="#PreviewModel.data">data</a></td> |
202 <td><a href="#PreviewModel.data">data</a></td> |
203 <td>Public Qt slot get the role data of item.</td> |
203 <td>Public Qt slot get the role data of item.</td> |
204 </tr> |
204 </tr> |
205 <tr> |
205 <tr> |
206 <td><a href="#PreviewModel.flags">flags</a></td> |
206 <td><a href="#PreviewModel.flags">flags</a></td> |
207 <td></td> |
207 <td>Public Qt slot to get the item flags.</td> |
208 </tr> |
208 </tr> |
209 <tr> |
209 <tr> |
210 <td><a href="#PreviewModel.index">index</a></td> |
210 <td><a href="#PreviewModel.index">index</a></td> |
211 <td>Public Qt slot to get the index of item at row:column of parent.</td> |
211 <td>Public Qt slot to get the index of item at row:column of parent.</td> |
212 </tr> |
212 </tr> |
213 <tr> |
213 <tr> |
214 <td><a href="#PreviewModel.parent">parent</a></td> |
214 <td><a href="#PreviewModel.parent">parent</a></td> |
215 <td></td> |
215 <td>Public Qt slot to get the parent of the given child.</td> |
216 </tr> |
216 </tr> |
217 <tr> |
217 <tr> |
218 <td><a href="#PreviewModel.rowCount">rowCount</a></td> |
218 <td><a href="#PreviewModel.rowCount">rowCount</a></td> |
219 <td></td> |
219 <td>Public Qt slot to get the row count.</td> |
220 </tr> |
220 </tr> |
221 <tr> |
221 <tr> |
222 <td><a href="#PreviewModel.setColor">setColor</a></td> |
222 <td><a href="#PreviewModel.setColor">setColor</a></td> |
223 <td>Public slot to update the background colour indexed by key.</td> |
223 <td>Public slot to update the background colour indexed by key.</td> |
224 </tr> |
224 </tr> |
238 </p> |
238 </p> |
239 <a NAME="PreviewModel.columnCount" ID="PreviewModel.columnCount"></a> |
239 <a NAME="PreviewModel.columnCount" ID="PreviewModel.columnCount"></a> |
240 <h4>PreviewModel.columnCount</h4> |
240 <h4>PreviewModel.columnCount</h4> |
241 <b>columnCount</b>(<i>parent=QModelIndex()</i>) |
241 <b>columnCount</b>(<i>parent=QModelIndex()</i>) |
242 |
242 |
|
243 <p> |
|
244 Public Qt slot to get the column count. |
|
245 </p> |
|
246 <dl> |
|
247 |
|
248 <dt><i>parent</i> (QModelIndex)</dt> |
|
249 <dd> |
|
250 the model parent |
|
251 </dd> |
|
252 </dl> |
|
253 <dl> |
|
254 <dt>Return:</dt> |
|
255 <dd> |
|
256 number of columns |
|
257 </dd> |
|
258 </dl> |
|
259 <dl> |
|
260 <dt>Return Type:</dt> |
|
261 <dd> |
|
262 int |
|
263 </dd> |
|
264 </dl> |
243 <a NAME="PreviewModel.data" ID="PreviewModel.data"></a> |
265 <a NAME="PreviewModel.data" ID="PreviewModel.data"></a> |
244 <h4>PreviewModel.data</h4> |
266 <h4>PreviewModel.data</h4> |
245 <b>data</b>(<i>index, role=Qt.ItemDataRole.DisplayRole</i>) |
267 <b>data</b>(<i>index, role=Qt.ItemDataRole.DisplayRole</i>) |
246 |
268 |
247 <p> |
269 <p> |
272 </dl> |
294 </dl> |
273 <a NAME="PreviewModel.flags" ID="PreviewModel.flags"></a> |
295 <a NAME="PreviewModel.flags" ID="PreviewModel.flags"></a> |
274 <h4>PreviewModel.flags</h4> |
296 <h4>PreviewModel.flags</h4> |
275 <b>flags</b>(<i>index</i>) |
297 <b>flags</b>(<i>index</i>) |
276 |
298 |
|
299 <p> |
|
300 Public Qt slot to get the item flags. |
|
301 </p> |
|
302 <dl> |
|
303 |
|
304 <dt><i>index</i> (QModelIndex)</dt> |
|
305 <dd> |
|
306 of item |
|
307 </dd> |
|
308 </dl> |
|
309 <dl> |
|
310 <dt>Return:</dt> |
|
311 <dd> |
|
312 item flags |
|
313 </dd> |
|
314 </dl> |
|
315 <dl> |
|
316 <dt>Return Type:</dt> |
|
317 <dd> |
|
318 QtCore.Qt.ItemFlag |
|
319 </dd> |
|
320 </dl> |
277 <a NAME="PreviewModel.index" ID="PreviewModel.index"></a> |
321 <a NAME="PreviewModel.index" ID="PreviewModel.index"></a> |
278 <h4>PreviewModel.index</h4> |
322 <h4>PreviewModel.index</h4> |
279 <b>index</b>(<i>row, column, parent=QModelIndex()</i>) |
323 <b>index</b>(<i>row, column, parent=QModelIndex()</i>) |
280 |
324 |
281 <p> |
325 <p> |
310 </dl> |
354 </dl> |
311 <a NAME="PreviewModel.parent" ID="PreviewModel.parent"></a> |
355 <a NAME="PreviewModel.parent" ID="PreviewModel.parent"></a> |
312 <h4>PreviewModel.parent</h4> |
356 <h4>PreviewModel.parent</h4> |
313 <b>parent</b>(<i>child</i>) |
357 <b>parent</b>(<i>child</i>) |
314 |
358 |
|
359 <p> |
|
360 Public Qt slot to get the parent of the given child. |
|
361 </p> |
|
362 <dl> |
|
363 |
|
364 <dt><i>child</i> (QModelIndex)</dt> |
|
365 <dd> |
|
366 the model child node |
|
367 </dd> |
|
368 </dl> |
|
369 <dl> |
|
370 <dt>Return:</dt> |
|
371 <dd> |
|
372 new model index for parent |
|
373 </dd> |
|
374 </dl> |
|
375 <dl> |
|
376 <dt>Return Type:</dt> |
|
377 <dd> |
|
378 QModelIndex |
|
379 </dd> |
|
380 </dl> |
315 <a NAME="PreviewModel.rowCount" ID="PreviewModel.rowCount"></a> |
381 <a NAME="PreviewModel.rowCount" ID="PreviewModel.rowCount"></a> |
316 <h4>PreviewModel.rowCount</h4> |
382 <h4>PreviewModel.rowCount</h4> |
317 <b>rowCount</b>(<i>parent=QModelIndex()</i>) |
383 <b>rowCount</b>(<i>parent=QModelIndex()</i>) |
318 |
384 |
|
385 <p> |
|
386 Public Qt slot to get the row count. |
|
387 </p> |
|
388 <dl> |
|
389 |
|
390 <dt><i>parent</i> (QModelIndex)</dt> |
|
391 <dd> |
|
392 the model parent |
|
393 </dd> |
|
394 </dl> |
|
395 <dl> |
|
396 <dt>Return:</dt> |
|
397 <dd> |
|
398 number of rows |
|
399 </dd> |
|
400 </dl> |
|
401 <dl> |
|
402 <dt>Return Type:</dt> |
|
403 <dd> |
|
404 int |
|
405 </dd> |
|
406 </dl> |
319 <a NAME="PreviewModel.setColor" ID="PreviewModel.setColor"></a> |
407 <a NAME="PreviewModel.setColor" ID="PreviewModel.setColor"></a> |
320 <h4>PreviewModel.setColor</h4> |
408 <h4>PreviewModel.setColor</h4> |
321 <b>setColor</b>(<i>key, bgcolour</i>) |
409 <b>setColor</b>(<i>key, bgcolour</i>) |
322 |
410 |
323 <p> |
411 <p> |