From b5a02e50aa94c10d2c9f2062af6b4e8d9cfb9294 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Sun, 23 Feb 2014 15:28:31 -0800 Subject: New profile: create new class for DiveHeartrateItem This allows us to give it a different color (red) and make it a smaller size. While implementing this I also fixed the size of the temperature text in the new profile. Signed-off-by: Dirk Hohndel --- qt-ui/profile/diveprofileitem.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'qt-ui/profile/diveprofileitem.h') diff --git a/qt-ui/profile/diveprofileitem.h b/qt-ui/profile/diveprofileitem.h index e8bac0421..86ea01c64 100644 --- a/qt-ui/profile/diveprofileitem.h +++ b/qt-ui/profile/diveprofileitem.h @@ -88,6 +88,16 @@ private: void createTextItem(int seconds, int mkelvin); }; +class DiveHeartrateItem : public AbstractProfilePolygonItem { + Q_OBJECT +public: + DiveHeartrateItem(); + virtual void modelDataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight); + virtual void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget); +private: + void createTextItem(int seconds, int hr); +}; + class DiveGasPressureItem : public AbstractProfilePolygonItem{ Q_OBJECT -- cgit v1.2.3-70-g09d2