aboutsummaryrefslogtreecommitdiffstats
path: root/qt-ui/models.cpp
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tcanabrava@kde.org>2013-11-14 17:43:28 -0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2013-11-15 09:21:05 +0900
commita07c3d62afe446df4eb6d185a201c235bfe2c64a (patch)
tree304c1aec47745ab3c2eb939ebec531144942522d /qt-ui/models.cpp
parent96d5687ab89edd7163493faf212ddcb119e93d8c (diff)
downloadsubsurface-a07c3d62afe446df4eb6d185a201c235bfe2c64a.tar.gz
Use the correct font for the Air Types Model.
The air types model had a font bigger than the other models, this patch creates a data() method that correctly delivers the correct font. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/models.cpp')
-rw-r--r--qt-ui/models.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/qt-ui/models.cpp b/qt-ui/models.cpp
index bb623243e..14c3cb5ea 100644
--- a/qt-ui/models.cpp
+++ b/qt-ui/models.cpp
@@ -1683,3 +1683,11 @@ void GasSelectionModel::repopulate()
{
setStringList(DivePlannerPointsModel::instance()->getGasList());
}
+
+QVariant GasSelectionModel::data(const QModelIndex& index, int role) const
+{
+ if(role == Qt::FontRole){
+ return defaultModelFont();
+ }
+ return QStringListModel::data(index, role);
+}