Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

/Go4QtBaseWidgets/metal.h

Go to the documentation of this file.
00001 //---------------------------------------------------------------
00002 //        Go4 Release Package v2.10-5 (build 21005) 
00003 //                      03-Nov-2005
00004 //---------------------------------------------------------------
00005 //       The GSI Online Offline Object Oriented (Go4) Project
00006 //       Experiment Data Processing at DVEE department, GSI
00007 //---------------------------------------------------------------
00008 //
00009 //Copyright (C) 2000- Gesellschaft f. Schwerionenforschung, GSI
00010 //                    Planckstr. 1, 64291 Darmstadt, Germany
00011 //Contact:            http://go4.gsi.de
00012 //----------------------------------------------------------------
00013 //This software can be used under the license agreements as stated
00014 //in Go4License.txt file which is part of the distribution.
00015 //----------------------------------------------------------------
00016 /****************************************************************************
00017 ** $Id: metal.h,v 1.5 2004/10/04 10:33:55 linev Exp $
00018 **
00019 ** Definition of the Metal Style for the themes example
00020 **
00021 ** Created : 979899
00022 **
00023 ** Copyright (C) 1997 by Trolltech AS.  All rights reserved.
00024 **
00025 ** This file is part of an example program for Qt.  This example
00026 ** program may be used, distributed and modified without limitation.
00027 **
00028 *****************************************************************************/
00029 
00030 #ifndef METAL_H
00031 #define METAL_H
00032 
00033 #include "qwindowsstyle.h"
00034 #include "qpalette.h"
00035 
00036 #ifndef QT_NO_STYLE_WINDOWS
00037 
00038 class MetalStyle : public QWindowsStyle
00039 {
00040 public:
00041     MetalStyle();
00042     void polish( QApplication*);
00043     void unPolish( QApplication*);
00044     void polish( QWidget* );
00045     void unPolish( QWidget* );
00046 
00047     void drawPrimitive( PrimitiveElement pe,
00048          QPainter *p,
00049          const QRect &r,
00050          const QColorGroup &cg,
00051          SFlags flags = Style_Default,
00052          const QStyleOption& = QStyleOption::Default) const;
00053 
00054     void drawControl( ControlElement element,
00055             QPainter *p,
00056             const QWidget *widget,
00057             const QRect &r,
00058             const QColorGroup &cg,
00059             SFlags how = Style_Default,
00060             const QStyleOption& = QStyleOption::Default ) const;
00061 
00062     void drawComplexControl( ComplexControl cc,
00063               QPainter *p,
00064               const QWidget *widget,
00065               const QRect &r,
00066               const QColorGroup &cg,
00067               SFlags how = Style_Default,
00068               SCFlags sub = SC_All,
00069               SCFlags subActive = SC_None,
00070               const QStyleOption& = QStyleOption::Default ) const;
00071     int pixelMetric( PixelMetric, const QWidget * ) const;
00072 
00073 
00074 private:
00075     void drawMetalFrame(  QPainter *p, int x, int y, int w, int h ) const;
00076     void drawMetalGradient( QPainter *p, int x, int y, int w, int h,
00077            bool sunken, bool horz, bool flat=FALSE ) const;
00078     void drawMetalButton( QPainter *p, int x, int y, int w, int h,
00079            bool sunken, bool horz, bool flat=FALSE ) const;
00080     QPalette oldPalette;
00081 };
00082 
00083 #endif
00084 
00085 #endif
00086 
00087 
00088 
00089 
00090 //----------------------------END OF GO4 SOURCE FILE ---------------------

Generated on Tue Nov 8 10:56:04 2005 for Go4-v2.10-5 by doxygen1.2.15