Qt 4.8
Public Functions | Public Variables | List of all members
QStandardItemPrivate Class Reference

#include <qstandarditemmodel_p.h>

Public Functions

void changeFlags (bool enable, Qt::ItemFlags f)
 
void childDeleted (QStandardItem *child)
 
int childIndex (int row, int column) const
 
int childIndex (const QStandardItem *child)
 
int columnCount () const
 
bool insertColumns (int column, int count, const QList< QStandardItem *> &items)
 
bool insertRows (int row, int count, const QList< QStandardItem *> &items)
 
bool insertRows (int row, const QList< QStandardItem *> &items)
 
const QMap< int, QVariantitemData () const
 
QPair< int, int > position () const
 
 QStandardItemPrivate ()
 
int rowCount () const
 
void setChild (int row, int column, QStandardItem *item, bool emitChanged=false)
 
void setItemData (const QMap< int, QVariant > &roles)
 
void setModel (QStandardItemModel *mod)
 
void setParentAndModel (QStandardItem *par, QStandardItemModel *mod)
 
void sortChildren (int column, Qt::SortOrder order)
 
virtual ~QStandardItemPrivate ()
 

Public Variables

QVector< QStandardItem * > children
 
int columns
 
int lastIndexOf
 
QStandardItemModelmodel
 
QStandardItemparent
 
QStandardItemq_ptr
 
int rows
 
QVector< QWidgetItemDatavalues
 

Detailed Description

Definition at line 69 of file qstandarditemmodel_p.h.

Constructors and Destructors

◆ QStandardItemPrivate()

QStandardItemPrivate::QStandardItemPrivate ( )
inline

Definition at line 73 of file qstandarditemmodel_p.h.

74  : model(0),
75  parent(0),
76  rows(0),
77  columns(0),
78  q_ptr(0),
79  lastIndexOf(2)
80  { }
QStandardItemModel * model

◆ ~QStandardItemPrivate()

QStandardItemPrivate::~QStandardItemPrivate ( )
virtual
Warning
This function is not part of the public interface.

Definition at line 90 of file qstandarditemmodel.cpp.

Referenced by QStandardItemPrivate().

91 {
93  for (it = children.constBegin(); it != children.constEnd(); ++it) {
94  QStandardItem *child = *it;
95  if (child)
96  child->d_func()->setModel(0);
97  delete child;
98  }
99  children.clear();
100  if (parent && model)
101  parent->d_func()->childDeleted(q_func());
102 }
#define it(className, varName)
const_iterator constEnd() const
Returns a const STL-style iterator pointing to the imaginary item after the last item in the vector...
Definition: qvector.h:252
QVector< QStandardItem * > children
const_iterator constBegin() const
Returns a const STL-style iterator pointing to the first item in the vector.
Definition: qvector.h:249
void clear()
Removes all the elements from the vector and releases the memory used by the vector.
Definition: qvector.h:347
QStandardItemModel * model
const T * const_iterator
The QVector::const_iterator typedef provides an STL-style const iterator for QVector and QStack...
Definition: qvector.h:245
The QStandardItem class provides an item for use with the QStandardItemModel class.

Functions

◆ changeFlags()

void QStandardItemPrivate::changeFlags ( bool  enable,
Qt::ItemFlags  f 
)
Warning
This function is not part of the public interface.

Definition at line 163 of file qstandarditemmodel.cpp.

Referenced by setParentAndModel().

164 {
166  Qt::ItemFlags flags = q->flags();
167  if (enable)
168  flags |= f;
169  else
170  flags &= ~f;
171  q->setFlags(flags);
172 }
#define Q_Q(Class)
Definition: qglobal.h:2483
The QStandardItem class provides an item for use with the QStandardItemModel class.

◆ childDeleted()

void QStandardItemPrivate::childDeleted ( QStandardItem child)
Warning
This function is not part of the public interface.

