Qt 4.8
|
#include <qpaintengine_mac_p.h>
Public Functions | |
bool | begin (QPaintDevice *pdev) |
Reimplement this function to initialise your paint engine when painting is to start on the paint device pdev. More... | |
void | drawEllipse (const QRectF &r) |
Reimplement this function to draw the largest ellipse that can be contained within rectangle rect. More... | |
void | drawEllipse (const QRect &r) |
The default implementation of this function calls the floating point version of this function. More... | |
void | drawImage (const QRectF &r, const QImage &pm, const QRectF &sr, Qt::ImageConversionFlags flags=Qt::AutoColor) |
Reimplement this function to draw the part of the image specified by the sr rectangle in the given rectangle using the given conversion flags flags, to convert it to a pixmap. More... | |
void | drawLines (const QLineF *lines, int lineCount) |
The default implementation splits the list of lines in lines into lineCount separate calls to drawPath() or drawPolygon() depending on the feature set of the paint engine. More... | |
void | drawLines (const QLine *lines, int lineCount) |
The default implementation converts the first lineCount lines in lines to a QLineF and calls the floating point version of this function. More... | |
void | drawPath (const QPainterPath &path) |
The default implementation ignores the path and does nothing. More... | |
void | drawPixmap (const QRectF &r, const QPixmap &pm, const QRectF &sr) |
Reimplement this function to draw the part of the pm specified by the sr rectangle in the given r. More... | |
void | drawPoints (const QPointF *p, int pointCount) |
Draws the first pointCount points in the buffer points. More... | |
void | drawPoints (const QPoint *p, int pointCount) |
Draws the first pointCount points in the buffer points. More... | |
void | drawPolygon (const QPointF *points, int pointCount, PolygonDrawMode mode) |
Reimplement this virtual function to draw the polygon defined by the pointCount first points in points, using mode mode. More... | |
void | drawPolygon (const QPoint *points, int pointCount, PolygonDrawMode mode) |
Reimplement this virtual function to draw the polygon defined by the pointCount first points in points, using mode mode. More... | |
void | drawRects (const QRectF *rects, int rectCount) |
Draws the first rectCount rectangles in the buffer rects. More... | |
void | drawRects (const QRect *rects, int rectCount) |
The default implementation converts the first rectCount rectangles in the buffer rects to a QRectF and calls the floating point version of this function. More... | |
void | drawTextItem (const QPointF &pos, const QTextItem &item) |
This function draws the text item textItem at position p. More... | |
void | drawTiledPixmap (const QRectF &r, const QPixmap &pixmap, const QPointF &s) |
Reimplement this function to draw the pixmap in the given rect, starting at the given p. More... | |
bool | end () |
Reimplement this function to finish painting on the current paint device. More... | |
CGContextRef | handle () const |
QCoreGraphicsPaintEngine () | |
QPainter::RenderHints | supportedRenderHints () const |
bool | supportsTransformations (qreal, const QTransform &) const |
Type | type () const |
Reimplement this function to return the paint engine Type. More... | |
void | updateBrush (const QBrush &brush, const QPointF &pt) |
void | updateClipPath (const QPainterPath &path, Qt::ClipOperation op) |
void | updateClipRegion (const QRegion ®ion, Qt::ClipOperation op) |
void | updateCompositionMode (QPainter::CompositionMode mode) |
void | updateFont (const QFont &font) |
void | updateMatrix (const QTransform &matrix) |
void | updateOpacity (qreal opacity) |
void | updatePen (const QPen &pen) |
void | updateRenderHints (QPainter::RenderHints hints) |
void | updateState (const QPaintEngineState &state) |
Reimplement this function to update the state of a paint engine. More... | |
void | updateTransform (const QTransform &matrix) |
~QCoreGraphicsPaintEngine () | |
Public Functions inherited from QPaintEngine | |
void | clearDirty (DirtyFlags df) |
virtual QPoint | coordinateOffset () const |
Returns the offset from the painters origo to the engines origo. More... | |
void | fix_neg_rect (int *x, int *y, int *w, int *h) |
virtual HDC | getDC () const |
Empty default implementation. More... | |
bool | hasFeature (PaintEngineFeatures feature) const |
Returns true if the paint engine supports the specified feature; otherwise returns false. More... | |
bool | isActive () const |
Returns true if the paint engine is actively drawing; otherwise returns false. More... | |
bool | isExtended () const |
Returns true if the paint engine is a QPaintEngineEx derivative. More... | |
QPaintDevice * | paintDevice () const |
Returns the device that this engine is painting on, if painting is active; otherwise returns 0. More... | |
QPainter * | painter () const |
Returns the paint engine's painter. More... | |
QPaintEngine (PaintEngineFeatures features=0) | |
Creates a paint engine with the featureset specified by caps. More... | |
virtual void | releaseDC (HDC hdc) const |
Empty default implementation. More... | |
void | setActive (bool newState) |
Sets the active state of the paint engine to state. More... | |
void | setDirty (DirtyFlags df) |
void | setPaintDevice (QPaintDevice *device) |
void | setSystemClip (const QRegion &baseClip) |
Sets the system clip for this engine. More... | |
void | setSystemRect (const QRect &rect) |
Sets the target rect for drawing within the backing store. More... | |
void | syncState () |
Updates all dirty states in this engine. More... | |
QRegion | systemClip () const |
Returns the system clip. More... | |
QRect | systemRect () const |
Retrieves the rect for drawing within the backing store. More... | |
bool | testDirty (DirtyFlags df) |
virtual | ~QPaintEngine () |
Destroys the paint engine. More... | |
Static Public Functions | |
static void | cleanup () |
static void | clearColorSpace (QWidget *w) |
static void | initialize () |
static CGColorSpaceRef | macDisplayColorSpace (const QWidget *widget=0) |
static CGColorSpaceRef | macGenericColorSpace () |
Protected Functions | |
QCoreGraphicsPaintEngine (QPaintEnginePrivate &dptr) | |
Protected Functions inherited from QPaintEngine | |
QPaintEngine (QPaintEnginePrivate &data, PaintEngineFeatures devcaps=0) | |
Static Private Functions | |
static void | cleanUpMacColorSpaces () |
Static Private Attributes | |
static QHash< QWidget *, CGColorSpaceRef > | m_displayColorSpaceHash |
static CGColorSpaceRef | m_genericColorSpace = 0 |
static bool | m_postRoutineRegistered = false |
Friends | |
class | QMacPrintEngine |
class | QMacPrintEnginePrivate |
void | qt_color_profile_changed (CFNotificationCenterRef center, void *, CFStringRef, const void *, CFDictionaryRef) |
void | qt_mac_display_change_callbk (CGDirectDisplayID, CGDisplayChangeSummaryFlags, void *) |
Definition at line 67 of file qpaintengine_mac_p.h.
QCoreGraphicsPaintEngine::QCoreGraphicsPaintEngine | ( | ) |
Definition at line 544 of file qpaintengine_mac.cpp.
QCoreGraphicsPaintEngine::~QCoreGraphicsPaintEngine | ( | ) |
Definition at line 554 of file qpaintengine_mac.cpp.
|
protected |
Definition at line 549 of file qpaintengine_mac.cpp.
|
virtual |
Reimplement this function to initialise your paint engine when painting is to start on the paint device pdev.
Return true if the initialization was successful; otherwise return false.
Implements QPaintEngine.
Definition at line 559 of file qpaintengine_mac.cpp.
|
static |
|
staticprivate |
Definition at line 366 of file qpaintengine_mac.cpp.
Referenced by macDisplayColorSpace(), macGenericColorSpace(), qt_color_profile_changed(), and qt_mac_display_change_callbk().
|
static |
Definition at line 1070 of file qpaintengine_mac.cpp.
Referenced by QWidget::destroy(), and type().
|
virtual |
Reimplement this function to draw the largest ellipse that can be contained within rectangle rect.
The default implementation calls drawPolygon().
Reimplemented from QPaintEngine.
Definition at line 909 of file qpaintengine_mac.cpp.
|
inlinevirtual |
The default implementation of this function calls the floating point version of this function.
Reimplemented from QPaintEngine.
Definition at line 121 of file qpaintengine_mac_p.h.
|
virtual |
Reimplement this function to draw the part of the image specified by the sr rectangle in the given rectangle using the given conversion flags flags, to convert it to a pixmap.
Reimplemented from QPaintEngine.
Definition at line 1043 of file qpaintengine_mac.cpp.
|
virtual |
The default implementation splits the list of lines in lines into lineCount separate calls to drawPath() or drawPolygon() depending on the feature set of the paint engine.
Reimplemented from QPaintEngine.
Definition at line 950 of file qpaintengine_mac.cpp.
|
inlinevirtual |
The default implementation converts the first lineCount lines in lines to a QLineF and calls the floating point version of this function.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Reimplemented from QPaintEngine.
Definition at line 118 of file qpaintengine_mac_p.h.
|
virtual |
The default implementation ignores the path and does nothing.
Reimplemented from QPaintEngine.
Definition at line 835 of file qpaintengine_mac.cpp.
|
virtual |
Reimplement this function to draw the part of the pm specified by the sr rectangle in the given r.
Implements QPaintEngine.
Definition at line 968 of file qpaintengine_mac.cpp.
|
virtual |
Draws the first pointCount points in the buffer points.
Reimplemented from QPaintEngine.
Definition at line 875 of file qpaintengine_mac.cpp.
|
inlinevirtual |
Draws the first pointCount points in the buffer points.
The default implementation converts the first pointCount QPoints in points to QPointFs and calls the floating point version of drawPoints.
Reimplemented from QPaintEngine.
Definition at line 120 of file qpaintengine_mac_p.h.
|
virtual |
Reimplement this virtual function to draw the polygon defined by the pointCount first points in points, using mode mode.
Reimplemented from QPaintEngine.
Definition at line 927 of file qpaintengine_mac.cpp.
|
inlinevirtual |
Reimplement this virtual function to draw the polygon defined by the pointCount first points in points, using mode mode.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Reimplemented from QPaintEngine.
Definition at line 122 of file qpaintengine_mac_p.h.
|
virtual |
Draws the first rectCount rectangles in the buffer rects.
The default implementation of this function calls drawPath() or drawPolygon() depending on the feature set of the paint engine.
Reimplemented from QPaintEngine.
Definition at line 855 of file qpaintengine_mac.cpp.
|
inlinevirtual |
The default implementation converts the first rectCount rectangles in the buffer rects to a QRectF and calls the floating point version of this function.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Reimplemented from QPaintEngine.
Definition at line 119 of file qpaintengine_mac_p.h.
|
virtual |
This function draws the text item textItem at position p.
The default implementation of this function converts the text to a QPainterPath and paints the resulting path.
Reimplemented from QPaintEngine.
Definition at line 1126 of file qpaintengine_mac.cpp.
|
virtual |
Reimplement this function to draw the pixmap in the given rect, starting at the given p.
The pixmap will be drawn repeatedly until the rect is filled.
Reimplemented from QPaintEngine.
Definition at line 1082 of file qpaintengine_mac.cpp.
|
virtual |
Reimplement this function to finish painting on the current paint device.
Return true if painting was finished successfully; otherwise return false.
Implements QPaintEngine.
Definition at line 615 of file qpaintengine_mac.cpp.
Referenced by begin(), and drawLines().
CGContextRef QCoreGraphicsPaintEngine::handle | ( | ) | const |
Definition at line 1076 of file qpaintengine_mac.cpp.
Referenced by type().
|
static |
Definition at line 1062 of file qpaintengine_mac.cpp.
|
static |
Definition at line 319 of file qpaintengine_mac.cpp.
Referenced by QMacPixmapData::macCreateCGImageRef(), qt_mac_colorSpaceForDeviceType(), and QNativeImage::systemFormat().
|
static |
Definition at line 295 of file qpaintengine_mac.cpp.
Referenced by QMacStyle::drawComplexControl(), QMacStyle::drawControl(), QFontEngineMac::imageForGlyph(), qt_mac_createCGImageFromQImage(), qt_mac_grabScreenRect(), qt_mac_image_to_cgimage(), and QCoreGraphicsPaintEnginePrivate::setFillBrush().
QPainter::RenderHints QCoreGraphicsPaintEngine::supportedRenderHints | ( | ) | const |
Definition at line 1183 of file qpaintengine_mac.cpp.
Referenced by type().
|
inline |
Definition at line 125 of file qpaintengine_mac_p.h.
|
inlinevirtual |
Reimplement this function to return the paint engine Type.
Implements QPaintEngine.
Definition at line 107 of file qpaintengine_mac_p.h.
Referenced by drawTextItem().
Definition at line 712 of file qpaintengine_mac.cpp.
Referenced by drawTextItem(), and updateState().
void QCoreGraphicsPaintEngine::updateClipPath | ( | const QPainterPath & | path, |
Qt::ClipOperation | op | ||
) |
Definition at line 770 of file qpaintengine_mac.cpp.
Referenced by updateState().
void QCoreGraphicsPaintEngine::updateClipRegion | ( | const QRegion & | region, |
Qt::ClipOperation | op | ||
) |
Definition at line 812 of file qpaintengine_mac.cpp.
Referenced by updateState().
void QCoreGraphicsPaintEngine::updateCompositionMode | ( | QPainter::CompositionMode | mode | ) |
Definition at line 1206 of file qpaintengine_mac.cpp.
Referenced by updateState().
void QCoreGraphicsPaintEngine::updateFont | ( | const QFont & | font | ) |
Definition at line 744 of file qpaintengine_mac.cpp.
Referenced by updateState().
void QCoreGraphicsPaintEngine::updateMatrix | ( | const QTransform & | matrix | ) |
Definition at line 752 of file qpaintengine_mac.cpp.
Referenced by updateState().
void QCoreGraphicsPaintEngine::updateOpacity | ( | qreal | opacity | ) |
Definition at line 737 of file qpaintengine_mac.cpp.
Referenced by updateState().
void QCoreGraphicsPaintEngine::updatePen | ( | const QPen & | pen | ) |
Definition at line 703 of file qpaintengine_mac.cpp.
Referenced by drawTextItem(), updateFont(), and updateState().
void QCoreGraphicsPaintEngine::updateRenderHints | ( | QPainter::RenderHints | hints | ) |
Definition at line 1395 of file qpaintengine_mac.cpp.
Referenced by updateState().
|
virtual |
Reimplement this function to update the state of a paint engine.
When implemented, this function is responsible for checking the paint engine's current state and update the properties that are changed. Use the QPaintEngineState::state() function to find out which properties that must be updated, then use the corresponding GetFunction{get function} to retrieve the current values for the given properties.
Implements QPaintEngine.
Definition at line 642 of file qpaintengine_mac.cpp.
void QCoreGraphicsPaintEngine::updateTransform | ( | const QTransform & | matrix | ) |
|
friend |
Definition at line 125 of file qpaintengine_mac_p.h.
|
friend |
Definition at line 129 of file qpaintengine_mac_p.h.
|
friend |
Definition at line 1122 of file qapplication_mac.mm.
|
friend |
Definition at line 352 of file qapplication_mac.mm.
|
staticprivate |
Definition at line 138 of file qpaintengine_mac_p.h.
Referenced by clearColorSpace(), and qt_mac_compose_path().
|
staticprivate |
Definition at line 137 of file qpaintengine_mac_p.h.
Referenced by qt_mac_compose_path().
|
staticprivate |
Definition at line 136 of file qpaintengine_mac_p.h.
Referenced by qt_mac_compose_path().