QGIS API Documentation  3.0.2-Girona (307d082)
qgsdetaileditemdata.cpp
Go to the documentation of this file.
1 /***************************************************************************
2  qgsdetailedlistdata.cpp - A data represenation for a rich QItemData subclass
3  -------------------
4  begin : Sat May 17 2008
5  copyright : (C) 2008 Tim Sutton
6  email : [email protected]
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * This program is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU General Public License as published by *
13  * the Free Software Foundation; either version 2 of the License, or *
14  * (at your option) any later version. *
15  * *
16  ***************************************************************************/
17 
18 #include "qgsdetaileditemdata.h"
19 
20 void QgsDetailedItemData::setTitle( const QString &title )
21 {
22  mTitle = title;
23 }
24 
25 void QgsDetailedItemData::setDetail( const QString &detail )
26 {
27  mDetail = detail;
28 }
29 
31 {
32  mCategory = category;
33 }
34 
35 void QgsDetailedItemData::setIcon( const QPixmap &icon )
36 {
37  mPixmap = icon;
38 }
39 
40 void QgsDetailedItemData::setCheckable( const bool flag )
41 {
42  mCheckableFlag = flag;
43 }
44 
45 void QgsDetailedItemData::setChecked( const bool flag )
46 {
47  mCheckedFlag = flag;
48 }
49 
51 {
52  mRenderAsWidgetFlag = flag;
53 }
54 
56 {
57  return mTitle;
58 }
59 
61 {
62  return mDetail;
63 }
64 
66 {
67  return mCategory;
68 }
69 
71 {
72  return mPixmap;
73 }
74 
76 {
77  return mCheckableFlag;
78 }
79 
81 {
82  return mCheckedFlag;
83 }
84 
86 {
87  return mRenderAsWidgetFlag;
88 }
89 
91 {
92  mEnabledFlag = flag;
93 }
94 
96 {
97  return mEnabledFlag;
98 }
void setCheckable(const bool flag)
void setDetail(const QString &detail)
void setChecked(const bool flag)
void setEnabled(bool flag)
void setTitle(const QString &title)
void setIcon(const QPixmap &icon)
void setCategory(const QString &category)
void setRenderAsWidget(bool flag)
This is a hint to the delegate to render using a widget rather than manually painting every part of t...