Home · All Classes · Main Classes · Grouped Classes · Modules · Functions

QStyleOptionButton Class Reference
[QtGui module]

The QStyleOptionButton class is used to describe the parameters for drawing buttons. More...

#include <QStyleOptionButton>

Inherits QStyleOption.

Public Types

Public Functions

Public Variables

Static Public Members


Detailed Description

The QStyleOptionButton class is used to describe the parameters for drawing buttons.

The QStyleOptionButton class is used to draw QPushButton, QCheckBox, and QRadioButton.

See also QStyleOptionToolButton.


Member Type Documentation

enum QStyleOptionButton::ButtonFeature
flags QStyleOptionButton::ButtonFeatures

This enum describles the different types of features a push button can have.

ConstantValueDescription
QStyleOptionButton::None0x00Indicates a normal push button.
QStyleOptionButton::Flat0x01Indicates a flat push button.
QStyleOptionButton::HasMenu0x02Indicates that the button has a drop down menu.
QStyleOptionButton::DefaultButton0x04Indicates that the button is a default button.
QStyleOptionButton::AutoDefaultButton0x08Indicates that the button is an auto default button.

The ButtonFeatures type is a typedef for QFlags<ButtonFeature>. It stores an OR combination of ButtonFeature values.

See also features.


Member Function Documentation

QStyleOptionButton::QStyleOptionButton ()

Constructs a QStyleOptionButton. The members variables are initialized to default values.

QStyleOptionButton::QStyleOptionButton ( const QStyleOptionButton & other )

Constructs a copy of the other style option.


Member Variable Documentation

const int QStyleOptionButton::Type

Equals SO_Button.

const int QStyleOptionButton::Version

Equals 1.

ButtonFeatures QStyleOptionButton::features

This variable holds the features for the button.

This variable is a bitwise OR of the features that describe this button.

See also ButtonFeature.

QIcon QStyleOptionButton::icon

This variable holds the icon of the button.

See also iconSize.

QSize QStyleOptionButton::iconSize

This variable holds the size of the icon for the button.

QString QStyleOptionButton::text

This variable holds the text of the button.


Copyright © 2006 Trolltech Trademarks
Qt 4.1.3