Qt 4.8
Classes | Macros | Enumerations | Functions
qmacstyle_mac_p.h File Reference
#include <qmacstyle_mac.h>
#include <private/qapplication_p.h>
#include <private/qcombobox_p.h>
#include <private/qmacstylepixmaps_mac_p.h>
#include <private/qpaintengine_mac_p.h>
#include <private/qpainter_p.h>
#include <private/qprintengine_mac_p.h>
#include <private/qstylehelper_p.h>
#include <qapplication.h>
#include <qbitmap.h>
#include <qcheckbox.h>
#include <qcombobox.h>
#include <qdialogbuttonbox.h>
#include <qdockwidget.h>
#include <qevent.h>
#include <qfocusframe.h>
#include <qformlayout.h>
#include <qgroupbox.h>
#include <qhash.h>
#include <qheaderview.h>
#include <qlayout.h>
#include <qlineedit.h>
#include <qlistview.h>
#include <qmainwindow.h>
#include <qmap.h>
#include <qmenubar.h>
#include <qpaintdevice.h>
#include <qpainter.h>
#include <qpixmapcache.h>
#include <qpointer.h>
#include <qprogressbar.h>
#include <qpushbutton.h>
#include <qradiobutton.h>
#include <qrubberband.h>
#include <qsizegrip.h>
#include <qspinbox.h>
#include <qsplitter.h>
#include <qstyleoption.h>
#include <qtextedit.h>
#include <qtextstream.h>
#include <qtoolbar.h>
#include <qtoolbutton.h>
#include <qtreeview.h>
#include <qtableview.h>
#include <qwizard.h>
#include <qdebug.h>
#include <qlibrary.h>
#include <qdatetimeedit.h>
#include <qmath.h>
#include <QtGui/qgraphicsproxywidget.h>
#include <QtGui/qgraphicsview.h>
#include <private/qt_cocoa_helpers_mac_p.h>

Go to the source code of this file.

Classes

class  QMacStylePrivate
 
struct  QMacStylePrivate::ButtonState
 

Macros

#define CT1(c)   CT2(c, c)
 
#define CT2(c1, c2)   ((uint(c1) << 16) | uint(c2))
 
#define return_SIZE(large, small, mini)
 
#define SIZE(large, small, mini)   (controlSize == QAquaSizeLarge ? (large) : controlSize == QAquaSizeSmall ? (small) : (mini))
 

Enumerations

enum  { kThemePushButtonTextured = 31, kThemePushButtonTexturedSmall = 32, kThemePushButtonTexturedMini = 33 }
 
enum  { kHIThemeFrameTextFieldRound = 1000, kHIThemeFrameTextFieldRoundSmall = 1001, kHIThemeFrameTextFieldRoundMini = 1002 }
 
enum  QAquaWidgetSize { QAquaSizeLarge = 0, QAquaSizeSmall = 1, QAquaSizeMini = 2, QAquaSizeUnknown = -1 }
 

Functions

bool qt_mac_buttonIsRenderedFlat (const QPushButton *pushButton, const QStyleOptionButton *option)
 

Macro Definition Documentation

◆ CT1

#define CT1 (   c)    CT2(c, c)

Definition at line 137 of file qmacstyle_mac_p.h.

Referenced by QMacStyle::layoutSpacingImplementation().

◆ CT2

#define CT2 (   c1,
  c2 
)    ((uint(c1) << 16) | uint(c2))

Definition at line 138 of file qmacstyle_mac_p.h.

Referenced by QMacStyle::layoutSpacingImplementation().

◆ return_SIZE

#define return_SIZE (   large,
  small,
  mini 
)
Value:
do { \
static const int sizes[] = { (large), (small), (mini) }; \
return sizes[controlSize]; \
} while (0)

Definition at line 147 of file qmacstyle_mac_p.h.

Referenced by QMacStyle::layoutSpacingImplementation(), and QMacStyle::pixelMetric().

◆ SIZE

#define SIZE (   large,
  small,
  mini 
)    (controlSize == QAquaSizeLarge ? (large) : controlSize == QAquaSizeSmall ? (small) : (mini))

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
kThemePushButtonTextured 
kThemePushButtonTexturedSmall 
kThemePushButtonTexturedMini 

Definition at line 113 of file qmacstyle_mac_p.h.

◆ anonymous enum

anonymous enum
Enumerator
kHIThemeFrameTextFieldRound 
kHIThemeFrameTextFieldRoundSmall 
kHIThemeFrameTextFieldRoundMini 

Definition at line 120 of file qmacstyle_mac_p.h.

◆ QAquaWidgetSize

Enumerator
QAquaSizeLarge 
QAquaSizeSmall 
QAquaSizeMini 
QAquaSizeUnknown 

Definition at line 140 of file qmacstyle_mac_p.h.

Function Documentation

◆ qt_mac_buttonIsRenderedFlat()

bool qt_mac_buttonIsRenderedFlat ( const QPushButton pushButton,
const QStyleOptionButton option 
)

Definition at line 1062 of file qmacstyle_mac.mm.

Referenced by QPushButton::hitButton().

1063 {
1064  QMacStyle *macStyle = qobject_cast<QMacStyle *>(pushButton->style());
1065  if (!macStyle)
1066  return true; // revert to 'flat' behavior if not Mac style
1067  HIThemeButtonDrawInfo bdi;
1068  macStyle->d->initHIThemePushButton(option, pushButton, kThemeStateActive, &bdi);
1069  return bdi.kind == kThemeBevelButton;
1070 }
T * qobject_cast(QObject *object)
Definition: qobject.h:375
QMacStylePrivate * d
QStyle * style() const
Definition: qwidget.cpp:2742
void initHIThemePushButton(const QStyleOptionButton *btn, const QWidget *widget, const ThemeDrawState tds, HIThemeButtonDrawInfo *bdi) const