7#include <QtGui/qtguiglobal.h>
8#include <QtGui/qtransform.h>
9#include <QtCore/qglobal.h>
10#include <QtCore/qline.h>
11#include <QtCore/qlist.h>
12#include <QtCore/qrect.h>
13#include <QtCore/qshareddata.h>
20struct QPainterPathPrivateDeleter;
59 QT_MOVE_ASSIGNMENT_OPERATOR_IMPL_VIA_PURE_SWAP(
QPainterPath)
88 QPointF currentPosition()
const;
99 void addRegion(
const QRegion ®ion);
120 QRectF controlPointRect()
const;
125 bool isEmpty()
const;
133 int elementCount()
const;
166 inline void ensureData() {
if (!d_ptr) ensureData_helper(); }
167 void ensureData_helper();
170 void computeBoundingRect()
const;
171 void computeControlPointRect()
const;
181#ifndef QT_NO_DATASTREAM
190#ifndef QT_NO_DATASTREAM
213 qreal miterLimit()
const;
215 void setCurveThreshold(
qreal threshold);
216 qreal curveThreshold()
const;
223 qreal dashOffset()
const;
247 arcTo(
QRectF(
x,
y,
w,
h), startAngle, arcLength);
274 addEllipse(
QRectF(center.x() -
rx, center.y() -
ry, 2 *
rx, 2 *
ry));
303#ifndef QT_NO_DEBUG_STREAM
\inmodule QtCore\reentrant
T * data() const noexcept
Returns a pointer to the shared data object.
The QPainterPathStroker class is used to generate fillable outlines for a given painter path.
bool isMoveTo() const
Returns true if the element is moving the current position, otherwise returns false.
bool isCurveTo() const
Returns true if the element is a curve, otherwise returns false.
bool operator==(const Element &e) const
\variable QPainterPath::Element::x
bool operator!=(const Element &e) const
bool isLineTo() const
Returns true if the element is a line, otherwise returns false.
void quadTo(const QPointF &ctrlPt, const QPointF &endPt)
Adds a quadratic Bezier curve between the current position and the given endPoint with the control po...
QPainterPath translated(qreal dx, qreal dy) const
Returns a copy of the path that is translated by ({dx}, {dy}).
void translate(qreal dx, qreal dy)
Translates all elements in the path by ({dx}, {dy}).
void addRect(const QRectF &rect)
Adds the given rectangle to this path as a closed subpath.
void addEllipse(const QRectF &rect)
Creates an ellipse within the specified boundingRectangle and adds it to the painter path as a closed...
void addRoundedRect(const QRectF &rect, qreal xRadius, qreal yRadius, Qt::SizeMode mode=Qt::AbsoluteSize)
void arcTo(const QRectF &rect, qreal startAngle, qreal arcLength)
Creates an arc that occupies the given rectangle, beginning at the specified startAngle and extending...
ElementType
This enum describes the types of elements used to connect vertices in subpaths.
void addText(const QPointF &point, const QFont &f, const QString &text)
Adds the given text to this path as a set of closed subpaths created from the font supplied.
void lineTo(const QPointF &p)
Adds a straight line from the current position to the given endPoint.
void swap(QPainterPath &other) noexcept
void cubicTo(const QPointF &ctrlPt1, const QPointF &ctrlPt2, const QPointF &endPt)
Adds a cubic Bezier curve between the current position and the given endPoint using the control point...
void arcMoveTo(const QRectF &rect, qreal angle)
\inmodule QtCore\reentrant
The QPolygonF class provides a list of points using floating point precision.
\inmodule QtCore\reentrant
The QRegion class specifies a clip region for a painter.
\macro QT_RESTRICTED_CAST_FROM_ASCII
Combined button and popup list for selecting options.
constexpr bool operator!=(const timespec &t1, const timespec &t2)
constexpr timespec operator+(const timespec &t1, const timespec &t2)
constexpr timespec operator*(const timespec &t1, int mul)
constexpr timespec & operator+=(timespec &t1, const timespec &t2)
constexpr timespec operator-(const timespec &t1, const timespec &t2)
bool qFuzzyCompare(qfloat16 p1, qfloat16 p2) noexcept
constexpr QKeyCombination operator|(Qt::Modifier modifier, Qt::Key key) noexcept
static bool contains(const QJsonArray &haystack, unsigned needle)
GLint GLint GLint GLint GLint x
[0]
GLfloat GLfloat GLfloat w
[0]
GLenum GLuint GLintptr GLsizeiptr size
[1]
GLenum GLuint GLenum GLsizei length
GLenum GLuint GLintptr offset
GLfloat GLfloat GLfloat GLfloat h
GLsizei const GLchar *const * path
static const QRectF boundingRect(const QPointF *points, int pointCount)
static void setCapStyle(int cap_style, GC gc)
const QVectorPath & qtVectorPathForPath(const QPainterPath &path)
Q_GUI_EXPORT QDataStream & operator<<(QDataStream &, const QPainterPath &)
Q_GUI_EXPORT QDataStream & operator>>(QDataStream &, QPainterPath &)
bool operator==(const QRandomGenerator &rng1, const QRandomGenerator &rng2)
static bool operator&(QSortFilterProxyModelPrivate::Direction a, QSortFilterProxyModelPrivate::Direction b)
#define Q_DECLARE_TYPEINFO(TYPE, FLAGS)
QUrl::FormattingOptions & operator|=(QUrl::FormattingOptions &i, QUrl::ComponentFormattingOptions f)
static bool translate(xcb_connection_t *connection, xcb_window_t child, xcb_window_t parent, int *x, int *y)
scene addText("Hello, world!")
scene addRect(QRectF(-10, -10, 20, 20))