28 Q_DECLARE_PUBLIC(QQuickRectangleShape)
31 QQuickRectangleShapePrivate() =
default;
33 static QQuickRectangleShapePrivate *get(QQuickRectangleShape *p) {
return p->d_func(); }
35 void setTopLeftRadius(
int topLeftRadius, QQml::PropertyUtils::State propertyState);
36 void setTopRightRadius(
int topRightRadius, QQml::PropertyUtils::State propertyState);
37 void setBottomLeftRadius(
int bottomLeftRadius, QQml::PropertyUtils::State propertyState);
38 void setBottomRightRadius(
int bottomRightRadius, QQml::PropertyUtils::State propertyState);
40 void setTopLeftBevel(
bool topLeftBevel, QQml::PropertyUtils::State propertyState);
41 void setTopRightBevel(
bool topRightBevel, QQml::PropertyUtils::State propertyState);
42 void setBottomLeftBevel(
bool bottomLeftBevel, QQml::PropertyUtils::State propertyState);
43 void setBottomRightBevel(
bool bottomRightBevel, QQml::PropertyUtils::State propertyState);
45 void maybeUpdateElements();
47 void calculateIndependentRadii();
57 QQuickShapePath *shapePath =
nullptr;
59 QQuickPathLine *topPathLine =
nullptr;
60 QQuickPathMove *topPathMove =
nullptr;
61 QQuickPathArc *topRightPathArc =
nullptr;
62 QQuickPathLine *rightPathLine =
nullptr;
63 QQuickPathMove *rightPathMove =
nullptr;
64 QQuickPathArc *bottomRightPathArc =
nullptr;
65 QQuickPathLine *bottomPathLine =
nullptr;
66 QQuickPathMove *bottomPathMove =
nullptr;
67 QQuickPathArc *bottomLeftPathArc =
nullptr;
68 QQuickPathLine *leftPathLine =
nullptr;
69 QQuickPathArc *topLeftPathArc =
nullptr;
71 static const int defaultRadius = 10;
72 static const bool defaultDrawEdge =
true;
73 static const bool defaultBevel =
false;
75 int radius = defaultRadius;
76 int topLeftRadius = defaultRadius;
77 int topRightRadius = defaultRadius;
78 int bottomLeftRadius = defaultRadius;
79 int bottomRightRadius = defaultRadius;
80 int effectiveTopLeftRadius = 0;
81 int effectiveTopRightRadius = 0;
82 int effectiveBottomLeftRadius = 0;
83 int effectiveBottomRightRadius = 0;
85 bool explicitTopLeftRadius =
false;
86 bool explicitTopRightRadius =
false;
87 bool explicitBottomLeftRadius =
false;
88 bool explicitBottomRightRadius =
false;
89 bool drawTop = defaultDrawEdge;
90 bool drawRight = defaultDrawEdge;
91 bool drawBottom = defaultDrawEdge;
92 bool drawLeft = defaultDrawEdge;
93 bool bevel = defaultBevel;
94 bool topLeftBevel = defaultBevel;
95 bool topRightBevel = defaultBevel;
96 bool bottomLeftBevel = defaultBevel;
97 bool bottomRightBevel = defaultBevel;
99 bool explicitTopLeftBevel =
false;
100 bool explicitTopRightBevel =
false;
101 bool explicitBottomLeftBevel =
false;
102 bool explicitBottomRightBevel =
false;
103 qreal borderOffset = 0;
104 qreal borderRadiusAdjustment = 0;
105 Edge firstVisibleEdge = Edge::NEdges;
106 QQuickRectangleShape::BorderMode borderMode = QQuickRectangleShape::BorderMode::Inside;