Eneboo - Documentación para desarrolladores
Métodos públicos | Métodos protegidos
Referencia de la Clase QMotifPlusStyle

The QMotifPlusStyle class provides a more sophisticated Motif-ish look and feel. Más...

#include <qmotifplusstyle.h>

Diagrama de herencias de QMotifPlusStyle
QMotifStyle QMotifStyle QCommonStyle QCommonStyle QCommonStyle QCommonStyle QStyle QStyle QStyle QStyle QStyle QStyle QStyle QStyle

Lista de todos los miembros.

Métodos públicos

 QMotifPlusStyle (bool hoveringHighlight=TRUE)
virtual ~QMotifPlusStyle ()
void polish (QPalette &pal)
void polish (QWidget *widget)
void unPolish (QWidget *widget)
void polish (QApplication *app)
void unPolish (QApplication *app)
void drawPrimitive (PrimitiveElement pe, QPainter *p, const QRect &r, const QColorGroup &cg, SFlags flags=Style_Default, const QStyleOption &=QStyleOption::Default) const
void drawControl (ControlElement element, QPainter *p, const QWidget *widget, const QRect &r, const QColorGroup &cg, SFlags how=Style_Default, const QStyleOption &=QStyleOption::Default) const
QRect subRect (SubRect r, const QWidget *widget) const
void drawComplexControl (ComplexControl control, QPainter *p, const QWidget *widget, const QRect &r, const QColorGroup &cg, SFlags how=Style_Default, SCFlags controls=(uint) SC_All, SCFlags active=SC_None, const QStyleOption &=QStyleOption::Default) const
QRect querySubControlMetrics (ComplexControl control, const QWidget *widget, SubControl subcontrol, const QStyleOption &=QStyleOption::Default) const
int pixelMetric (PixelMetric metric, const QWidget *widget=0) const
int styleHint (StyleHint sh, const QWidget *, const QStyleOption &=QStyleOption::Default, QStyleHintReturn *=0) const
 QMotifPlusStyle (bool hoveringHighlight=TRUE)
virtual ~QMotifPlusStyle ()
void polish (QPalette &pal)
void polish (QWidget *widget)
void unPolish (QWidget *widget)
void polish (QApplication *app)
void unPolish (QApplication *app)
void drawPrimitive (PrimitiveElement pe, QPainter *p, const QRect &r, const QColorGroup &cg, SFlags flags=Style_Default, const QStyleOption &=QStyleOption::Default) const
void drawControl (ControlElement element, QPainter *p, const QWidget *widget, const QRect &r, const QColorGroup &cg, SFlags how=Style_Default, const QStyleOption &=QStyleOption::Default) const
QRect subRect (SubRect r, const QWidget *widget) const
void drawComplexControl (ComplexControl control, QPainter *p, const QWidget *widget, const QRect &r, const QColorGroup &cg, SFlags how=Style_Default, SCFlags controls=(uint) SC_All, SCFlags active=SC_None, const QStyleOption &=QStyleOption::Default) const
QRect querySubControlMetrics (ComplexControl control, const QWidget *widget, SubControl subcontrol, const QStyleOption &=QStyleOption::Default) const
int pixelMetric (PixelMetric metric, const QWidget *widget=0) const
int styleHint (StyleHint sh, const QWidget *, const QStyleOption &=QStyleOption::Default, QStyleHintReturn *=0) const

Métodos protegidos

bool eventFilter (QObject *, QEvent *)
bool eventFilter (QObject *, QEvent *)

Descripción detallada

The QMotifPlusStyle class provides a more sophisticated Motif-ish look and feel.

This class implements a Motif-ish look and feel with the more sophisticated bevelling as used by the GIMP Toolkit (GTK+) for Unix/X11.


Documentación del constructor y destructor

QMotifPlusStyle::QMotifPlusStyle ( bool  hoveringHighlight = TRUE)

Constructs a QMotifPlusStyle

If hoveringHighlight is TRUE (the default), then the style will not highlight push buttons, checkboxes, radiobuttons, comboboxes, scrollbars or sliders.

QMotifPlusStyle::~QMotifPlusStyle ( ) [virtual]
QMotifPlusStyle::QMotifPlusStyle ( bool  hoveringHighlight = TRUE)
virtual QMotifPlusStyle::~QMotifPlusStyle ( ) [virtual]

Documentación de las funciones miembro

