Main Page   Namespace List   Class Hierarchy   Alphabetical List   Data Structures   File List   Data Fields   Globals  

/cygdrive/d/Eigene Dateien/!DProcs/code_gen/QLookAndFeel.h

Go to the documentation of this file.
00001 // Class QLookAndFeel 
00002 // Filename QLookAndFeel.h 
00003 // FaPra 2003-2004, A5, Alexander Kramer
00004 
00005 #ifndef QLookAndFeel_h 
00006 #define QLookAndFeel_h 
00007 
00008 
00009 //! Pre-declaration of QLookAndFeel
00010 class QLookAndFeel;
00011 
00012 
00013 //! enumeration of bevel states
00014 enum QBevelState {bsUp, bsDown, bsDisabled };
00015 
00016 #include "QColor.h"
00017 #include "QFont.h"
00018 
00019 //! Defines Look and Feel. Colors, Textures, default Font size and so on.
00020 class QLookAndFeel
00021 {
00022 private:
00023 //! id for checkbox texture
00024 unsigned int CheckBoxTexID;
00025 
00026 //! id for checkbox texture
00027 unsigned int CheckBoxCheckedTexID;
00028 
00029 //! id for radio button checked texture
00030 unsigned int RadioButtonCheckedTexID;
00031 
00032 //! id for radio button texture
00033 unsigned int RadioButtonTexID;
00034 
00035 //! id for close button texture
00036 unsigned int CloseButtonTexID;
00037 
00038 //! id for close button down texture
00039 unsigned int CloseButtonDownTexID;
00040 
00041 //! id for maximize button texture
00042 unsigned int MaximizeButtonTexID;
00043 
00044 //! id for maximize button down texture
00045 unsigned int MaximizeButtonDownTexID;
00046 
00047 //! id for restore button texture
00048 unsigned int RestoreButtonTexID;
00049 
00050 //! id for restore button down texture
00051 unsigned int RestoreButtonDownTexID;
00052 
00053 //! id for miniimize button texture
00054 unsigned int MinimizeButtonTexID;
00055 
00056 //! id for minimize button down texture
00057 unsigned int MinimizeButtonDownTexID;
00058 
00059 protected:
00060 //! back ground color
00061 QColor* BackGroundColor;
00062 
00063 //! color of control if it is disabled
00064 QColor* DisabledColor;
00065 
00066 //! color of the raised side of a bevel
00067 QColor* BevelRaisedColor;
00068 
00069 //! color of the lowered side of a bevel
00070 QColor* BevelLoweredColor;
00071 
00072 //! color of the side of a disabled bevel
00073 QColor* BevelDisabledColor;
00074 
00075 //! highlighted color
00076 QColor* HighlightColor;
00077 
00078 //! reference font
00079 QFont* Font;
00080 
00081 public:
00082 //! draws bevel from x,y-x+w,y+h. State : up,down,disabled
00083  void drawBevel( float  x , float  y , float  w , float  h , QBevelState  state );
00084 
00085 //! draws bevel from x,y-x+w,y+h. State : up,down,disabled
00086  void drawRect( float  x , float  y , float  w , float  h );
00087 
00088 //! draws given texture with given size
00089  void drawTexture( unsigned  int  texID , int  width , int  height );
00090 
00091 //! draws checkbox texture
00092  void drawCheckBox( bool  checked );
00093 
00094 //! draws radio button texture
00095  void drawRadioButton( bool  checked );
00096 
00097 //! draws close button texture
00098  void drawCloseButton( bool  down , int  width , int  height );
00099 
00100 //! draws maximize button texture
00101  void drawMaximizeButton( bool  down , int  width , int  height );
00102 
00103 //! initialization code
00104 virtual void Init();
00105 
00106 //! clean up code
00107 virtual void CleanUp();
00108 
00109 //! getter method for BackGroundColor
00110  QColor* getBackGroundColor();
00111 
00112 //! getter method for DisabledColor
00113  QColor* getDisabledColor();
00114 
00115 //! getter method for BevelRaisedColor
00116  QColor* getBevelRaisedColor();
00117 
00118 //! getter method for BevelLoweredColor
00119  QColor* getBevelLoweredColor();
00120 
00121 //! getter method for BevelDisabledColor
00122  QColor* getBevelDisabledColor();
00123 
00124 //! getter method for HighlightColor
00125  QColor* getHighlightColor();
00126 
00127 //! getter method for Font
00128  QFont* getFont();
00129 
00130 //! prints itself to the cout
00131  void print();
00132 
00133 //! Constructor
00134   QLookAndFeel(  );
00135 
00136 //! Destructor
00137 virtual  ~QLookAndFeel();
00138 
00139 
00140 };
00141 #endif
00142 

Generated on Thu Mar 18 18:33:48 2004 for miniQT by doxygen1.2.18