Definition at line 177 of file qstandarditemmodel.cpp.

Referenced by columnCount().

178 {
179  int index = childIndex(child);
180  Q_ASSERT(index != -1);
181  children.replace(index, 0);
182 }
void replace(int i, const T &t)
Replaces the item at index position i with value.
Definition: qvector.h:382
QVector< QStandardItem * > children
#define Q_ASSERT(cond)
Definition: qglobal.h:1823
int childIndex(int row, int column) const
quint16 index

◆ childIndex() [1/2]

int QStandardItemPrivate::childIndex ( int  row,
int  column 
) const
inline

Definition at line 83 of file qstandarditemmodel_p.h.

83  {
84  if ((row < 0) || (column < 0)
85  || (row >= rowCount()) || (column >= columnCount())) {
86  return -1;
87  }
88  return (row * columnCount()) + column;
89  }

◆ childIndex() [2/2]

int QStandardItemPrivate::childIndex ( const QStandardItem child)
inline

Definition at line 90 of file qstandarditemmodel_p.h.

90  {
91  int start = qMax(0, lastIndexOf -2);
92  lastIndexOf = children.indexOf(const_cast<QStandardItem*>(child), start);
93  if (lastIndexOf == -1 && start != 0)
94  lastIndexOf = children.lastIndexOf(const_cast<QStandardItem*>(child), start);
95  return lastIndexOf;
96  }
QVector< QStandardItem * > children
Q_DECL_CONSTEXPR const T & qMax(const T &a, const T &b)
Definition: qglobal.h:1217
int indexOf(const T &t, int from=0) const
Returns the index position of the first occurrence of value in the vector, searching forward from ind...
Definition: qvector.h:698
int lastIndexOf(const T &t, int from=-1) const
Returns the index position of the last occurrence of the value value in the vector, searching backward from index position from.
Definition: qvector.h:713

◆ columnCount()

int QStandardItemPrivate::columnCount ( ) const
inline

Definition at line 103 of file qstandarditemmodel_p.h.

Referenced by childIndex().

103  {
104  return columns;
105  }

◆ insertColumns()

bool QStandardItemPrivate::insertColumns ( int  column,
int  count,
const QList< QStandardItem *> &  items 
)
Warning
This function is not part of the public interface.

Definition at line 440 of file qstandarditemmodel.cpp.

Referenced by setParentAndModel().

441 {
443  if ((count < 1) || (column < 0) || (column > columnCount()))
444  return false;
445  if (model)
446  model->d_func()->columnsAboutToBeInserted(q, column, column + count - 1);
447  if (columnCount() == 0) {
448  children.resize(rowCount() * count);
449  columns = count;
450  } else {
451  columns += count;
452  int index = childIndex(0, column);
453  for (int row = 0; row < rowCount(); ++row) {
454  children.insert(index, count, 0);
455  index += columnCount();
456  }
457  }
458  if (!items.isEmpty()) {
459  int limit = qMin(items.count(), rowCount() * count);
460  for (int i = 0; i < limit; ++i) {
461  QStandardItem *item = items.at(i);
462  if (item) {
463  if (item->d_func()->parent == 0) {
464  item->d_func()->setParentAndModel(q, model);
465  } else {
466  qWarning("QStandardItem::insertColumns: Ignoring duplicate insertion of item %p",
467  item);
468  item = 0;
469  }
470  }
471  int r = i / count;
472  int c = column + (i % count);
473  int index = childIndex(r, c);
474  children.replace(index, item);
475  }
476  }
477  if (model)
478  model->d_func()->columnsInserted(q, column, count);
479  return true;
480 }
unsigned char c[8]
Definition: qnumeric_p.h:62
Q_DECL_CONSTEXPR const T & qMin(const T &a, const T &b)
Definition: qglobal.h:1215
void replace(int i, const T &t)
Replaces the item at index position i with value.
Definition: qvector.h:382
void columnsInserted(const QModelIndex &parent, int first, int last)
This signal is emitted after columns have been inserted into the model.
int count(const T &t) const
Returns the number of occurrences of value in the list.
Definition: qlist.h:891
QVector< QStandardItem * > children
int childIndex(int row, int column) const
bool isEmpty() const
Returns true if the list contains no items; otherwise returns false.
Definition: qlist.h:152
void resize(int size)
Sets the size of the vector to size.
Definition: qvector.h:342
#define Q_Q(Class)
Definition: qglobal.h:2483
void columnsAboutToBeInserted(const QModelIndex &parent, int first, int last)
This signal is emitted just before columns are inserted into the model.
const T & at(int i) const
Returns the item at index position i in the list.
Definition: qlist.h:468
Q_CORE_EXPORT void qWarning(const char *,...)
QStandardItemModel * model
void insert(int i, const T &t)
Inserts value at index position i in the vector.
Definition: qvector.h:362
quint16 index
The QStandardItem class provides an item for use with the QStandardItemModel class.
QStandardItem * parent() const
Returns the item&#39;s parent item, or 0 if the item has no parent.

