00001
00002
00003
00004
00005 #ifndef QLookAndFeel_h
00006 #define QLookAndFeel_h
00007
00008
00009
00010 class QLookAndFeel;
00011
00012
00013
00014 #include "QColor.h"
00015 #include "QFont.h"
00016
00017 enum QBevelState {bsUp, bsDown, bsDisabled };
00018
00019
00020
00021 class QLookAndFeel
00022 {
00023 private:
00024
00025 unsigned int CheckBoxTexID;
00026
00027
00028 unsigned int CheckBoxCheckedTexID;
00029
00030
00031 unsigned int RadioButtonCheckedTexID;
00032
00033
00034 unsigned int RadioButtonTexID;
00035
00036
00037 unsigned int CloseButtonTexID;
00038
00039
00040 unsigned int CloseButtonDownTexID;
00041
00042
00043 unsigned int MaximizeButtonTexID;
00044
00045
00046 unsigned int MaximizeButtonDownTexID;
00047
00048
00049 unsigned int RestoreButtonTexID;
00050
00051
00052 unsigned int RestoreButtonDownTexID;
00053
00054
00055 unsigned int MinimizeButtonTexID;
00056
00057
00058 unsigned int MinimizeButtonDownTexID;
00059
00060 protected:
00061
00062 QColor* BackGroundColor;
00063
00064
00065 QColor* DisabledColor;
00066
00067
00068 QColor* BevelRaisedColor;
00069
00070
00071 QColor* BevelLoweredColor;
00072
00073
00074 QColor* BevelDisabledColor;
00075
00076
00077 QColor* HighlightColor;
00078
00079
00080 QFont* Font;
00081
00082 public:
00083
00084 void drawBevel( float x , float y , float w , float h , QBevelState state );
00085
00086
00087 void drawRect( float x , float y , float w , float h );
00088
00089
00090 void drawTexture( unsigned int texID , int width , int height );
00091
00092
00093 void drawCheckBox( bool checked );
00094
00095
00096 void drawRadioButton( bool checked );
00097
00098
00099 void drawCloseButton( bool down , int width , int height );
00100
00101
00102 void drawMaximizeButton( bool down , int width , int height );
00103
00104
00105 virtual void Init();
00106
00107
00108 virtual void CleanUp();
00109
00110
00111 QColor* getBackGroundColor();
00112
00113
00114 QColor* getDisabledColor();
00115
00116
00117 QColor* getBevelRaisedColor();
00118
00119
00120 QColor* getBevelLoweredColor();
00121
00122
00123 QColor* getBevelDisabledColor();
00124
00125
00126 QColor* getHighlightColor();
00127
00128
00129 QFont* getFont();
00130
00131
00132 void print();
00133
00134
00135 QLookAndFeel( );
00136
00137
00138 virtual ~QLookAndFeel();
00139
00140
00141 };
00142 #endif
00143