25#ifndef QPROPERTYMODEL_H_
26#define QPROPERTYMODEL_H_
28#include <qabstractitemmodel.h>
31#include "QPropertyEditorWidget.h"
51 QModelIndex
index (
int row,
int column,
const QModelIndex &
parent = QModelIndex() )
const;
60 QVariant
data (
const QModelIndex &
index,
int role = Qt::DisplayRole )
const;
63 bool setData (
const QModelIndex &
index,
const QVariant & value,
int role = Qt::EditRole );
68 QVariant
headerData (
int section, Qt::Orientation orientation,
int role = Qt::DisplayRole )
const;
86 void updateItem ( QObject* propertyObject,
const QModelIndex&
parent = QModelIndex() ) ;
103 void setSorted(
bool value);
105 bool sorted()
const {
return m_sorted; }
Definition QPropertyModel.h:39
void registerCustomPropertyCB(QPropertyEditorWidget::UserTypeCB callback)
QList< QPropertyEditorWidget::UserTypeCB > m_userCallbacks
Custom callback.
Definition QPropertyModel.h:120
void addItem(QObject *propertyObject)
int columnCount(const QModelIndex &parent=QModelIndex()) const
QAbstractItemModel implementation.
QModelIndex buddy(const QModelIndex &index) const
QAbstractItemModel implementation.
int rowCount(const QModelIndex &parent=QModelIndex()) const
QAbstractItemModel implementation.
Property * m_rootItem
The Root Property for all objects.
Definition QPropertyModel.h:117
bool setData(const QModelIndex &index, const QVariant &value, int role=Qt::EditRole)
QAbstractItemModel implementation.
virtual ~QPropertyModel()
Destructor.
void addDynamicProperties(Property *parent, QObject *propertyObject)
Adds dynamic properties to the model.
QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const
QAbstractItemModel implementation.
void updateItem(QObject *propertyObject, const QModelIndex &parent=QModelIndex())
QModelIndex parent(const QModelIndex &index) const
QAbstractItemModel implementation.
Definition QPropertyModel.cpp:106
QModelIndex index(int row, int column, const QModelIndex &parent=QModelIndex()) const
QAbstractItemModel implementation.
void unregisterCustomPropertyCB(QPropertyEditorWidget::UserTypeCB callback)
Qt::ItemFlags flags(const QModelIndex &index) const
QAbstractItemModel implementation.
QVariant headerData(int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const
QAbstractItemModel implementation.
QPropertyModel(QObject *parent=0)