◆ insertRows() [1/2]

bool QStandardItemPrivate::insertRows ( int  row,
int  count,
const QList< QStandardItem *> &  items 
)

Definition at line 398 of file qstandarditemmodel.cpp.

Referenced by setParentAndModel().

399 {
401  if ((count < 1) || (row < 0) || (row > rowCount()))
402  return false;
403  if (model)
404  model->d_func()->rowsAboutToBeInserted(q, row, row + count - 1);
405  if (rowCount() == 0) {
406  children.resize(columnCount() * count);
407  rows = count;
408  } else {
409  rows += count;
410  int index = childIndex(row, 0);
411  if (index != -1)
412  children.insert(index, columnCount() * count, 0);
413  }
414  if (!items.isEmpty()) {
415  int index = childIndex(row, 0);
416  int limit = qMin(items.count(), columnCount() * count);
417  for (int i = 0; i < limit; ++i) {
418  QStandardItem *item = items.at(i);
419  if (item) {
420  if (item->d_func()->parent == 0) {
421  item->d_func()->setParentAndModel(q, model);
422  } else {
423  qWarning("QStandardItem::insertRows: Ignoring duplicate insertion of item %p",
424  item);
425  item = 0;
426  }
427  }
428  children.replace(index, item);
429  ++index;
430  }
431  }
432  if (model)
433  model->d_func()->rowsInserted(q, row, count);
434  return true;
435 }
Q_DECL_CONSTEXPR const T & qMin(const T &a, const T &b)
Definition: qglobal.h:1215
void replace(int i, const T &t)
Replaces the item at index position i with value.
Definition: qvector.h:382
int count(const T &t) const
Returns the number of occurrences of value in the list.
Definition: qlist.h:891
QVector< QStandardItem * > children
int childIndex(int row, int column) const
bool isEmpty() const
Returns true if the list contains no items; otherwise returns false.
Definition: qlist.h:152
void resize(int size)
Sets the size of the vector to size.
Definition: qvector.h:342
#define Q_Q(Class)
Definition: qglobal.h:2483
void rowsAboutToBeInserted(const QModelIndex &parent, int first, int last)
This signal is emitted just before rows are inserted into the model.
const T & at(int i) const
Returns the item at index position i in the list.
Definition: qlist.h:468
Q_CORE_EXPORT void qWarning(const char *,...)
QStandardItemModel * model
void insert(int i, const T &t)
Inserts value at index position i in the vector.
Definition: qvector.h:362
void rowsInserted(const QModelIndex &parent, int first, int last)
This signal is emitted after rows have been inserted into the model.
quint16 index
The QStandardItem class provides an item for use with the QStandardItemModel class.
QStandardItem * parent() const
Returns the item&#39;s parent item, or 0 if the item has no parent.

◆ insertRows() [2/2]

