Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
QmitkDoseColorDelegate.h
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 #ifndef QmitkDoseColorDelegate_h
18 #define QmitkDoseColorDelegate_h
19 
20 
21 #include <QStyledItemDelegate>
22 
23 #include "MitkRTUIExports.h"
24 
27 class MITKRTUI_EXPORT QmitkDoseColorDelegate : public QStyledItemDelegate
28 {
29  Q_OBJECT
30 
31 public:
35  QmitkDoseColorDelegate(QObject *parent = 0);
36 
37  bool editorEvent(QEvent *event, QAbstractItemModel *model, const QStyleOptionViewItem &option,
38  const QModelIndex &index);
39 
40  void paint(QPainter *painter, const QStyleOptionViewItem &option,
41  const QModelIndex &index) const;
42 };
43 
44 #endif
An item delegate for rendering and editing dose color in a QTableView.
#define MITKRTUI_EXPORT