summaryrefslogtreecommitdiffstats
path: root/examples/themes/wood.h
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2012-08-09 15:32:06 -0500
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2012-08-09 15:32:06 -0500
commitd24053184c51974368634902f1c0e862c811098b (patch)
treeb7429f5319e15d2db2fb056e223c84ad0e05df89 /examples/themes/wood.h
parent8805afa8c607ac6028207434f78a7cd90a9df64b (diff)
downloadqt3-d24053184c51974368634902f1c0e862c811098b.tar.gz
qt3-d24053184c51974368634902f1c0e862c811098b.zip
Update example styles to new style API
Diffstat (limited to 'examples/themes/wood.h')
-rw-r--r--examples/themes/wood.h44
1 files changed, 28 insertions, 16 deletions
diff --git a/examples/themes/wood.h b/examples/themes/wood.h
index 56ce8f5..3d7b0e6 100644
--- a/examples/themes/wood.h
+++ b/examples/themes/wood.h
@@ -26,13 +26,15 @@ class NorwegianWoodStyle : public QWindowsStyle
{
public:
NorwegianWoodStyle();
- void polish( QApplication*);
- void polish( QWidget* );
- void unPolish( QWidget* );
- void unPolish( QApplication*);
+ void applicationPolish( QStyleControlElementData ceData, ControlElementFlags elementFlags, void * );
+ void polish( QStyleControlElementData ceData, ControlElementFlags elementFlags, void * );
+ void unPolish( QStyleControlElementData ceData, ControlElementFlags elementFlags, void * );
+ void applicationUnPolish( QStyleControlElementData ceData, ControlElementFlags elementFlags, void * );
void drawPrimitive( PrimitiveElement pe,
QPainter *p,
+ QStyleControlElementData ceData,
+ ControlElementFlags elementFlags,
const QRect &r,
const QColorGroup &cg,
SFlags flags = Style_Default,
@@ -40,44 +42,54 @@ public:
void drawControl( ControlElement element,
QPainter *p,
- const QWidget *widget,
+ QStyleControlElementData ceData,
+ ControlElementFlags elementFlags,
const QRect &r,
const QColorGroup &cg,
SFlags how = Style_Default,
- const QStyleOption& = QStyleOption::Default ) const;
+ const QStyleOption& = QStyleOption::Default,
+ const QWidget *widget = 0 ) const;
void drawControlMask( ControlElement element,
QPainter *p,
- const QWidget *widget,
+ QStyleControlElementData ceData,
+ ControlElementFlags elementFlags,
const QRect &r,
- const QStyleOption& = QStyleOption::Default ) const;
+ const QStyleOption& = QStyleOption::Default,
+ const QWidget *widget = 0 ) const;
void drawComplexControl( ComplexControl cc,
QPainter *p,
- const QWidget *widget,
+ QStyleControlElementData ceData,
+ ControlElementFlags elementFlags,
const QRect &r,
const QColorGroup &cg,
SFlags how = Style_Default,
SCFlags sub = SC_All,
SCFlags subActive = SC_None,
- const QStyleOption& = QStyleOption::Default ) const;
+ const QStyleOption& = QStyleOption::Default,
+ const QWidget *widget = 0 ) const;
void drawComplexControlMask( ComplexControl control,
QPainter *p,
- const QWidget *widget,
+ const QStyleControlElementData ceData,
+ const ControlElementFlags elementFlags,
const QRect &r,
- const QStyleOption& = QStyleOption::Default ) const;
+ const QStyleOption& = QStyleOption::Default,
+ const QWidget *widget = 0 ) const;
QRect querySubControlMetrics( ComplexControl control,
- const QWidget *widget,
+ QStyleControlElementData ceData,
+ ControlElementFlags elementFlags,
SubControl sc,
- const QStyleOption& = QStyleOption::Default ) const;
+ const QStyleOption& = QStyleOption::Default,
+ const QWidget *widget = 0 ) const;
- QRect subRect( SubRect r, const QWidget *widget ) const;
+ QRect subRect( SubRect r, const QStyleControlElementData ceData, const ControlElementFlags elementFlags, const QWidget *widget ) const;
private:
- void drawSemicircleButton(QPainter *p, const QRect &r, int dir,
+ void drawSemicircleButton(QPainter *p, QStyleControlElementData ceData, ControlElementFlags elementFlags, const QRect &r, int dir,
bool sunken, const QColorGroup &g ) const;
QPalette oldPalette;
QPixmap *sunkenDark;