00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef METAL_H
00016 #define METAL_H
00017
00018 #include <qwindowsstyle.h>
00019 #include <qpalette.h>
00020
00021 class MetalStyle : public QWindowsStyle
00022 {
00023 public:
00024 MetalStyle();
00025 void polish( QApplication*);
00026 void unPolish( QApplication*);
00027 void polish( QWidget* );
00028 void unPolish( QWidget* );
00029
00030
00031 void drawMetalButton( QPainter *p, int x, int y, int w, int h,
00032 bool sunken = FALSE, bool horz = TRUE );
00033
00034
00035 void drawButton( QPainter *p, int x, int y, int w, int h,
00036 const QColorGroup &g, bool sunken = FALSE,
00037 const QBrush *fill = 0 );
00038 void drawBevelButton( QPainter *p, int x, int y, int w, int h,
00039 const QColorGroup &g, bool sunken = FALSE,
00040 const QBrush *fill = 0 );
00041
00042 void drawPushButton( QPushButton* btn, QPainter *p);
00043 void drawPushButtonLabel( QPushButton* btn, QPainter *p);
00044 void drawPanel( QPainter *p, int x, int y, int w, int h,
00045 const QColorGroup &, bool sunken,
00046 int lineWidth, const QBrush *fill );
00047
00048
00049 void drawSlider( QPainter *p,
00050 int x, int y, int w, int h,
00051 const QColorGroup &g,
00052 Orientation orient, bool tickAbove, bool tickBelow );
00053
00054 void drawScrollBarControls( QPainter* p, const QScrollBar* sb,
00055 int sliderStart, uint controls,
00056 uint activeControl );
00057
00058
00059 void drawComboButton( QPainter *p, int x, int y, int w, int h,
00060 const QColorGroup &g, bool sunken = FALSE,
00061 bool editable = FALSE,
00062 bool enabled = TRUE,
00063 const QBrush *fill = 0 );
00064
00065 private:
00066 QPalette oldPalette;
00067 };
00068
00069 #endif