RioEngine  0.1
My first attempt to create a 3D WYSIWYG Game Engine
EnumProperty Class Reference

#include <enumproperty.h>

Inheritance diagram for EnumProperty:
Property CObjectTypesEnumProperty

Public Member Functions

 EnumProperty (const QString &name=QString(), QObject *propertyObject=0, QObject *parent=0)
 
virtual QVariant value (int role=Qt::UserRole) const
 
virtual QWidget * createEditor (QWidget *parent, const QStyleOptionViewItem &option)
 
virtual bool setEditorData (QWidget *editor, const QVariant &data)
 
virtual QVariant editorData (QWidget *editor)
 
- Public Member Functions inherited from Property
 Property (const QString &name=QString(), QObject *propertyObject=0, QObject *parent=0)
 
virtual void setValue (const QVariant &value)
 
QObject * propertyObject ()
 
bool isRoot ()
 
bool isReadOnly ()
 
int row ()
 
QString editorHints ()
 
virtual void setEditorHints (const QString &hints)
 
PropertyfindPropertyObject (QObject *propertyObject)
 

Protected Attributes

QStringList m_enum
 
- Protected Attributes inherited from Property
QObject * m_propertyObject
 
QString m_hints
 

Additional Inherited Members

- Signals inherited from Property
void propertyChanged (QObject *, QString, QVariant, QVariant)
 

Detailed Description

The Enum Property Class extends a Property to add enum functionality to the QPropertyEditor. Enum Properties are automatically created in the QPropertyModel for objects that have an enum as property value.

Author
Roman Schmid

Definition at line 41 of file enumproperty.h.

Constructor & Destructor Documentation

EnumProperty::EnumProperty ( const QString &  name = QString(),
QObject *  propertyObject = 0,
QObject *  parent = 0 
)

Definition at line 28 of file enumproperty.cpp.

Member Function Documentation

QWidget * EnumProperty::createEditor ( QWidget *  parent,
const QStyleOptionViewItem &  option 
)
virtual
See also
Property::createEditor

Reimplemented from Property.

Definition at line 68 of file enumproperty.cpp.

QVariant EnumProperty::editorData ( QWidget *  editor)
virtual
See also
Property::editorData

Reimplemented from Property.

Definition at line 104 of file enumproperty.cpp.

bool EnumProperty::setEditorData ( QWidget *  editor,
const QVariant &  data 
)
virtual
See also
Property::setEditorData

Reimplemented from Property.

Definition at line 81 of file enumproperty.cpp.

QVariant EnumProperty::value ( int  role = Qt::UserRole) const
virtual
See also
Property::value

Reimplemented from Property.

Reimplemented in CObjectTypesEnumProperty.

Definition at line 48 of file enumproperty.cpp.

Member Data Documentation

QStringList EnumProperty::m_enum
protected

QStringList with possible enum values

Definition at line 63 of file enumproperty.h.


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