bool QStandardItemPrivate::insertRows ( int  row,
const QList< QStandardItem *> &  items 
)
Warning
This function is not part of the public interface.

Definition at line 367 of file qstandarditemmodel.cpp.

368 {
370  if ((row < 0) || (row > rowCount()))
371  return false;
372  int count = items.count();
373  if (model)
374  model->d_func()->rowsAboutToBeInserted(q, row, row + count - 1);
375  if (rowCount() == 0) {
376  if (columnCount() == 0)
377  q->setColumnCount(1);
378  children.resize(columnCount() * count);
379  rows = count;
380  } else {
381  rows += count;
382  int index = childIndex(row, 0);
383  if (index != -1)
384  children.insert(index, columnCount() * count, 0);
385  }
386  for (int i = 0; i < items.count(); ++i) {
387  QStandardItem *item = items.at(i);
388  item->d_func()->model = model;
389  item->d_func()->parent = q;
390  int index = childIndex(i + row, 0);
391  children.replace(index, item);
392  }
393  if (model)
394  model->d_func()->rowsInserted(q, row, count);
395  return true;
396 }
void replace(int i, const T &t)
Replaces the item at index position i with value.
Definition: qvector.h:382
int count(const T &t) const
Returns the number of occurrences of value in the list.
Definition: qlist.h:891
QVector< QStandardItem * > children
int childIndex(int row, int column) const
void resize(int size)
Sets the size of the vector to size.
Definition: qvector.h:342
#define Q_Q(Class)
Definition: qglobal.h:2483
void rowsAboutToBeInserted(const QModelIndex &parent, int first, int last)
This signal is emitted just before rows are inserted into the model.
const T & at(int i) const
Returns the item at index position i in the list.
Definition: qlist.h:468
QStandardItemModel * model
void insert(int i, const T &t)
Inserts value at index position i in the vector.
Definition: qvector.h:362
void rowsInserted(const QModelIndex &parent, int first, int last)
This signal is emitted after rows have been inserted into the model.
QStandardItemModel * model() const
Returns the QStandardItemModel that this item belongs to.
quint16 index
The QStandardItem class provides an item for use with the QStandardItemModel class.
QStandardItem * parent() const
Returns the item&#39;s parent item, or 0 if the item has no parent.

◆ itemData()

const QMap< int, QVariant > QStandardItemPrivate::itemData ( ) const
Warning
This function is not part of the public interface.

Definition at line 214 of file qstandarditemmodel.cpp.

Referenced by setParentAndModel().

215 {
216  QMap<int, QVariant> result;
218  for (it = values.begin(); it != values.end(); ++it)
219  result.insert((*it).role, (*it).value);
220  return result;
221 }
#define it(className, varName)
The QVector class is a template class that provides a dynamic array.
Definition: qdatastream.h:64
iterator end()
Returns an STL-style iterator pointing to the imaginary item after the last item in the vector...
Definition: qvector.h:250
iterator begin()
Returns an STL-style iterator pointing to the first item in the vector.
Definition: qvector.h:247
iterator insert(const Key &key, const T &value)
Inserts a new item with the key key and a value of value.
Definition: qmap.h:559
QVector< QWidgetItemData > values
The QMap class is a template class that provides a skip-list-based dictionary.
Definition: qdatastream.h:67

◆ position()

QPair< int, int > QStandardItemPrivate::position ( ) const
Warning
This function is not part of the public interface.

Definition at line 107 of file qstandarditemmodel.cpp.

Referenced by childIndex().

108 {
109  if (QStandardItem *par = parent) {
110  int idx = par->d_func()->childIndex(q_func());
111  if (idx == -1)
112  return QPair<int, int>(-1, -1);
113  return QPair<int, int>(idx / par->columnCount(), idx % par->columnCount());
114  }
115  // ### support header items?
116  return QPair<int, int>(-1, -1);
117 }
The QStandardItem class provides an item for use with the QStandardItemModel class.

