![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
#include <qquickshape_p_p.h>
Public Types | |
enum | Dirty { DirtyPath = 0x01 , DirtyStrokeColor = 0x02 , DirtyStrokeWidth = 0x04 , DirtyFillColor = 0x08 , DirtyFillRule = 0x10 , DirtyStyle = 0x20 , DirtyDash = 0x40 , DirtyFillGradient = 0x80 , DirtyFillTransform = 0x100 , DirtyFillItem = 0x200 , DirtyAll = 0x3FF } |
![]() | |
typedef void(* | StaticMetaCallFunction) (QObject *, QMetaObject::Call, int, void **) |
using | ConnectionDataPointer = QExplicitlySharedDataPointer<ConnectionData> |
Static Public Member Functions | |
static QQuickShapePathPrivate * | get (QQuickShapePath *p) |
![]() | |
static QQuickPathPrivate * | get (QQuickPath *path) |
static const QQuickPathPrivate * | get (const QQuickPath *path) |
![]() | |
static bool | removeConnection (Connection *c) |
static QObjectPrivate * | get (QObject *o) |
static const QObjectPrivate * | get (const QObject *o) |
template<typename Func1, typename Func2> | |
static QMetaObject::Connection | connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot, Qt::ConnectionType type=Qt::AutoConnection) |
template<typename Func1, typename Func2> | |
static bool | disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot) |
static QMetaObject::Connection | connectImpl (const QObject *sender, int signal_index, const QObject *receiver, void **slot, QtPrivate::QSlotObjectBase *slotObj, int type, const int *types, const QMetaObject *senderMetaObject) |
static QMetaObject::Connection | connect (const QObject *sender, int signal_index, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type) |
static QMetaObject::Connection | connect (const QObject *sender, int signal_index, const QObject *receiver, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type) |
static bool | disconnect (const QObject *sender, int signal_index, void **slot) |
static bool | disconnect (const QObject *sender, int signal_index, const QObject *receiver, void **slot) |
Definition at line 91 of file qquickshape_p_p.h.
Enumerator | |
---|---|
DirtyPath | |
DirtyStrokeColor | |
DirtyStrokeWidth | |
DirtyFillColor | |
DirtyFillRule | |
DirtyStyle | |
DirtyDash | |
DirtyFillGradient | |
DirtyFillTransform | |
DirtyFillItem | |
DirtyAll |
Definition at line 96 of file qquickshape_p_p.h.
QQuickShapePathPrivate::QQuickShapePathPrivate | ( | ) |
Describes a Path and associated properties for stroking and filling.
\qmltype ShapePath
! \nativetype QQuickShapePath \inqmlmodule QtQuick.Shapes
\inherits Path
A \l Shape contains one or more ShapePath elements. At least one ShapePath is necessary in order to have a Shape output anything visible. A ShapePath itself is a \l Path with additional properties describing the stroking and filling parameters, such as the stroke width and color, the fill color or gradient, join and cap styles, and so on. As with ordinary \l Path objects, ShapePath also contains a list of path elements like \l PathMove, \l PathLine, \l PathCubic, \l PathQuad, \l PathArc, together with a starting position.
Any property changes in these data sets will be bubble up and change the output of the Shape. This means that it is simple and easy to change, or even animate, the starting and ending position, control points, or any stroke or fill parameters using the usual QML bindings and animation types like NumberAnimation.
In the following example the line join style changes automatically based on the value of joinStyleIndex:
\qml ShapePath { strokeColor: "black" strokeWidth: 16 fillColor: "transparent" capStyle: ShapePath.RoundCap
property int joinStyleIndex: 0
property variant styles: [ ShapePath.BevelJoin, ShapePath.MiterJoin, ShapePath.RoundJoin ]
joinStyle: styles[joinStyleIndex]
startX: 30 startY: 30 PathLine { x: 100; y: 100 } PathLine { x: 30; y: 100 } } \endqml
Once associated with a Shape, here is the output with a joinStyleIndex of 2 (ShapePath.RoundJoin):
Definition at line 158 of file qquickshape.cpp.
void QQuickShapePathPrivate::_q_fillGradientChanged | ( | ) |
Definition at line 461 of file qquickshape.cpp.
void QQuickShapePathPrivate::_q_fillItemDestroyed | ( | ) |
Definition at line 529 of file qquickshape.cpp.
void QQuickShapePathPrivate::_q_pathChanged | ( | ) |
|
inlinestatic |
Definition at line 121 of file qquickshape_p_p.h.
void QQuickShapePathPrivate::handleSceneChange | ( | ) |
Reimplemented from QObjectPrivate.
Definition at line 539 of file qquickshape.cpp.
int QQuickShapePathPrivate::dirty |
Definition at line 123 of file qquickshape_p_p.h.
QQuickShapePath::PathHints QQuickShapePathPrivate::pathHints |
Definition at line 125 of file qquickshape_p_p.h.
QQuickShapeStrokeFillParams QQuickShapePathPrivate::sfp |
Definition at line 124 of file qquickshape_p_p.h.