Delegate for rendering and editing QVariant property values.
More...
#include <propertyeditordelegate.h>
|
| PropertyEditorDelegate (QObject *parent) |
|
QString | displayText (const QVariant &value, const QLocale &locale) const override |
|
bool | editorEvent (QEvent *event, QAbstractItemModel *model, const QStyleOptionViewItem &option, const QModelIndex &index) override |
|
void | paint (QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const override |
|
void | setEditorData (QWidget *editor, const QModelIndex &index) const override |
|
QSize | sizeHint (const QStyleOptionViewItem &option, const QModelIndex &index) const override |
|
Delegate for rendering and editing QVariant property values.
Compared to the built-in functionality this provides support for additional types, such as:
- rendering of vector and matrix types in their mathematical form
- editing of flags and enums resolved via EnumRepository
- editing support mathematical types, palettes, fonts, colors, etc.
It's recommended to use this on any cell containing target-provided QVariants, no matter whether it's read-only or read-write.