From 81aafd665a74ff4de206667ba495109f34294dd5 Mon Sep 17 00:00:00 2001 From: Arno Date: Sat, 17 Mar 2012 06:15:56 +0100 Subject: Make background color of PictureViewer2 configurable Add options to ConfigurationDialog to either use a fixed color as background or a gradient picked with random colors picked from the picture. --- pictureviewer2.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'pictureviewer2.h') diff --git a/pictureviewer2.h b/pictureviewer2.h index d5d80a4..e93dffc 100644 --- a/pictureviewer2.h +++ b/pictureviewer2.h @@ -36,6 +36,7 @@ class PictureViewer2 : public QGraphicsView { void next(); void previous(); void slide(); + void readSettings(); protected: virtual void wheelEvent(QWheelEvent *event); @@ -47,7 +48,7 @@ class PictureViewer2 : public QGraphicsView { private: void setupDialog(); - void setCurPalette(const QPixmap &pic); + void setGradient(const QPixmap &pic); QString constructWindowTitle() const; PicDataList mFiles; QGraphicsScene *mScene; @@ -57,6 +58,8 @@ class PictureViewer2 : public QGraphicsView { QTimer *mSlideTimer; const QString mDefaultFile; PictureViewer2FileinfoItem *mFnItem; + bool mUseGradient; + QColor mBgColor; }; class PictureViewer2FileinfoItem : public QGraphicsItem { -- cgit v1.2.3-70-g09d2