Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
An item delegate for rendering and editing dose values. The delegate assumes that the model uses the role Qt::UserRole+1 to indicate if the returned dose value is an absolute (data(Qt::UserRole+1) == true) or an relative dose (data(Qt::UserRole+1) == false). More...
#include <QmitkDoseValueDelegate.h>
Public Member Functions | |
QmitkDoseValueDelegate (QObject *parent=0) | |
void | paint (QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const |
QWidget * | createEditor (QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index) const |
void | setEditorData (QWidget *editor, const QModelIndex &index) const |
void | setModelData (QWidget *editor, QAbstractItemModel *model, const QModelIndex &index) const |
An item delegate for rendering and editing dose values. The delegate assumes that the model uses the role Qt::UserRole+1 to indicate if the returned dose value is an absolute (data(Qt::UserRole+1) == true) or an relative dose (data(Qt::UserRole+1) == false).
Definition at line 30 of file QmitkDoseValueDelegate.h.
QmitkDoseValueDelegate::QmitkDoseValueDelegate | ( | QObject * | parent = 0 | ) |
Creates a new PropertyDelegate.
Definition at line 24 of file QmitkDoseValueDelegate.cpp.
QWidget * QmitkDoseValueDelegate::createEditor | ( | QWidget * | parent, |
const QStyleOptionViewItem & | option, | ||
const QModelIndex & | index | ||
) | const |
Create an editor for a specific property (overwritten from QItemDelegate)
Definition at line 42 of file QmitkDoseValueDelegate.cpp.
void QmitkDoseValueDelegate::paint | ( | QPainter * | painter, |
const QStyleOptionViewItem & | option, | ||
const QModelIndex & | index | ||
) | const |
Renders a specific property (overwritten from QItemDelegate)
Definition at line 28 of file QmitkDoseValueDelegate.cpp.
void QmitkDoseValueDelegate::setEditorData | ( | QWidget * | editor, |
const QModelIndex & | index | ||
) | const |
Create an editor for a specific property (overwritten from QItemDelegate)
Definition at line 77 of file QmitkDoseValueDelegate.cpp.
void QmitkDoseValueDelegate::setModelData | ( | QWidget * | editor, |
QAbstractItemModel * | model, | ||
const QModelIndex & | index | ||
) | const |
When the user accepts input this func commits the data to the model (overwritten from QItemDelegate)
Definition at line 96 of file QmitkDoseValueDelegate.cpp.