#include <QtGui/qmatrix.h>
#include <QtCore/qglobal.h>
#include <QtCore/qrect.h>
#include <QtCore/qline.h>
#include <QtCore/qvector.h>
Include dependency graph for qpainterpath.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.
Classes | |
| class | QPainterPath |
| The QPainterPath class provides a container for painting operations, enabling graphical shapes to be constructed and reused. More... | |
| class | QPainterPath::Element |
| The QPainterPath::Element class specifies the position and type of a subpath. More... | |
| class | QPainterPathPrivate |
| class | QPainterPathStroker |
| The QPainterPathStroker class is used to generate fillable outlines for a given painter path. More... | |
Functions | |
| Q_DECLARE_TYPEINFO (QPainterPath::Element, Q_PRIMITIVE_TYPE) | |
| Q_GUI_EXPORT QDataStream & | operator<< (QDataStream &, const QPainterPath &) |
| Q_GUI_EXPORT QDataStream & | operator>> (QDataStream &, QPainterPath &) |
| Q_GUI_EXPORT QDataStream& operator<< | ( | QDataStream & | , | |
| const QPainterPath & | ||||
| ) |
Definition at line 2199 of file qpainterpath.cpp.
02200 { 02201 if (p.isEmpty()) { 02202 s << 0; 02203 return s; 02204 } 02205 02206 s << p.elementCount(); 02207 for (int i=0; i < p.d_func()->elements.size(); ++i) { 02208 const QPainterPath::Element &e = p.d_func()->elements.at(i); 02209 s << int(e.type); 02210 s << double(e.x) << double(e.y); 02211 } 02212 s << p.d_func()->cStart; 02213 s << int(p.d_func()->fillRule); 02214 return s; 02215 }
| Q_GUI_EXPORT QDataStream& operator>> | ( | QDataStream & | , | |
| QPainterPath & | ||||
| ) |
Definition at line 2226 of file qpainterpath.cpp.
References i, QPainterPath::MoveToElement, Qt::OddEvenFill, p, qIsNan(), qWarning(), s, size, type, Qt::WindingFill, x, and y.
02227 { 02228 int size; 02229 s >> size; 02230 02231 if (size == 0) 02232 return s; 02233 02234 p.ensureData(); // in case if p.d_func() == 0 02235 if (p.d_func()->elements.size() == 1) { 02236 Q_ASSERT(p.d_func()->elements.at(0).type == QPainterPath::MoveToElement); 02237 p.d_func()->elements.clear(); 02238 } 02239 p.d_func()->elements.reserve(p.d_func()->elements.size() + size); 02240 for (int i=0; i<size; ++i) { 02241 int type; 02242 double x, y; 02243 s >> type; 02244 s >> x; 02245 s >> y; 02246 Q_ASSERT(type >= 0 && type <= 3); 02247 #ifndef QT_NO_DEBUG 02248 if (qIsNan(x) || qIsNan(y)) 02249 qWarning("QDataStream::operator>>: Adding a NaN element to path, results are undefined"); 02250 #endif 02251 QPainterPath::Element elm = { x, y, QPainterPath::ElementType(type) }; 02252 p.d_func()->elements.append(elm); 02253 } 02254 s >> p.d_func()->cStart; 02255 int fillRule; 02256 s >> fillRule; 02257 Q_ASSERT(fillRule == Qt::OddEvenFill || Qt::WindingFill); 02258 p.d_func()->fillRule = Qt::FillRule(fillRule); 02259 return s; 02260 }
Here is the call graph for this function:

| Q_DECLARE_TYPEINFO | ( | QPainterPath::Element | , | |
| Q_PRIMITIVE_TYPE | ||||
| ) |
1.5.1