|
This patch adds 4 properties to the Rectangle: topLeftRadius,
topRightRadius, bottomLeftRadius and bottomRightRadius. These properties
can be used to get a Rectangle where the corners have different radii.
If the properties are not set or if they are zero, the value of the
property radius will be used to draw the corner. If radius is zero too,
the corner will be drawn normally.
The opportunity was used to rename some variables in the
QSGRectangleNode and comment the code. We now use float as the storage
type for small-valued numbers, to reduce memory usage, even though the
setters take qreal values. They lose precision during rendering anyway.
[ChangeLog][QtQuick][Rectangle] Rectangle can now render individual
radii on each corner.
Fixes: QTBUG-48774
Change-Id: Icba1f6a26da513c657b7b218adc9187afb085eda
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|