◆ rowCount()

int QStandardItemPrivate::rowCount ( ) const
inline

Definition at line 100 of file qstandarditemmodel_p.h.

Referenced by childIndex().

100  {
101  return rows;
102  }

◆ setChild()

void QStandardItemPrivate::setChild ( int  row,
int  column,
QStandardItem item,
bool  emitChanged = false 
)
Warning
This function is not part of the public interface.

Definition at line 122 of file qstandarditemmodel.cpp.

Referenced by childIndex().

124 {
126  if (item == q) {
127  qWarning("QStandardItem::setChild: Can't make an item a child of itself %p",
128  item);
129  return;
130  }
131  if ((row < 0) || (column < 0))
132  return;
133  if (rows <= row)
134  q->setRowCount(row + 1);
135  if (columns <= column)
136  q->setColumnCount(column + 1);
137  int index = childIndex(row, column);
138  Q_ASSERT(index != -1);
139  QStandardItem *oldItem = children.at(index);
140  if (item == oldItem)
141  return;
142  if (item) {
143  if (item->d_func()->parent == 0) {
144  item->d_func()->setParentAndModel(q, model);
145  } else {
146  qWarning("QStandardItem::setChild: Ignoring duplicate insertion of item %p",
147  item);
148  return;
149  }
150  }
151  if (oldItem)
152  oldItem->d_func()->setModel(0);
153  delete oldItem;
154  children.replace(index, item);
155  if (emitChanged && model)
156  model->d_func()->itemChanged(item);
157 }
void replace(int i, const T &t)
Replaces the item at index position i with value.
Definition: qvector.h:382
QVector< QStandardItem * > children
#define Q_ASSERT(cond)
Definition: qglobal.h:1823
int childIndex(int row, int column) const
#define Q_Q(Class)
Definition: qglobal.h:2483
void itemChanged(QStandardItem *item)
Q_CORE_EXPORT void qWarning(const char *,...)
QStandardItemModel * model
const T & at(int i) const
Returns the item at index position i in the vector.
Definition: qvector.h:350
quint16 index
The QStandardItem class provides an item for use with the QStandardItemModel class.
QStandardItem * parent() const
Returns the item&#39;s parent item, or 0 if the item has no parent.

◆ setItemData()

void QStandardItemPrivate::setItemData ( const QMap< int, QVariant > &  roles)
Warning
This function is not part of the public interface.

Definition at line 187 of file qstandarditemmodel.cpp.

Referenced by setParentAndModel().

188 {
190 
191  //let's build the vector of new values
192  QVector<QWidgetItemData> newValues;
194  for (it = roles.begin(); it != roles.end(); ++it) {
195  QVariant value = it.value();
196  if (value.isValid()) {
197  int role = it.key();
198  role = (role == Qt::EditRole) ? Qt::DisplayRole : role;
199  QWidgetItemData wid(role,it.value());
200  newValues.append(wid);
201  }
202  }
203 
204  if (values!=newValues) {
205  values=newValues;
206  if (model)
207  model->d_func()->itemChanged(q);
208  }
209 }
The QVariant class acts like a union for the most common Qt data types.
Definition: qvariant.h:92
#define it(className, varName)
const Key & key() const
Returns the current item&#39;s key.
Definition: qmap.h:324
#define Q_Q(Class)
Definition: qglobal.h:2483
void itemChanged(QStandardItem *item)
void append(const T &t)
Inserts value at the end of the vector.
Definition: qvector.h:573
QStandardItemModel * model
iterator begin()
Returns an STL-style iterator pointing to the first item in the map.
Definition: qmap.h:372
The QMap::const_iterator class provides an STL-style const iterator for QMap and QMultiMap.
Definition: qmap.h:301
iterator end()
Returns an STL-style iterator pointing to the imaginary item after the last item in the map...
Definition: qmap.h:375
const T & value() const
Returns the current item&#39;s value.
Definition: qmap.h:325
The QStandardItem class provides an item for use with the QStandardItemModel class.
bool isValid() const
Returns true if the storage type of this variant is not QVariant::Invalid; otherwise returns false...
Definition: qvariant.h:485
QVector< QWidgetItemData > values

