Eneboo - Documentación para desarrolladores
src/qt/include/qcommonstyle.h
Ir a la documentación de este archivo.
00001 /****************************************************************************
00002 ** $Id: qt/qcommonstyle.h   3.3.8   edited Jan 11 14:38 $
00003 **
00004 ** Definition of QCommonStyle class
00005 **
00006 ** Created : 980616
00007 **
00008 ** Copyright (C) 1992-2007 Trolltech ASA.  All rights reserved.
00009 **
00010 ** This file is part of the widgets module of the Qt GUI Toolkit.
00011 **
00012 ** This file may be distributed under the terms of the Q Public License
00013 ** as defined by Trolltech ASA of Norway and appearing in the file
00014 ** LICENSE.QPL included in the packaging of this file.
00015 **
00016 ** This file may be distributed and/or modified under the terms of the
00017 ** GNU General Public License version 2 as published by the Free Software
00018 ** Foundation and appearing in the file LICENSE.GPL included in the
00019 ** packaging of this file.
00020 **
00021 ** Licensees holding valid Qt Enterprise Edition or Qt Professional Edition
00022 ** licenses may use this file in accordance with the Qt Commercial License
00023 ** Agreement provided with the Software.
00024 **
00025 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
00026 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
00027 **
00028 ** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for
00029 **   information about Qt Commercial License Agreements.
00030 ** See http://www.trolltech.com/qpl/ for QPL licensing information.
00031 ** See http://www.trolltech.com/gpl/ for GPL licensing information.
00032 **
00033 ** Contact info@trolltech.com if any conditions of this licensing are
00034 ** not clear to you.
00035 **
00036 **********************************************************************/
00037 
00038 #ifndef QCOMMONSTYLE_H
00039 #define QCOMMONSTYLE_H
00040 
00041 #ifndef QT_H
00042 #include "qstyle.h"
00043 #endif // QT_H
00044 
00045 #ifndef QT_NO_STYLE
00046 
00047 class Q_EXPORT QCommonStyle: public QStyle
00048 {
00049     Q_OBJECT
00050 
00051 public:
00052     QCommonStyle();
00053     ~QCommonStyle();
00054 
00055     void drawPrimitive( PrimitiveElement pe,
00056                         QPainter *p,
00057                         const QRect &r,
00058                         const QColorGroup &cg,
00059                         SFlags flags = Style_Default,
00060                         const QStyleOption& = QStyleOption::Default ) const;
00061 
00062     void drawControl( ControlElement element,
00063                       QPainter *p,
00064                       const QWidget *widget,
00065                       const QRect &r,
00066                       const QColorGroup &cg,
00067                       SFlags how = Style_Default,
00068                       const QStyleOption& = QStyleOption::Default ) const;
00069 
00070     void drawControlMask( ControlElement element,
00071                           QPainter *p,
00072                           const QWidget *widget,
00073                           const QRect &r,
00074                           const QStyleOption& = QStyleOption::Default ) const;
00075 
00076     QRect subRect( SubRect r, const QWidget *widget ) const;
00077 
00078     void drawComplexControl( ComplexControl control,
00079                              QPainter *p,
00080                              const QWidget *widget,
00081                              const QRect &r,
00082                              const QColorGroup &cg,
00083                              SFlags how = Style_Default,
00084 #ifdef Q_QDOC
00085                              SCFlags sub = SC_All,
00086 #else
00087                              SCFlags sub = (uint)SC_All,
00088 #endif
00089                              SCFlags subActive = SC_None,
00090                              const QStyleOption& = QStyleOption::Default ) const;
00091 
00092     void drawComplexControlMask( ComplexControl control,
00093                                  QPainter *p,
00094                                  const QWidget *widget,
00095                                  const QRect &r,
00096                                  const QStyleOption& = QStyleOption::Default ) const;
00097 
00098     QRect querySubControlMetrics( ComplexControl control,
00099                                   const QWidget *widget,
00100                                   SubControl sc,
00101                                   const QStyleOption& = QStyleOption::Default ) const;
00102 
00103     SubControl querySubControl( ComplexControl control,
00104                                 const QWidget *widget,
00105                                 const QPoint &pos,
00106                                 const QStyleOption& = QStyleOption::Default ) const;
00107 
00108     int pixelMetric( PixelMetric m, const QWidget *widget = 0 ) const;
00109 
00110     QSize sizeFromContents( ContentsType s,
00111                             const QWidget *widget,
00112                             const QSize &contentsSize,
00113                             const QStyleOption& = QStyleOption::Default ) const;
00114 
00115     int styleHint(StyleHint sh, const QWidget *, const QStyleOption &, QStyleHintReturn *) const;
00116 
00117     QPixmap stylePixmap( StylePixmap sp,
00118                          const QWidget *widget = 0,
00119                          const QStyleOption& = QStyleOption::Default ) const;
00120 
00121 
00122 private:
00123     // Disabled copy constructor and operator=
00124 #if defined(Q_DISABLE_COPY)
00125     QCommonStyle( const QCommonStyle & );
00126     QCommonStyle &operator=( const QCommonStyle & );
00127 #endif
00128 };
00129 
00130 
00131 
00132 #endif // QT_NO_STYLE
00133 
00134 #endif // QCOMMONSTYLE_H
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'