void QMotifPlusStyle::drawComplexControl ( ComplexControl  control,
QPainter p,
const QWidget widget,
const QRect r,
const QColorGroup cg,
SFlags  flags = Style_Default,
SCFlags  controls = (uint)SC_All,
SCFlags  active = SC_None,
const QStyleOption opt = QStyleOption::Default 
) const [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::drawComplexControl ( ComplexControl  control,
QPainter p,
const QWidget widget,
const QRect r,
const QColorGroup cg,
SFlags  flags = Style_Default,
SCFlags  sub = (uint)SC_All,
SCFlags  subActive = SC_None,
const QStyleOption opt = QStyleOption::Default 
) const [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::drawControl ( ControlElement  element,
QPainter p,
const QWidget widget,
const QRect r,
const QColorGroup cg,
SFlags  flags = Style_Default,
const QStyleOption opt = QStyleOption::Default 
) const [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::drawControl ( ControlElement  element,
QPainter p,
const QWidget widget,
const QRect r,
const QColorGroup cg,
SFlags  flags = Style_Default,
const QStyleOption opt = QStyleOption::Default 
) const [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::drawPrimitive ( PrimitiveElement  pe,
QPainter p,
const QRect r,
const QColorGroup cg,
SFlags  flags = Style_Default,
const QStyleOption opt = QStyleOption::Default 
) const [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::drawPrimitive ( PrimitiveElement  pe,
QPainter p,
const QRect r,
const QColorGroup cg,
SFlags  flags = Style_Default,
const QStyleOption opt = QStyleOption::Default 
) const [virtual]

Reimplementado de QMotifStyle.

bool QMotifPlusStyle::eventFilter ( QObject object,
QEvent event 
) [protected, virtual]

Reimplementado de QObject.

bool QMotifPlusStyle::eventFilter ( QObject ,
QEvent  
) [protected, virtual]

Filters events if this object has been installed as an event filter for the watched object.

In your reimplementation of this function, if you want to filter the event e, out, i.e. stop it being handled further, return TRUE; otherwise return FALSE.

Example:

    class MyMainWindow : public QMainWindow
    {
    public:
        MyMainWindow( QWidget *parent = 0, const char *name = 0 );

    protected:
        bool eventFilter( QObject *obj, QEvent *ev );

    private:
        QTextEdit *textEdit;
    };

    MyMainWindow::MyMainWindow( QWidget *parent, const char *name )
        : QMainWindow( parent, name )
    {
        textEdit = new QTextEdit( this );
        setCentralWidget( textEdit );
        textEdit->installEventFilter( this );
    }

    bool MyMainWindow::eventFilter( QObject *obj, QEvent *ev )
    {
        if ( obj == textEdit ) {
            if ( e->type() == QEvent::KeyPress ) {
                QKeyEvent *k = (QKeyEvent*)ev;
                qDebug( "Ate key press %d", k->key() );
                return TRUE;
            } else {
                return FALSE;
            }
        } else {
            // pass the event on to the parent class
            return QMainWindow::eventFilter( obj, ev );
        }
    }

Notice in the example above that unhandled events are passed to the base class's eventFilter() function, since the base class might have reimplemented eventFilter() for its own internal purposes.

Atención:
If you delete the receiver object in this function, be sure to return TRUE. Otherwise, Qt will forward the event to the deleted object and the program might crash.
Ver también:
installEventFilter()

Reimplementado de QObject.

int QMotifPlusStyle::pixelMetric ( PixelMetric  metric,
const QWidget widget = 0 
) const [virtual]

Reimplementado de QMotifStyle.

int QMotifPlusStyle::pixelMetric ( PixelMetric  metric,
const QWidget widget = 0 
) const [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::polish ( QApplication app) [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::polish ( QApplication a) [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::polish ( QWidget w) [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::polish ( QWidget widget) [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::polish ( QPalette pal) [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::polish ( QPalette pal) [virtual]

Reimplementado de QMotifStyle.

QRect QMotifPlusStyle::querySubControlMetrics ( ComplexControl  control,
const QWidget widget,
SubControl  sc,
const QStyleOption opt = QStyleOption::Default 
) const [virtual]

Reimplementado de QMotifStyle.

QRect QMotifPlusStyle::querySubControlMetrics ( ComplexControl  control,
const QWidget widget,
SubControl  subcontrol,
const QStyleOption opt = QStyleOption::Default 
) const [virtual]

Reimplementado de QMotifStyle.

int QMotifPlusStyle::styleHint ( StyleHint  hint,
const QWidget widget,
const QStyleOption opt = QStyleOption::Default,
QStyleHintReturn *  returnData = 0 
) const [virtual]

Reimplementado de QMotifStyle.

int QMotifPlusStyle::styleHint ( StyleHint  hint,
const QWidget widget,
const QStyleOption opt = QStyleOption::Default,
QStyleHintReturn *  returnData = 0 
) const [virtual]

Reimplementado de QMotifStyle.

QRect QMotifPlusStyle::subRect ( SubRect  r,
const QWidget widget 
) const [virtual]

Reimplementado de QMotifStyle.

QRect QMotifPlusStyle::subRect ( SubRect  r,
const QWidget widget 
) const [virtual]

Reimplementado de QMotifStyle.

void QMotifPlusStyle::unPolish ( QApplication ) [virtual]

Esta es una función miembro sobrecargada que se suministra por conveniencia. Difiere de la anterior función solamente en los argumentos que acepta. Undoes the application polish.

Ver también:
polish()

Reimplementado de QStyle.

void QMotifPlusStyle::unPolish ( QWidget widget) [virtual]

Reimplementado de QStyle.

void QMotifPlusStyle::unPolish ( QWidget ) [virtual]

Undoes the initialization of a widget's appearance.

This function is the counterpart to polish. It is called for every polished widget when the style is dynamically changed. The former style has to unpolish its settings before the new style can polish them again.

Ver también:
polish()

Reimplementado de QStyle.

void QMotifPlusStyle::unPolish ( QApplication app) [virtual]

Reimplementado de QStyle.


La documentación para esta clase fue generada a partir de los siguientes ficheros:
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'