◆ setModel()

void QStandardItemPrivate::setModel ( QStandardItemModel mod)
Warning
This function is not part of the public interface. set the model of this item and all its children

Definition at line 291 of file qstandarditemmodel.cpp.

Referenced by columnCount(), and setParentAndModel().

292 {
293  if (children.isEmpty()) {
294  if (model)
295  model->d_func()->invalidatePersistentIndex(model->indexFromItem(q_ptr));
296  model = mod;
297  } else {
299  stack.push(q_ptr);
300  while (!stack.isEmpty()) {
301  QStandardItem *itm = stack.pop();
302  if (itm->d_func()->model) {
303  itm->d_func()->model->d_func()->invalidatePersistentIndex(itm->d_func()->model->indexFromItem(itm));
304  }
305  itm->d_func()->model = mod;
306  const QVector<QStandardItem*> &childList = itm->d_func()->children;
307  for (int i = 0; i < childList.count(); ++i) {
308  QStandardItem *chi = childList.at(i);
309  if (chi)
310  stack.push(chi);
311  }
312  }
313  }
314 }
int count(const T &t) const
Returns the number of occurrences of value in the vector.
Definition: qvector.h:742
The QStack class is a template class that provides a stack.
Definition: qcontainerfwd.h:63
QVector< QStandardItem * > children
The QVector class is a template class that provides a dynamic array.
Definition: qdatastream.h:64
T pop()
Removes the top item from the stack and returns it.
Definition: qstack.h:67
void push(const T &t)
Adds element t to the top of the stack.
Definition: qstack.h:60
QStandardItemModel * model
const T & at(int i) const
Returns the item at index position i in the vector.
Definition: qvector.h:350
QModelIndex indexFromItem(const QStandardItem *item) const
Returns the QModelIndex associated with the given item.
QStandardItemModel * model() const
Returns the QStandardItemModel that this item belongs to.
bool isEmpty() const
Returns true if the vector has size 0; otherwise returns false.
Definition: qvector.h:139
The QStandardItem class provides an item for use with the QStandardItemModel class.

◆ setParentAndModel()

void QStandardItemPrivate::setParentAndModel ( QStandardItem par,
QStandardItemModel mod 
)
inline

Definition at line 110 of file qstandarditemmodel_p.h.

112  {
113  setModel(mod);
114  parent = par;
115  }
void setModel(QStandardItemModel *mod)

◆ sortChildren()

void QStandardItemPrivate::sortChildren ( int  column,
Qt::SortOrder  order 
)
Warning
This function is not part of the public interface.

Definition at line 226 of file qstandarditemmodel.cpp.

Referenced by setParentAndModel().

