Eneboo - Documentación para desarrolladores
|
The QCommonStyle class encapsulates the common Look and Feel of a GUI. Más...
#include <qcommonstyle.h>
Métodos públicos | |
QCommonStyle () | |
~QCommonStyle () | |
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 |
void | drawControlMask (ControlElement element, QPainter *p, const QWidget *widget, const QRect &r, 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 sub=(uint) SC_All, SCFlags subActive=SC_None, const QStyleOption &=QStyleOption::Default) const |
void | drawComplexControlMask (ComplexControl control, QPainter *p, const QWidget *widget, const QRect &r, const QStyleOption &=QStyleOption::Default) const |
QRect | querySubControlMetrics (ComplexControl control, const QWidget *widget, SubControl sc, const QStyleOption &=QStyleOption::Default) const |
SubControl | querySubControl (ComplexControl control, const QWidget *widget, const QPoint &pos, const QStyleOption &=QStyleOption::Default) const |
int | pixelMetric (PixelMetric m, const QWidget *widget=0) const |
QSize | sizeFromContents (ContentsType s, const QWidget *widget, const QSize &contentsSize, const QStyleOption &=QStyleOption::Default) const |
int | styleHint (StyleHint sh, const QWidget *, const QStyleOption &, QStyleHintReturn *) const |
QPixmap | stylePixmap (StylePixmap sp, const QWidget *widget=0, const QStyleOption &=QStyleOption::Default) const |
QCommonStyle () | |
~QCommonStyle () | |
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 |
void | drawControlMask (ControlElement element, QPainter *p, const QWidget *widget, const QRect &r, 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 sub=(uint) SC_All, SCFlags subActive=SC_None, const QStyleOption &=QStyleOption::Default) const |
void | drawComplexControlMask (ComplexControl control, QPainter *p, const QWidget *widget, const QRect &r, const QStyleOption &=QStyleOption::Default) const |
QRect | querySubControlMetrics (ComplexControl control, const QWidget *widget, SubControl sc, const QStyleOption &=QStyleOption::Default) const |
SubControl | querySubControl (ComplexControl control, const QWidget *widget, const QPoint &pos, const QStyleOption &=QStyleOption::Default) const |
int | pixelMetric (PixelMetric m, const QWidget *widget=0) const |
QSize | sizeFromContents (ContentsType s, const QWidget *widget, const QSize &contentsSize, const QStyleOption &=QStyleOption::Default) const |
int | styleHint (StyleHint sh, const QWidget *, const QStyleOption &, QStyleHintReturn *) const |
QPixmap | stylePixmap (StylePixmap sp, const QWidget *widget=0, const QStyleOption &=QStyleOption::Default) const |
The QCommonStyle class encapsulates the common Look and Feel of a GUI.
This abstract class implements some of the widget's look and feel that is common to all GUI styles provided and shipped as part of Qt.
All the functions are documented in QStyle.
QCommonStyle::QCommonStyle | ( | ) |
Constructs a QCommonStyle.
QCommonStyle::~QCommonStyle | ( | ) |
QCommonStyle::QCommonStyle | ( | ) |
QCommonStyle::~QCommonStyle | ( | ) |
void QCommonStyle::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] |
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
void QCommonStyle::drawComplexControl | ( | ComplexControl | control, |
QPainter * | p, | ||
const QWidget * | widget, | ||
const QRect & | r, | ||
const QColorGroup & | cg, | ||
SFlags | how = Style_Default , |
||
SCFlags | sub = (uint)SC_All , |
||
SCFlags | subActive = SC_None , |
||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Draws the ComplexControl control using the painter p in the area r. Colors are used from the color group cg. The sub argument specifies which SubControls to draw. Multiple SubControls can be OR'ed together. The subActive argument specifies which SubControl is active.
The rect r should be in logical coordinates. Reimplementations of this function should use visualRect() to change the logical coordinates into screen coordinates when using drawPrimitive() and drawControl().
The how argument is used to control how the ComplexControl is drawn. Multiple flags can OR'ed together. See the table below for an explanation of which flags are used with the various ComplexControls.
The widget argument is a pointer to a QWidget or one of its subclasses. The widget can be cast to the appropriate type based on the value of control. The opt argument can be used to pass extra information required when drawing the ComplexControl. Note that opt may be the default value even for ComplexControls that can make use of the extra options. See the table below for the appropriate widget and opt usage:
ComplexControl
& Widget Cast Style Flags Notes Options Notes
{CC_SpinWidget}(const QSpinWidget *) Style_Enabled Set if the spinwidget is enabled. Unused. Style_HasFocus Set if the spinwidget has input focus.
{CC_ComboBox}(const QComboBox *) Style_Enabled Set if the combobox is enabled. Unused. Style_HasFocus Set if the combobox has input focus.
{CC_ScrollBar}(const QScrollBar *) Style_Enabled Set if the scrollbar is enabled. Unused. Style_HasFocus Set if the scrollbar has input focus.
{CC_Slider}(const QSlider *) Style_Enabled Set if the slider is enabled. Unused.
Style_HasFocus Set if the slider has input focus.
{CC_ToolButton}(const QToolButton *) Style_Enabled Set if the toolbutton is enabled. QStyleOption ( ArrowType t ) opt.arrowType() When the tool button only contains an arrow, t is the arrow's type. Style_HasFocus Set if the toolbutton has input focus. Style_Down Set if the toolbutton is down (ie. mouse button or space pressed). Style_On Set if the toolbutton is a toggle button and is toggled on. Style_AutoRaise Set if the toolbutton has auto-raise enabled. Style_Raised Set if the button is not down, not on and doesn't contain the mouse when auto-raise is enabled.
{CC_TitleBar}(const QWidget *) Style_Enabled Set if the titlebar is enabled. Unused.
{CC_ListView}(const QListView *) Style_Enabled Set if the titlebar is enabled. QStyleOption ( QListViewItem *item ) opt.listViewItem() item is the item that needs branches drawn
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
void QCommonStyle::drawComplexControlMask | ( | ComplexControl | control, |
QPainter * | p, | ||
const QWidget * | widget, | ||
const QRect & | r, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Draw a bitmask for the ComplexControl control using the painter p in the area r. See drawComplexControl() for an explanation of the use of the widget and opt arguments.
The rect r should be in logical coordinates. Reimplementations of this function should use visualRect() to change the logical corrdinates into screen coordinates when using drawPrimitive() and drawControl().
Implementa QStyle.
void QCommonStyle::drawComplexControlMask | ( | ComplexControl | control, |
QPainter * | p, | ||
const QWidget * | widget, | ||
const QRect & | r, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Implementa QStyle.
void QCommonStyle::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] |
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
void QCommonStyle::drawControl | ( | ControlElement | element, |
QPainter * | p, | ||
const QWidget * | widget, | ||
const QRect & | r, | ||
const QColorGroup & | cg, | ||
SFlags | how = Style_Default , |
||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Draws the ControlElement element using the painter p in the area r. Colors are used from the color group cg.
The rect r should be in screen coordinates.
The how argument is used to control how the ControlElement is drawn. Multiple flags can be OR'ed together. See the table below for an explanation of which flags are used with the various ControlElements.
The widget argument is a pointer to a QWidget or one of its subclasses. The widget can be cast to the appropriate type based on the value of element. The opt argument can be used to pass extra information required when drawing the ControlElement. Note that opt may be the default value even for ControlElements that can make use of the extra options. See the table below for the appropriate widget and opt usage:
ControlElement
& Widget Cast Style Flags Notes Options Notes
{CE_PushButton}(const QPushButton *)
and
{CE_PushButtonLabel}(const QPushButton *) Style_Enabled Set if the button is enabled. Unused. Style_HasFocus Set if the button has input focus. Style_Raised Set if the button is not down, not on and not flat. Style_On Set if the button is a toggle button and toggled on. Style_Down Set if the button is down (i.e., the mouse button or space bar is pressed on the button). Style_ButtonDefault Set if the button is a default button.
{CE_CheckBox}(const QCheckBox *)
and
{CE_CheckBoxLabel}(const QCheckBox *)
Style_Enabled Set if the checkbox is enabled. Unused. Style_HasFocus Set if the checkbox has input focus. Style_On Set if the checkbox is checked. Style_Off Set if the checkbox is not checked. Style_NoChange Set if the checkbox is in the NoChange state. Style_Down Set if the checkbox is down (i.e., the mouse button or space bar is pressed on the button).
{CE_RadioButton}(const QRadioButton *)
and
{CE_RadioButtonLabel}(const QRadioButton *) Style_Enabled Set if the radiobutton is enabled. Unused. Style_HasFocus Set if the radiobutton has input focus. Style_On Set if the radiobutton is checked. Style_Off Set if the radiobutton is not checked. Style_Down Set if the radiobutton is down (i.e., the mouse button or space bar is pressed on the radiobutton).
{CE_TabBarTab}(const QTabBar *)
and
{CE_TabBarLabel}(const QTabBar *)
Style_Enabled Set if the tabbar and tab is enabled. QStyleOption ( QTab *t ) opt.tab() t is the QTab being drawn. Style_Selected Set if the tab is the current tab.
{CE_ProgressBarGroove}(const QProgressBar *)
and
{CE_ProgressBarContents}(const QProgressBar *)
and
{CE_ProgressBarLabel}(const QProgressBar *)
Style_Enabled Set if the progressbar is enabled. Unused. Style_HasFocus Set if the progressbar has input focus.
{CE_PopupMenuItem}(const QPopupMenu *) Style_Enabled Set if the menuitem is enabled. QStyleOption ( QMenuItem *mi, int tabwidth, int maxpmwidth ) opt.menuItem() opt.tabWidth() opt.maxIconWidth() mi is the menu item being drawn. QMenuItem is currently an internal class. Style_Active Set if the menuitem is the current item. tabwidth is the width of the tab column where key accelerators are drawn. Style_Down Set if the menuitem is down (i.e., the mouse button or space bar is pressed). maxpmwidth is the maximum width of the check column where checkmarks and iconsets are drawn.
{CE_MenuBarItem}(const QMenuBar *) Style_Enabled Set if the menuitem is enabled QStyleOption ( QMenuItem *mi ) opt.menuItem() mi is the menu item being drawn. Style_Active Set if the menuitem is the current item. Style_Down Set if the menuitem is down (i.e., a mouse button or the space bar is pressed). Style_HasFocus Set if the menubar has input focus.
{CE_ToolButtonLabel}(const QToolButton *) Style_Enabled Set if the toolbutton is enabled. QStyleOption ( ArrowType t ) opt.arrowType() When the tool button only contains an arrow, t is the arrow's type. Style_HasFocus Set if the toolbutton has input focus. Style_Down Set if the toolbutton is down (i.e., a mouse button or the space is pressed). Style_On Set if the toolbutton is a toggle button and is toggled on. Style_AutoRaise Set if the toolbutton has auto-raise enabled. Style_MouseOver Set if the mouse pointer is over the toolbutton. Style_Raised Set if the button is not down, not on and doesn't contain the mouse when auto-raise is enabled.
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
void QCommonStyle::drawControlMask | ( | ControlElement | control, |
QPainter * | p, | ||
const QWidget * | widget, | ||
const QRect & | r, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Implementa QStyle.
Reimplementado en BluecurveStyle.
void QCommonStyle::drawControlMask | ( | ControlElement | element, |
QPainter * | p, | ||
const QWidget * | widget, | ||
const QRect & | r, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Draw a bitmask for the ControlElement element using the painter p in the area r. See drawControl() for an explanation of the use of the widget and opt arguments.
The rect r should be in screen coordinates.
Implementa QStyle.
Reimplementado en BluecurveStyle.
void QCommonStyle::drawPrimitive | ( | PrimitiveElement | pe, |
QPainter * | p, | ||
const QRect & | r, | ||
const QColorGroup & | cg, | ||
SFlags | flags = Style_Default , |
||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
void QCommonStyle::drawPrimitive | ( | PrimitiveElement | pe, |
QPainter * | p, | ||
const QRect & | r, | ||
const QColorGroup & | cg, | ||
SFlags | flags = Style_Default , |
||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Draws the style PrimitiveElement pe using the painter p in the area r. Colors are used from the color group cg.
The rect r should be in screen coordinates.
The flags argument is used to control how the PrimitiveElement is drawn. Multiple flags can be OR'ed together.
For example, a pressed button would be drawn with the flags Style_Enabled
and Style_Down
.
The opt argument can be used to control how various PrimitiveElements are drawn. Note that opt may be the default value even for PrimitiveElements that make use of extra options. When opt is non-default, it is used as follows:
PrimitiveElement Options Notes PE_FocusRect QStyleOption ( const QColor & bg ) opt.color() bg is the background color on which the focus rect is being drawn. PE_Panel QStyleOption ( int linewidth, int midlinewidth ) opt.lineWidth() opt.midLineWidth() linewidth is the line width for drawing the panel. midlinewidth is the mid-line width for drawing the panel. PE_PanelPopup QStyleOption ( int linewidth, int midlinewidth ) opt.lineWidth() opt.midLineWidth() linewidth is the line width for drawing the panel. midlinewidth is the mid-line width for drawing the panel. PE_PanelMenuBar QStyleOption ( int linewidth, int midlinewidth ) opt.lineWidth() opt.midLineWidth() linewidth is the line width for drawing the panel. midlinewidth is the mid-line width for drawing the panel. PE_PanelDockWindow QStyleOption ( int linewidth, int midlinewidth ) opt.lineWidth() opt.midLineWidth() linewidth is the line width for drawing the panel. midlinewidth is the mid-line width for drawing the panel. PE_GroupBoxFrame QStyleOption ( int linewidth, int midlinewidth, int shape, int shadow ) opt.lineWidth() opt.midLineWidth() opt.frameShape() opt.frameShadow() linewidth is the line width for the group box. midlinewidth is the mid-line width for the group box. shape is the frame shape for the group box. shadow is the frame shadow for the group box.
For all other PrimitiveElements, opt is unused.
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
int QCommonStyle::pixelMetric | ( | PixelMetric | m, |
const QWidget * | widget = 0 |
||
) | const [virtual] |
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
int QCommonStyle::pixelMetric | ( | PixelMetric | metric, |
const QWidget * | widget = 0 |
||
) | const [virtual] |
Returns the pixel metric for metric. The widget argument is a pointer to a QWidget or one of its subclasses. The widget can be cast to the appropriate type based on the value of metric. Note that widget may be zero even for PixelMetrics that can make use of widget. See the table below for the appropriate widget casts:
PixelMetric Widget Cast PM_SliderControlThickness (const QSlider *) PM_SliderLength (const QSlider *) PM_SliderTickmarkOffset (const QSlider *) PM_SliderSpaceAvailable (const QSlider *) PM_TabBarTabOverlap (const QTabBar *) PM_TabBarTabHSpace (const QTabBar *) PM_TabBarTabVSpace (const QTabBar *) PM_TabBarBaseHeight (const QTabBar *) PM_TabBarBaseOverlap (const QTabBar *)
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QCDEStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
QStyle::SubControl QCommonStyle::querySubControl | ( | ComplexControl | control, |
const QWidget * | widget, | ||
const QPoint & | pos, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Implementa QStyle.
Reimplementado en BluecurveStyle y QtCKStyle.
SubControl QCommonStyle::querySubControl | ( | ComplexControl | control, |
const QWidget * | widget, | ||
const QPoint & | pos, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Returns the SubControl for widget at the point pos. The widget argument is a pointer to a QWidget or one of its subclasses. The widget can be cast to the appropriate type based on the value of control. The opt argument can be used to pass extra information required when drawing the ComplexControl. Note that opt may be the default value even for ComplexControls that can make use of the extra options. See drawComplexControl() for an explanation of the widget and opt arguments.
Note that pos is passed in screen coordinates. When using querySubControlMetrics() to check for hits and misses, use visualRect() to change the logical coordinates into screen coordinates.
Implementa QStyle.
Reimplementado en BluecurveStyle y QtCKStyle.
QRect QCommonStyle::querySubControlMetrics | ( | ComplexControl | control, |
const QWidget * | widget, | ||
SubControl | subcontrol, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Returns the rect for the SubControl subcontrol for widget in logical coordinates.
The widget argument is a pointer to a QWidget or one of its subclasses. The widget can be cast to the appropriate type based on the value of control. The opt argument can be used to pass extra information required when drawing the ComplexControl. Note that opt may be the default value even for ComplexControls that can make use of the extra options. See drawComplexControl() for an explanation of the widget and opt arguments.
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle y QSGIStyle.
QRect QCommonStyle::querySubControlMetrics | ( | ComplexControl | control, |
const QWidget * | widget, | ||
SubControl | sc, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle y QSGIStyle.
QSize QCommonStyle::sizeFromContents | ( | ContentsType | contents, |
const QWidget * | widget, | ||
const QSize & | contentsSize, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Returns the size of widget based on the contents size contentsSize.
The widget argument is a pointer to a QWidget or one of its subclasses. The widget can be cast to the appropriate type based on the value of contents. The opt argument can be used to pass extra information required when calculating the size. Note that opt may be the default value even for ContentsTypes that can make use of the extra options. See the table below for the appropriate widget and opt usage:
ContentsType Widget Cast Options Notes CT_PushButton (const QPushButton *) Unused. CT_CheckBox (const QCheckBox *) Unused. CT_RadioButton (const QRadioButton *) Unused. CT_ToolButton (const QToolButton *) Unused. CT_ComboBox (const QComboBox *) Unused. CT_Splitter (const QSplitter *) Unused. CT_DockWindow (const QDockWindow *) Unused. CT_ProgressBar (const QProgressBar *) Unused. CT_PopupMenuItem (const QPopupMenu *) QStyleOption ( QMenuItem *mi ) opt.menuItem() mi is the menu item to use when calculating the size. QMenuItem is currently an internal class.
Implementa QStyle.
Reimplementado en BluecurveStyle, QMotifStyle, QSGIStyle, QWindowsStyle, QMotifStyle, QSGIStyle y QWindowsStyle.
QSize QCommonStyle::sizeFromContents | ( | ContentsType | contents, |
const QWidget * | widget, | ||
const QSize & | contentsSize, | ||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Implementa QStyle.
Reimplementado en BluecurveStyle, QMotifStyle, QSGIStyle, QWindowsStyle, QMotifStyle, QSGIStyle y QWindowsStyle.
int QCommonStyle::styleHint | ( | StyleHint | stylehint, |
const QWidget * | widget, | ||
const QStyleOption & | opt, | ||
QStyleHintReturn * | returnData | ||
) | const [virtual] |
Returns the style hint stylehint for widget. Currently, widget, opt, and returnData are unused; they're included to allow for future enhancements.
For an explanation of the return value see StyleHint.
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifPlusStyle, QMotifStyle, QWindowsStyle, QMotifPlusStyle, QMotifStyle y QWindowsStyle.
int QCommonStyle::styleHint | ( | StyleHint | sh, |
const QWidget * | w, | ||
const QStyleOption & | , | ||
QStyleHintReturn * | |||
) | const [virtual] |
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifPlusStyle, QMotifStyle, QWindowsStyle, QMotifPlusStyle, QMotifStyle y QWindowsStyle.
QPixmap QCommonStyle::stylePixmap | ( | StylePixmap | stylepixmap, |
const QWidget * | widget = 0 , |
||
const QStyleOption & | opt = QStyleOption::Default |
||
) | const [virtual] |
Returns a pixmap for stylepixmap.
The opt argument can be used to pass extra information required when drawing the ControlElement. Note that opt may be the default value even for StylePixmaps that can make use of the extra options. Currently, the opt argument is unused.
The widget argument is a pointer to a QWidget or one of its subclasses. The widget can be cast to the appropriate type based on the value of stylepixmap. See the table below for the appropriate widget casts:
StylePixmap Widget Cast SP_TitleBarMinButton (const QWidget *) SP_TitleBarMaxButton (const QWidget *) SP_TitleBarCloseButton (const QWidget *) SP_TitleBarNormalButton (const QWidget *) SP_TitleBarShadeButton (const QWidget *) SP_TitleBarUnshadeButton (const QWidget *) SP_DockWindowCloseButton (const QDockWindow *)
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifStyle, QWindowsStyle, QMotifStyle y QWindowsStyle.
QPixmap QCommonStyle::stylePixmap | ( | StylePixmap | sp, |
const QWidget * | widget = 0 , |
||
const QStyleOption & | = QStyleOption::Default |
||
) | const [virtual] |
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifStyle, QWindowsStyle, QMotifStyle y QWindowsStyle.
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.
Returns the sub-area subrect for the widget in logical coordinates.
The widget argument is a pointer to a QWidget or one of its subclasses. The widget can be cast to the appropriate type based on the value of subrect. See the table below for the appropriate widget casts:
SubRect Widget Cast SR_PushButtonContents (const QPushButton *) SR_PushButtonFocusRect (const QPushButton *) SR_CheckBoxIndicator (const QCheckBox *) SR_CheckBoxContents (const QCheckBox *) SR_CheckBoxFocusRect (const QCheckBox *) SR_RadioButtonIndicator (const QRadioButton *) SR_RadioButtonContents (const QRadioButton *) SR_RadioButtonFocusRect (const QRadioButton *) SR_ComboBoxFocusRect (const QComboBox *) SR_DockWindowHandleRect (const QWidget *) SR_ProgressBarGroove (const QProgressBar *) SR_ProgressBarContents (const QProgressBar *) SR_ProgressBarLabel (const QProgressBar *)
The tear-off handle (SR_DockWindowHandleRect) for QDockWindow is a private class. Use QWidget::parentWidget() to access the QDockWindow:
if ( !widget->parentWidget() ) return; const QDockWindow *dw = (const QDockWindow *) widget->parentWidget();
Implementa QStyle.
Reimplementado en BluecurveStyle, QtCKStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle, QWindowsStyle, QMotifPlusStyle, QMotifStyle, QPlatinumStyle, QSGIStyle y QWindowsStyle.