summaryrefslogtreecommitdiffstats
path: root/qt-ui/modeldelegates.h
diff options
context:
space:
mode:
authorGravatar Giuseppe Bilotta <giuseppe.bilotta@gmail.com>2014-10-15 15:30:49 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-10-18 15:16:03 -0700
commitf18bcd66072c115456d98a8aeb87500b2ca8e642 (patch)
tree6639ddf1c43a4499e020c4821657d24aa3d87e68 /qt-ui/modeldelegates.h
parent10351b34955a2a008269e489acde9bc084e3aa43 (diff)
downloadsubsurface-f18bcd66072c115456d98a8aeb87500b2ca8e642.tar.gz
Dynamic dive trip list column widths
Compute the default widths for the columns in the dive trip list from their header and (expected) content length rather than some fixed pixel sizes. Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/modeldelegates.h')
-rw-r--r--qt-ui/modeldelegates.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/qt-ui/modeldelegates.h b/qt-ui/modeldelegates.h
index bc5dd3fcd..94ffe0868 100644
--- a/qt-ui/modeldelegates.h
+++ b/qt-ui/modeldelegates.h
@@ -20,9 +20,11 @@ public:
explicit StarWidgetsDelegate(QWidget *parent = 0);
virtual void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const;
virtual QSize sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const;
+ const QSize& starSize() const;
private:
QWidget *parentWidget;
+ QSize minStarSize;
};
class ComboBoxDelegate : public QStyledItemDelegate {