227 {
229  if (column >= columnCount())
230  return;
231 
233  QVector<int> unsortable;
234 
235  sortable.reserve(rowCount());
236  unsortable.reserve(rowCount());
237 
238  for (int row = 0; row < rowCount(); ++row) {
239  QStandardItem *itm = q->child(row, column);
240  if (itm)
241  sortable.append(QPair<QStandardItem*,int>(itm, row));
242  else
243  unsortable.append(row);
244  }
245 
246  if (order == Qt::AscendingOrder) {
248  qStableSort(sortable.begin(), sortable.end(), lt);
249  } else {
251  qStableSort(sortable.begin(), sortable.end(), gt);
252  }
253 
254  QModelIndexList changedPersistentIndexesFrom, changedPersistentIndexesTo;
255  QVector<QStandardItem*> sorted_children(children.count());
256  for (int i = 0; i < rowCount(); ++i) {
257  int r = (i < sortable.count()
258  ? sortable.at(i).second
259  : unsortable.at(i - sortable.count()));
260  for (int c = 0; c < columnCount(); ++c) {
261  QStandardItem *itm = q->child(r, c);
262  sorted_children[childIndex(i, c)] = itm;
263  if (model) {
264  QModelIndex from = model->createIndex(r, c, q);
265  if (model->d_func()->persistent.indexes.contains(from)) {
266  QModelIndex to = model->createIndex(i, c, q);
267  changedPersistentIndexesFrom.append(from);
268  changedPersistentIndexesTo.append(to);
269  }
270  }
271  }
272  }
273 
274  children = sorted_children;
275 
276  if (model) {
277  model->changePersistentIndexList(changedPersistentIndexesFrom, changedPersistentIndexesTo);
278  }
279 
281  for (it = children.begin(); it != children.end(); ++it) {
282  if (*it)
283  (*it)->d_func()->sortChildren(column, order);
284  }
285 }
unsigned char c[8]
Definition: qnumeric_p.h:62
#define it(className, varName)
int count(const T &t) const
Returns the number of occurrences of value in the vector.
Definition: qvector.h:742
QModelIndex createIndex(int row, int column, void *data=0) const
Creates a model index for the given row and column with the internal pointer ptr. ...
QVector< QStandardItem * > children
The QVector class is a template class that provides a dynamic array.
Definition: qdatastream.h:64
int childIndex(int row, int column) const
void changePersistentIndexList(const QModelIndexList &from, const QModelIndexList &to)
Changes the QPersistentModelIndexes that is equal to the indexes in the given from model index list t...
iterator end()
Returns an STL-style iterator pointing to the imaginary item after the last item in the vector...
Definition: qvector.h:250
#define Q_Q(Class)
Definition: qglobal.h:2483
void append(const T &t)
Inserts value at the end of the vector.
Definition: qvector.h:573
QStandardItemModel * model
const T & at(int i) const
Returns the item at index position i in the vector.
Definition: qvector.h:350
void qStableSort(RandomAccessIterator start, RandomAccessIterator end)
Definition: qalgorithms.h:202
iterator begin()
Returns an STL-style iterator pointing to the first item in the vector.
Definition: qvector.h:247
The QModelIndex class is used to locate data in a data model.
void reserve(int size)
Attempts to allocate memory for at least size elements.
Definition: qvector.h:339
The QStandardItem class provides an item for use with the QStandardItemModel class.
The QTableWidgetItem class provides an item for use with the QTableWidget class.
Definition: qtablewidget.h:82
QStandardItem * child(int row, int column=0) const
Returns the child item at (row, column) if one has been set; otherwise returns 0. ...

Properties

◆ children

QVector<QStandardItem*> QStandardItemPrivate::children

Definition at line 130 of file qstandarditemmodel_p.h.

Referenced by childIndex(), and QStandardItemModel::mimeData().

◆ columns

int QStandardItemPrivate::columns

Definition at line 132 of file qstandarditemmodel_p.h.

Referenced by columnCount().

◆ lastIndexOf

int QStandardItemPrivate::lastIndexOf

Definition at line 136 of file qstandarditemmodel_p.h.

Referenced by childIndex().

◆ model

QStandardItemModel* QStandardItemPrivate::model

Definition at line 127 of file qstandarditemmodel_p.h.

◆ parent

QStandardItem* QStandardItemPrivate::parent

◆ q_ptr

QStandardItem* QStandardItemPrivate::q_ptr

Definition at line 134 of file qstandarditemmodel_p.h.

◆ rows

int QStandardItemPrivate::rows

Definition at line 131 of file qstandarditemmodel_p.h.

Referenced by rowCount().

◆ values

QVector<QWidgetItemData> QStandardItemPrivate::values

Definition at line 129 of file qstandarditemmodel_p.h.


The documentation for this class was generated from the following files: