FACT++  1.0
HtmlDelegate.h
Go to the documentation of this file.
1 #ifndef FACT_HtmlDelegate
2 #define FACT_HtmlDelegate
3 
4 #include <QStyledItemDelegate>
5 
6 class HtmlDelegate : public QStyledItemDelegate
7 {
8 public:
9  HtmlDelegate(QObject *p=0) : QStyledItemDelegate(p)
10  {
11  }
12 
13  void paint(QPainter *painter,
14  const QStyleOptionViewItem &option,
15  const QModelIndex &index) const;
16 
17  QSize sizeHint(const QStyleOptionViewItem &option,
18  const QModelIndex &index) const;
19 };
20 
21 #endif
void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const
Definition: HtmlDelegate.cc:13
A Qt-Delegate to display HTML text (QTextDocument) in a list.
Definition: HtmlDelegate.h:6
HtmlDelegate(QObject *p=0)
Definition: HtmlDelegate.h:9
QSize sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const
Definition: HtmlDelegate.cc:30