diff options
author | J-P Nurmi <jpnurmi@digia.com> | 2012-11-26 13:24:12 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-11-26 17:33:37 +0100 |
commit | 5a0fd7fb04af6e9e6d16e9647756ee05441fc245 (patch) | |
tree | 178ec0307047cf67cd2b429f4980c0b4cf748665 /examples/widgets/widgets/styles/norwegianwoodstyle.h | |
parent | cd765bbae07310b29c8d0f0275fdc3c7f0696472 (diff) |
Examples: inherit NorwegianWoodStyle from QProxyStyle
The QStyle specializations are being made internal. The recommended way
to customize styles is now to use QProxyStyle (& QStyleFactory), or to
implement a full custom style one can alternatively subclass
QCommonStyle. The proxy style approach was chosen for this case, since
the example assumes some drawing functionality provided by the windows
style and it is not a "complete" custom style implementation but more
like a customization anyway.
Change-Id: Ib2477339cfef258cfc944a76a2eea728066e1f45
Reviewed-by: Geir Vattekar <geir.vattekar@digia.com>
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
Diffstat (limited to 'examples/widgets/widgets/styles/norwegianwoodstyle.h')
-rw-r--r-- | examples/widgets/widgets/styles/norwegianwoodstyle.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/widgets/widgets/styles/norwegianwoodstyle.h b/examples/widgets/widgets/styles/norwegianwoodstyle.h index 84ace3b7a8..e8bb0fb096 100644 --- a/examples/widgets/widgets/styles/norwegianwoodstyle.h +++ b/examples/widgets/widgets/styles/norwegianwoodstyle.h @@ -41,7 +41,7 @@ #ifndef NORWEGIANWOODSTYLE_H #define NORWEGIANWOODSTYLE_H -#include <QWindowsStyle> +#include <QProxyStyle> #include <QPalette> QT_BEGIN_NAMESPACE @@ -49,12 +49,12 @@ class QPainterPath; QT_END_NAMESPACE //! [0] -class NorwegianWoodStyle : public QWindowsStyle +class NorwegianWoodStyle : public QProxyStyle { Q_OBJECT public: - NorwegianWoodStyle() {} + NorwegianWoodStyle(); void polish(QPalette &palette); void polish(QWidget *widget); |