aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrook Cronin <brook.cronin@qt.io>2022-04-26 14:50:29 +0200
committerThomas Hartmann <thomas.hartmann@qt.io>2022-04-26 16:40:29 +0000
commit7a5cfebc9d4dd35d548f47d3ce8188efee83d2c9 (patch)
tree2f108e70594d5af4516ba0616af14eb51d77aa1b
parent8908a38bfb0aa5d3f566455344c33cf8ec2cee99 (diff)
Rework QtDS Splash Screen to show telemetry options
* clean up Design to a more minimal style * remove some unused components Change-Id: I37af39a1cae6b6f14f769383ac73c00570729f4f Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/ColorOverlayEffect.qml36
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/EllipseItem.qml201
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/FastBlurEffect.qml36
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/MyEllipse.qml46
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/PushButton.ui.qml117
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/RectangleItem.qml418
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/Splash_Image25d.qml24
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/Welcome_splash.qml303
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/main.qml2
9 files changed, 1078 insertions, 105 deletions
diff --git a/src/plugins/studiowelcome/qml/splashscreen/ColorOverlayEffect.qml b/src/plugins/studiowelcome/qml/splashscreen/ColorOverlayEffect.qml
new file mode 100644
index 0000000000..6b67005162
--- /dev/null
+++ b/src/plugins/studiowelcome/qml/splashscreen/ColorOverlayEffect.qml
@@ -0,0 +1,36 @@
+/****************************************************************************
+**
+** Copyright (C) 2020 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of Qt Quick Designer Components.
+**
+** $QT_BEGIN_LICENSE:GPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 or (at your option) any later version
+** approved by the KDE Free Qt Foundation. The licenses are as published by
+** the Free Software Foundation and appearing in the file LICENSE.GPL3
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-3.0.html.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.0
+import Qt5Compat.GraphicalEffects
+
+ColorOverlay {
+ id: colorOverlay
+ color: "#80fff000"
+}
diff --git a/src/plugins/studiowelcome/qml/splashscreen/EllipseItem.qml b/src/plugins/studiowelcome/qml/splashscreen/EllipseItem.qml
new file mode 100644
index 0000000000..2ce07cab31
--- /dev/null
+++ b/src/plugins/studiowelcome/qml/splashscreen/EllipseItem.qml
@@ -0,0 +1,201 @@
+/****************************************************************************
+**
+** Copyright (C) 2021 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of Qt Quick Studio Components.
+**
+** $QT_BEGIN_LICENSE:GPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 or (at your option) any later version
+** approved by the KDE Free Qt Foundation. The licenses are as published by
+** the Free Software Foundation and appearing in the file LICENSE.GPL3
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-3.0.html.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.10
+import QtQuick.Shapes 1.0
+
+/*!
+ \qmltype EllipseItem
+ \inqmlmodule QtQuick.Studio.Components
+ \since QtQuick.Studio.Components 1.0
+ \inherits Shape
+
+ \brief A filled ellipse with an optional border.
+*/
+
+Shape {
+ id: root
+ width: 200
+ height: 150
+
+/*!
+ The gradient of the rectangle fill color.
+
+ By default, no gradient is enabled and the value is null. In this case, the
+ fill uses a solid color based on the value of \l fillColor.
+
+ When set, \l fillColor is ignored and filling is done using one of the
+ \l ShapeGradient subtypes.
+
+ \note The \l Gradient type cannot be used here. Rather, prefer using one of
+ the advanced subtypes, like \l LinearGradient.
+*/
+ property alias gradient: path.fillGradient
+
+/*!
+ The style of the rectangle border.
+
+ \value ShapePath.SolidLine
+ A solid line. This is the default value.
+ \value ShapePath.DashLine
+ Dashes separated by a few pixels.
+ The \l dashPattern property specifies the dash pattern.
+
+ \sa Qt::PenStyle
+*/
+ property alias strokeStyle: path.strokeStyle
+
+/*!
+ The width of the border of the rectangle.
+
+ The default value is 4.
+
+ A width of 1 creates a thin line. For no line, use a negative value or a
+ transparent color.
+
+ \note The width of the rectangle's border does not affect the geometry of
+ the rectangle itself or its position relative to other items if anchors are
+ used.
+
+ The border is rendered within the rectangle's boundaries.
+*/
+ property alias strokeWidth: path.strokeWidth
+
+/*!
+ The color used to draw the border of the rectangle.
+
+ When set to \c transparent, no line is drawn.
+
+ The default value is \c red.
+
+ \sa QColor
+*/
+ property alias strokeColor: path.strokeColor
+
+/*!
+ The dash pattern of the rectangle border specified as the dashes and the
+ gaps between them.
+
+ The dash pattern is specified in units of the pen's width. That is, a dash
+ with the length 5 and width 10 is 50 pixels long.
+
+ The default value is (4, 2), meaning a dash of 4 * \l strokeWidth pixels
+ followed by a space of 2 * \l strokeWidth pixels.
+
+ \sa QPen::setDashPattern()
+*/
+ property alias dashPattern: path.dashPattern
+
+/*!
+ The rectangle fill color.
+
+ A gradient for the fill can be specified by using \l gradient. If both a
+ color and a gradient are specified, the gradient is used.
+
+ When set to \c transparent, no filling occurs.
+
+ The default value is \c white.
+*/
+ property alias fillColor: path.fillColor
+
+/*!
+ The starting point of the dash pattern for the rectangle border.
+
+ The offset is measured in terms of the units used to specify the dash
+ pattern. For example, a pattern where each stroke is four units long,
+ followed by a gap of two units, will begin with the stroke when drawn
+ as a line. However, if the dash offset is set to 4.0, any line drawn
+ will begin with the gap. Values of the offset up to 4.0 will cause part
+ of the stroke to be drawn first, and values of the offset between 4.0 and
+ 6.0 will cause the line to begin with part of the gap.
+
+ The default value is 0.
+
+ \sa QPen::setDashOffset()
+*/
+ property alias dashOffset: path.dashOffset
+
+ layer.enabled: root.antialiasing
+ layer.smooth: root.antialiasing
+ layer.samples: root.antialiasing ? 4 : 0
+
+/*!
+ The border is rendered within the rectangle's boundaries, outside of them,
+ or on top of them.
+*/
+ property int borderMode: 0
+
+ property real borderOffset: {
+ if (root.borderMode === 0)
+ return root.strokeWidth * 0.5
+ if (root.borderMode === 1)
+ return 0
+
+ return -root.strokeWidth * 0.5
+ }
+
+ Item {
+ anchors.fill: parent
+ anchors.margins: {
+ if (root.borderMode === 0)
+ return 0
+ if (root.borderMode === 1)
+ return -root.strokeWidth * 0.5
+
+ return -root.strokeWidth
+ }
+ }
+
+ ShapePath {
+ id: path
+
+ joinStyle: ShapePath.MiterJoin
+ strokeWidth: 4
+ strokeColor: "red"
+ startX: root.width * 0.5
+ startY: root.borderOffset
+
+ PathArc {
+ x: path.startX
+ y: root.height - root.borderOffset
+ radiusX: root.width * 0.5 - root.borderOffset
+ radiusY: root.height * 0.5 - root.borderOffset
+ useLargeArc: true
+ }
+
+ PathArc {
+ x: path.startX
+ y: path.startY
+ radiusX: root.width * 0.5 - root.borderOffset
+ radiusY: root.height * 0.5 - root.borderOffset
+ useLargeArc: true
+ }
+
+ }
+}
diff --git a/src/plugins/studiowelcome/qml/splashscreen/FastBlurEffect.qml b/src/plugins/studiowelcome/qml/splashscreen/FastBlurEffect.qml
new file mode 100644
index 0000000000..353fd1ddca
--- /dev/null
+++ b/src/plugins/studiowelcome/qml/splashscreen/FastBlurEffect.qml
@@ -0,0 +1,36 @@
+/****************************************************************************
+**
+** Copyright (C) 2020 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of Qt Quick Designer Components.
+**
+** $QT_BEGIN_LICENSE:GPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 or (at your option) any later version
+** approved by the KDE Free Qt Foundation. The licenses are as published by
+** the Free Software Foundation and appearing in the file LICENSE.GPL3
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-3.0.html.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.8
+import Qt5Compat.GraphicalEffects
+
+FastBlur {
+ id: fastBlur
+ radius: 20
+}
diff --git a/src/plugins/studiowelcome/qml/splashscreen/MyEllipse.qml b/src/plugins/studiowelcome/qml/splashscreen/MyEllipse.qml
new file mode 100644
index 0000000000..b1195826ba
--- /dev/null
+++ b/src/plugins/studiowelcome/qml/splashscreen/MyEllipse.qml
@@ -0,0 +1,46 @@
+/****************************************************************************
+**
+** Copyright (C) 2022 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of Qt Creator.
+**
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 as published by the Free Software
+** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-3.0.html.
+**
+****************************************************************************/
+import QtQuick 2.15
+import QtQuick.Controls 2.15
+import QtQuick.Layouts 1.15
+import StudioFonts 1.0
+import projectmodel 1.0
+import usagestatistics 1.0
+
+EllipseItem {
+ id: ellipse
+ width: 529
+ height: 391
+ opacity: 0.495
+ layer.enabled: true
+ layer.effect: FastBlurEffect {
+ id: fastBlur
+ radius: 66
+ transparentBorder: true
+ cached: true
+ }
+ fillColor: "#878787"
+ strokeColor: "#00ff0000"
+}
diff --git a/src/plugins/studiowelcome/qml/splashscreen/PushButton.ui.qml b/src/plugins/studiowelcome/qml/splashscreen/PushButton.ui.qml
new file mode 100644
index 0000000000..968fdb1828
--- /dev/null
+++ b/src/plugins/studiowelcome/qml/splashscreen/PushButton.ui.qml
@@ -0,0 +1,117 @@
+/****************************************************************************
+**
+** Copyright (C) 2022 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of Qt Creator.
+**
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 as published by the Free Software
+** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-3.0.html.
+**
+****************************************************************************/
+import QtQuick 2.15
+import QtQuick.Templates 2.15
+
+Button {
+ id: control
+
+ implicitWidth: Math.max(
+ buttonBackground ? buttonBackground.implicitWidth : 0,
+ textItem.implicitWidth + leftPadding + rightPadding)
+ implicitHeight: Math.max(
+ buttonBackground ? buttonBackground.implicitHeight : 0,
+ textItem.implicitHeight + topPadding + bottomPadding)
+ leftPadding: 4
+ rightPadding: 4
+
+ text: "My Button"
+ property alias fontpixelSize: textItem.font.pixelSize
+ property bool forceHover: false
+ state: "normal"
+
+ background: buttonBackground
+ Rectangle {
+ id: buttonBackground
+ color: "#00000000"
+ implicitWidth: 100
+ implicitHeight: 40
+ opacity: enabled ? 1 : 0.3
+ radius: 2
+ border.color: "#047eff"
+ anchors.fill: parent
+ }
+
+ contentItem: textItem
+
+ Text {
+ id: textItem
+ text: control.text
+ font.pixelSize: 18
+
+ opacity: enabled ? 1.0 : 0.3
+ color: "#ffffff"
+ horizontalAlignment: Text.AlignHCenter
+ verticalAlignment: Text.AlignVCenter
+ rightPadding: 5
+ leftPadding: 5
+ }
+
+ states: [
+ State {
+ name: "normal"
+ when: !control.down && !control.hovered && !control.forceHover
+
+ PropertyChanges {
+ target: buttonBackground
+ color: "#323232"
+ border.color: "#868686"
+ }
+
+ PropertyChanges {
+ target: textItem
+ color: "#ffffff"
+ }
+ },
+ State {
+ name: "hover"
+ when: (control.hovered || control.forceHover) && !control.down
+ PropertyChanges {
+ target: textItem
+ color: "#ffffff"
+ }
+
+ PropertyChanges {
+ target: buttonBackground
+ color: "#474747"
+ border.color: "#adadad"
+ }
+ },
+ State {
+ name: "activeQds"
+ when: control.down
+ PropertyChanges {
+ target: textItem
+ color: "#111111"
+ }
+
+ PropertyChanges {
+ target: buttonBackground
+ color: "#2e769e"
+ border.color: "#2e769e"
+ }
+ }
+ ]
+}
diff --git a/src/plugins/studiowelcome/qml/splashscreen/RectangleItem.qml b/src/plugins/studiowelcome/qml/splashscreen/RectangleItem.qml
new file mode 100644
index 0000000000..b2bd1d1ae8
--- /dev/null
+++ b/src/plugins/studiowelcome/qml/splashscreen/RectangleItem.qml
@@ -0,0 +1,418 @@
+/****************************************************************************
+**
+** Copyright (C) 2021 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of Qt Quick Studio Components.
+**
+** $QT_BEGIN_LICENSE:GPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 or (at your option) any later version
+** approved by the KDE Free Qt Foundation. The licenses are as published by
+** the Free Software Foundation and appearing in the file LICENSE.GPL3
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-3.0.html.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.10
+import QtQuick.Shapes 1.0
+
+/*!
+ \qmltype RectangleItem
+ \inqmlmodule QtQuick.Studio.Components
+ \since QtQuick.Studio.Components 1.0
+ \inherits Shape
+
+ \brief A filled rectangle with an optional border.
+
+ Rectangle items are used to fill areas with solid color or gradients and
+ to provide a rectangular border.
+
+ Each Rectangle item is painted using either a solid fill color, specified
+ using the \l fillColor property, or a gradient, defined using one of the
+ \l ShapeGradient subtypes and set using the \l gradient property.
+ If both a color and a gradient are specified, the gradient is used.
+
+ An optional border can be added to a rectangle with its own color and
+ thickness by setting the \l strokeColor and \l strokeWidth properties.
+ Setting the color to \c transparent creates a border without a fill color.
+
+ Rounded rectangles can be drawn using the \l radius property. The radius
+ can also be specified separately for each corner. Because this introduces
+ curved edges to the corners of a rectangle, it may be appropriate to set
+ the \c antialiasing property that is inherited from \l Item to improve the
+ appearance of the rectangle.
+
+ \section2 Example Usage
+
+ You can use the Rectangle component in \QDS to create different kinds of
+ rectangles.
+
+ \image studio-rectangle.png
+
+ The QML code looks as follows:
+
+ \code
+ RectangleItem {
+ id: rectangle
+ gradient: RadialGradient {
+ focalRadius: 0
+ centerY: 38.5
+ focalY: 38.5
+ centerX: 51.5
+ centerRadius: 38.5
+ GradientStop {
+ position: 0
+ color: "#ffffff"
+ }
+
+ GradientStop {
+ position: 1
+ color: "#000000"
+ }
+ focalX: 51.5
+ }
+ bottomRightRadius: 0
+ topLeftRadius: 0
+ strokeColor: "gray"
+ }
+
+ RectangleItem {
+ id: rectangle1
+ gradient: LinearGradient {
+ y1: 0
+ y2: 77
+ x2: 103
+ x1: 0
+ GradientStop {
+ position: 0
+ color: "#ffffff"
+ }
+
+ GradientStop {
+ position: 1
+ color: "#000000"
+ }
+ }
+ topRightRadius: 0
+ bottomLeftRadius: 0
+ strokeColor: "#808080"
+ }
+
+ RectangleItem {
+ id: rectangle2
+ topLeftRadius: 0
+ bottomRightRadius: 0
+ fillColor: "#d3d3d3"
+ strokeColor: "#808080"
+ }
+
+ RectangleItem {
+ id: rectangle3
+ fillColor: "#000000"
+ gradient: LinearGradient {
+ y1: 0
+ y2: 77
+ x2: 103
+ x1: 0
+ GradientStop {
+ position: 0
+ color: "#000000"
+ }
+
+ GradientStop {
+ position: 1
+ color: "#fdf9f9"
+ }
+ }
+ topRightRadius: 0
+ bottomLeftRadius: 0
+ strokeColor: "#808080"
+ }
+ \endcode
+*/
+
+Shape {
+ id: root
+ width: 200
+ height: 150
+
+/*!
+ The radius used to draw rounded corners.
+
+ The default value is 10.
+
+ If radius is non-zero, the corners will be rounded, otherwise they will
+ be sharp. The radius can also be specified separately for each corner by
+ using the \l bottomLeftRadius, \l bottomRightRadius, \l topLeftRadius, and
+ \l topRightRadius properties.
+*/
+ property int radius: 10
+
+/*!
+ The radius of the top left rectangle corner.
+*/
+ property int topLeftRadius: root.radius
+
+/*!
+ The radius of the bottom left rectangle corner.
+*/
+ property int bottomLeftRadius: root.radius
+
+/*!
+ The radius of the top right rectangle corner.
+*/
+ property int topRightRadius: root.radius
+
+/*!
+ The radius of the bottom right rectangle corner.
+*/
+ property int bottomRightRadius: root.radius
+
+/*!
+ The gradient of the rectangle fill color.
+
+ By default, no gradient is enabled and the value is null. In this case, the
+ fill uses a solid color based on the value of \l fillColor.
+
+ When set, \l fillColor is ignored and filling is done using one of the
+ \l ShapeGradient subtypes.
+
+ \note The \l Gradient type cannot be used here. Rather, prefer using one of
+ the advanced subtypes, like \l LinearGradient.
+*/
+ property alias gradient: path.fillGradient
+
+/*!
+ The style of the rectangle border.
+
+ \value ShapePath.SolidLine
+ A solid line. This is the default value.
+ \value ShapePath.DashLine
+ Dashes separated by a few pixels.
+ The \l dashPattern property specifies the dash pattern.
+
+ \sa Qt::PenStyle
+*/
+ property alias strokeStyle: path.strokeStyle
+
+/*!
+ The width of the border of the rectangle.
+
+ The default value is 4.
+
+ A width of 1 creates a thin line. For no line, use a negative value or a
+ transparent color.
+
+ \note The width of the rectangle's border does not affect the geometry of
+ the rectangle itself or its position relative to other items if anchors are
+ used.
+
+ The border is rendered within the rectangle's boundaries.
+*/
+ property alias strokeWidth: path.strokeWidth
+
+/*!
+ The color used to draw the border of the rectangle.
+
+ When set to \c transparent, no line is drawn.
+
+ The default value is \c red.
+
+ \sa QColor
+*/
+ property alias strokeColor: path.strokeColor
+
+/*!
+ The dash pattern of the rectangle border specified as the dashes and the
+ gaps between them.
+
+ The dash pattern is specified in units of the pen's width. That is, a dash
+ with the length 5 and width 10 is 50 pixels long.
+
+ The default value is (4, 2), meaning a dash of 4 * \l strokeWidth pixels
+ followed by a space of 2 * \l strokeWidth pixels.
+
+ \sa QPen::setDashPattern()
+*/
+ property alias dashPattern: path.dashPattern
+
+
+ property alias joinStyle: path.joinStyle
+
+/*!
+ The rectangle fill color.
+
+ A gradient for the fill can be specified by using \l gradient. If both a
+ color and a gradient are specified, the gradient is used.
+
+ When set to \c transparent, no filling occurs.
+
+ The default value is \c white.
+*/
+ property alias fillColor: path.fillColor
+
+/*!
+ The starting point of the dash pattern for the rectangle border.
+
+ The offset is measured in terms of the units used to specify the dash
+ pattern. For example, a pattern where each stroke is four units long,
+ followed by a gap of two units, will begin with the stroke when drawn
+ as a line. However, if the dash offset is set to 4.0, any line drawn
+ will begin with the gap. Values of the offset up to 4.0 will cause part
+ of the stroke to be drawn first, and values of the offset between 4.0 and
+ 6.0 will cause the line to begin with part of the gap.
+
+ The default value is 0.
+
+ \sa QPen::setDashOffset()
+*/
+ property alias dashOffset: path.dashOffset
+
+/*!
+ Whether the border corner is beveled.
+*/
+ property bool bevel: false
+
+/*!
+ The bevel of the top left border corner.
+
+ \sa bevel
+*/
+ property bool topLeftBevel: root.bevel
+
+/*!
+ The bevel of the top right border corner.
+
+ \sa bevel
+*/
+ property bool topRightBevel: root.bevel
+
+/*!
+ The bevel of the bottom right border corner.
+
+ \sa bevel
+*/
+ property bool bottomRightBevel: root.bevel
+
+/*!
+ The bevel of the bottom left border corner.
+
+ \sa bevel
+*/
+ property bool bottomLeftBevel: root.bevel
+
+ layer.enabled: root.antialiasing
+ layer.smooth: root.antialiasing
+ layer.samples: root.antialiasing ? 4 : 0
+
+/*!
+ The border is rendered within the rectangle's boundaries, outside of them,
+ or on top of them.
+*/
+ property int borderMode: 0
+
+ property real borderOffset: {
+ if (root.borderMode === 0)
+ return root.strokeWidth * 0.5
+ if (root.borderMode === 1)
+ return 0
+
+ return -root.strokeWidth * 0.5
+ }
+
+ Item {
+ anchors.fill: parent
+ anchors.margins: {
+ if (root.borderMode === 0)
+ return 0
+ if (root.borderMode === 1)
+ return -root.strokeWidth * 0.5
+
+ return -root.strokeWidth
+ }
+ }
+
+ ShapePath {
+ id: path
+
+ property int __maxRadius: Math.floor(Math.min(root.width, root.height) / 2)
+ property int __topLeftRadius: Math.min(root.topLeftRadius, path.__maxRadius)
+ property int __topRightRadius: Math.min(root.topRightRadius, path.__maxRadius)
+ property int __bottomRightRadius: Math.min(root.bottomRightRadius, path.__maxRadius)
+ property int __bottomLeftRadius: Math.min(root.bottomLeftRadius, path.__maxRadius)
+
+ joinStyle: ShapePath.MiterJoin
+
+ strokeWidth: 4
+ strokeColor: "red"
+
+ startX: path.__topLeftRadius + root.borderOffset
+ startY: root.borderOffset
+
+ PathLine {
+ x: root.width - path.__topRightRadius - root.borderOffset
+ y: root.borderOffset
+ }
+
+ PathArc {
+ x: root.width - root.borderOffset
+ y: path.__topRightRadius + root.borderOffset
+
+ radiusX: root.topRightBevel ? 50000 : path.__topRightRadius
+ radiusY: root.topRightBevel ? 50000 : path.__topRightRadius
+ }
+
+ PathLine {
+ x: root.width - root.borderOffset
+ y: root.height - path.__bottomRightRadius - root.borderOffset
+ }
+
+ PathArc {
+ x: root.width - path.__bottomRightRadius - root.borderOffset
+ y: root.height - root.borderOffset
+
+ radiusX: root.bottomRightBevel ? 50000 : path.__bottomRightRadius
+ radiusY: root.bottomRightBevel ? 50000 : path.__bottomRightRadius
+ }
+
+ PathLine {
+ x: path.__bottomLeftRadius + root.borderOffset
+ y: root.height - root.borderOffset
+ }
+
+ PathArc {
+ x: root.borderOffset
+ y: root.height - path.__bottomLeftRadius - root.borderOffset
+
+ radiusX: root.bottomLeftBevel ? 50000 : path.__bottomLeftRadius
+ radiusY: root.bottomLeftBevel ? 50000 : path.__bottomLeftRadius
+ }
+
+ PathLine {
+ x: root.borderOffset
+ y: path.__topLeftRadius + root.borderOffset
+ }
+
+ PathArc {
+ x: path.__topLeftRadius + root.borderOffset
+ y: root.borderOffset
+
+ radiusX: root.topLeftBevel ? 50000 : path.__topLeftRadius
+ radiusY: root.topLeftBevel ? 50000 : path.__topLeftRadius
+ }
+ }
+}
diff --git a/src/plugins/studiowelcome/qml/splashscreen/Splash_Image25d.qml b/src/plugins/studiowelcome/qml/splashscreen/Splash_Image25d.qml
index f0ae6c2d8b..38054b52f9 100644
--- a/src/plugins/studiowelcome/qml/splashscreen/Splash_Image25d.qml
+++ b/src/plugins/studiowelcome/qml/splashscreen/Splash_Image25d.qml
@@ -22,7 +22,6 @@
** be met: https://www.gnu.org/licenses/gpl-3.0.html.
**
****************************************************************************/
-
import QtQuick 2.3
Rectangle {
@@ -30,6 +29,7 @@ Rectangle {
width: 460
height: 480
color: "transparent"
+ scale: 1.2
layer.enabled: true
layer.textureSize: Qt.size(width * 2, height * 2)
@@ -40,21 +40,27 @@ Rectangle {
anchors.centerIn: parent
width: 460
height: 480
+ visible: true
+ anchors.verticalCenterOffset: -1
+ anchors.horizontalCenterOffset: 14
+ clip: true
layer.enabled: true
layer.textureSize: Qt.size(width * 2, height * 2)
layer.smooth: true
Splash_Image2d_png {
- x: 25
- y: 15
- antialiasing: false
- scale: 1.4
- transform: Matrix4x4 {
- matrix: Qt.matrix4x4(1.12606, 0.06371, 0, 0, 0.26038, 0.90592,
- 0, 0, 0.00000, 0.0000, 1.0, 0,
- 0.00121, -0.00009, 0.0, 1)
+ x: -22
+ y: -33
+ width: 461
+ height: 427
+ layer.enabled: true
+ layer.effect: ColorOverlayEffect {
+ id: colorOverlay
+ visible: true
+ color: "#41cd52"
}
+ scale: 1
}
}
}
diff --git a/src/plugins/studiowelcome/qml/splashscreen/Welcome_splash.qml b/src/plugins/studiowelcome/qml/splashscreen/Welcome_splash.qml
index 24fba429ea..89d5113187 100644
--- a/src/plugins/studiowelcome/qml/splashscreen/Welcome_splash.qml
+++ b/src/plugins/studiowelcome/qml/splashscreen/Welcome_splash.qml
@@ -22,23 +22,30 @@
** be met: https://www.gnu.org/licenses/gpl-3.0.html.
**
****************************************************************************/
-
import QtQuick 2.15
import QtQuick.Controls 2.15
import QtQuick.Layouts 1.15
import StudioFonts 1.0
import projectmodel 1.0
import usagestatistics 1.0
+import QtQuick.Shapes 1.0
Rectangle {
id: welcome_splash
anchors.fill: parent
+ clip: true
gradient: Gradient {
orientation: Gradient.Horizontal
- GradientStop { position: 0.0; color: "#1d212a" }
- GradientStop { position: 1.0; color: "#232c56" }
+ GradientStop {
+ position: 0.0
+ color: "#1d212a"
+ }
+ GradientStop {
+ position: 1.0
+ color: "#232c56"
+ }
}
signal goNext
@@ -47,52 +54,118 @@ Rectangle {
property bool doNotShowAgain: true
property bool loadingPlugins: true
+
+ width: 600
+ height: 720
+ visible: true
color: "#1d212a"
- Image {
- id: logo
- anchors.top: parent.top
- anchors.left: parent.left
- anchors.margins: 10
- width: 66 * 2
- height: 50 * 2
- smooth: true
- source: "welcome_windows/logo.png"
+ Rectangle {
+ id: qtGreen
+ color: "#515151"
+ anchors.fill: parent
+ anchors.rightMargin: 0
+ anchors.bottomMargin: 0
+ anchors.leftMargin: 0
+ anchors.topMargin: 0
}
+ RectangleItem {
+ id: background
+ opacity: 0.825
+ anchors.fill: parent
+ gradient: LinearGradient {
+ x1: 0
+ stops: [
+ GradientStop {
+ position: 0
+ color: "#29323c"
+ },
+ GradientStop {
+ position: 1
+ color: "#485563"
+ }
+ ]
+ x2: 640
+ y2: 800
+ y1: 0
+ }
+ topRightRadius: 0
+ anchors.topMargin: 0
+ bottomLeftRadius: 0
+ borderMode: 1
+ fillColor: "#2d2d2d"
+ bottomRightRadius: 0
+ topLeftRadius: 0
+ topRightBevel: true
+ bottomLeftBevel: true
+ strokeColor: "#00ff0000"
+ }
- Text {
- id: qt_design_studio_text
- anchors.top: logo.top
- anchors.left: logo.right
- anchors.leftMargin: 10
- color: "#25709a"
- text: qsTr("Qt Design Studio")
- font.pixelSize: 36
- font.family: StudioFonts.titilliumWeb_light
+ RectangleItem {
+ id: topBar
+ opacity: 0.239
+ anchors.fill: parent
+ anchors.bottomMargin: 550
+ strokeColor: "#00ff0000"
+ bottomRightRadius: 0
+ topRightBevel: true
+ fillColor: "#2d2d2d"
+ bottomLeftRadius: 0
+ topRightRadius: 0
+ borderMode: 1
+ anchors.topMargin: 0
+ topLeftRadius: 0
+ bottomLeftBevel: true
}
- Text {
- id: qt_design_studio_version_text
- anchors.left: qt_design_studio_text.right
- anchors.baseline: qt_design_studio_text.baseline
- anchors.leftMargin: 10
- color: "#25709a"
- text: usageStatisticModel.version
+ RectangleItem {
+ id: bottomBar
+ opacity: 0.534
+ visible: true
+ anchors.fill: parent
+ anchors.rightMargin: 0
+ anchors.leftMargin: 0
+ strokeColor: "#00ff0000"
+ anchors.bottomMargin: 0
+ bottomRightRadius: 0
+ bottomLeftRadius: 0
+ fillColor: "#2d2d2d"
+ topRightBevel: true
+ topRightRadius: 0
+ borderMode: 1
+ anchors.topMargin: 539
+ topLeftRadius: 0
+ bottomLeftBevel: true
+ }
- font.family: StudioFonts.titilliumWeb_light
- font.pixelSize: 36
+ MyEllipse {
+ id: ellipse
+ x: 0
+ y: 204
+ width: 640
+ height: 391
+ opacity: 0.05
+ }
+
+ Image {
+ id: logo
+ anchors.top: parent.top
+ anchors.margins: 10
+ smooth: true
+ source: "welcome_windows/logo.png"
+ anchors.topMargin: 10
+ anchors.horizontalCenter: parent.horizontalCenter
}
Text {
id: license_variant_text
- anchors.left: qt_design_studio_text.left
- anchors.top: qt_design_studio_text.bottom
- anchors.leftMargin: 5
+ anchors.top: designStudioVersion.bottom
color: "#ffffff"
font.family: StudioFonts.titilliumWeb_light
font.pixelSize: 20
+ anchors.horizontalCenter: parent.horizontalCenter
text: {
if (projectModel.communityVersion)
@@ -111,56 +184,94 @@ Rectangle {
}
}
- Dof_Effect {
- id: dof_effect
- anchors.top: qt_design_studio_text.bottom
- anchors.horizontalCenter: welcome_splash.horizontalCenter
- width: 442
- height: 480
- maskBlurSamples: 64
- maskBlurRadius: 32
-
- Splash_Image25d {
- id: animated_artwork
- width: dof_effect.width
- height: dof_effect.height
- clip: true
- }
+ //DOF seems to do nothing, we should probably just remove it.
+ Splash_Image25d {
+ id: animated_artwork
+ width: 628
+ height: 377
+ anchors.top: license_variant_text.bottom
+ anchors.horizontalCenterOffset: 0
+ scale: 1.1
+ anchors.horizontalCenter: parent.horizontalCenter
+ anchors.topMargin: 50
+ clip: true
}
Text {
id: help_us_text
anchors.left: welcome_splash.left
anchors.right: parent.right
- anchors.leftMargin: 10
- anchors.top: dof_effect.bottom
- anchors.topMargin: 10
+ anchors.leftMargin: 20
+ anchors.top: bottomBar.top
color: "#FFFFFF"
- text: qsTr("Before we let you move on to your wonderful designs, help us make Qt Design Studio even better by letting us know how you're using it.")
-
+ text: qsTr("Before we let you move on to your wonderful designs, help us make Qt Design Studio even betterby letting us know how you're using it. To do this, we would like to turn on automatic collection of pseudonymized Analytics and Crash Report Data.")
font.family: StudioFonts.titilliumWeb_light
- font.pixelSize: 18
+ font.pixelSize: 16
+ horizontalAlignment: Text.AlignHCenter
+ verticalAlignment: Text.AlignVCenter
wrapMode: Text.WordWrap
- anchors.rightMargin: 10
+ anchors.topMargin: 25
+ anchors.rightMargin: 20
+ }
+
+ RowLayout {
+ anchors.right: parent.right
+ anchors.bottom: welcome_splash.bottom
+ anchors.rightMargin: 20
+ anchors.bottomMargin: 20
+ spacing: 20
+
+ PushButton {
+ text: qsTr("Turn Off")
+ fontpixelSize: 14
+ onClicked: {
+ usageStatisticModel.setTelemetryEnabled(false)
+ usageStatisticModel.setCrashReporterEnabled(false)
+ welcome_splash.closeClicked()
+ }
+ }
+
+ PushButton {
+ text: qsTr("Turn On")
+ forceHover: false
+ fontpixelSize: 14
+ onClicked: {
+ usageStatisticModel.setTelemetryEnabled(true)
+ usageStatisticModel.setCrashReporterEnabled(true)
+ welcome_splash.closeClicked()
+ }
+ }
}
- ColumnLayout {
- id: columnLayout
+ PushButton {
+ y: 430
+ text: qsTr("Learn More")
anchors.left: parent.left
- anchors.top: help_us_text.bottom
- anchors.leftMargin: 10
- anchors.topMargin: 20
- spacing: 3
+ anchors.bottom: parent.bottom
+ fontpixelSize: 14
+ anchors.bottomMargin: 20
+ anchors.leftMargin: 20
+ onClicked: Qt.openUrlExternally(
+ "https://www.qt.io/terms-conditions/telemetry-privacy")
+ }
+
+ Row {
+ y: 690
+ visible: false
+ anchors.horizontalCenter: parent.horizontalCenter
+ spacing: 20
+ layoutDirection: Qt.LeftToRight
CheckBox {
- visible: false
+ visible: true
id: usageStatisticCheckBox
text: qsTr("Send Usage Statistics")
checked: usageStatisticModel.usageStatisticEnabled
padding: 0
spacing: 12
- onCheckedChanged: usageStatisticModel.setTelemetryEnabled(usageStatisticCheckBox.checked)
+ onCheckedChanged: usageStatisticModel.setTelemetryEnabled(
+ usageStatisticCheckBox.checked)
contentItem: Text {
text: usageStatisticCheckBox.text
@@ -171,15 +282,17 @@ Rectangle {
}
CheckBox {
- visible: false
+ visible: true
id: crashReportCheckBox
text: qsTr("Send Crash Reports")
spacing: 12
checked: usageStatisticModel.crashReporterEnabled
onCheckedChanged: {
- usageStatisticModel.setCrashReporterEnabled(crashReportCheckBox.checked)
- welcome_splash.onPluginInitialized(true, crashReportCheckBox.checked)
+ usageStatisticModel.setCrashReporterEnabled(
+ crashReportCheckBox.checked)
+ welcome_splash.onPluginInitialized(true,
+ crashReportCheckBox.checked)
}
contentItem: Text {
@@ -192,39 +305,39 @@ Rectangle {
}
}
- RowLayout {
- anchors.right: parent.right
- anchors.bottom: welcome_splash.bottom
- anchors.rightMargin: 10
- anchors.bottomMargin: 10
- spacing: 20
+ Row {
+ id: designStudioVersion
+ anchors.top: logo.bottom
+ anchors.topMargin: 5
+ spacing: 10
+ anchors.horizontalCenter: parent.horizontalCenter
- CustomButton {
- text: qsTr("Don't send")
- onClicked: {
- usageStatisticModel.setTelemetryEnabled(false)
- usageStatisticModel.setCrashReporterEnabled(false)
- welcome_splash.closeClicked()
- }
+ Text {
+ id: qt_design_studio_text
+ height: 45
+ color: "#ffffff"
+ text: qsTr("Qt Design Studio")
+ font.pixelSize: 36
+ horizontalAlignment: Text.AlignHCenter
+ verticalAlignment: Text.AlignVCenter
+ font.family: StudioFonts.titilliumWeb_light
}
- CustomButton {
- text: qsTr("Send analytics data")
- onClicked: {
- usageStatisticModel.setTelemetryEnabled(true)
- usageStatisticModel.setCrashReporterEnabled(true)
- welcome_splash.closeClicked()
- }
+ Text {
+ id: qt_design_studio_version_text
+ height: 45
+ color: "#fbfbfb"
+ text: usageStatisticModel.version
+ font.family: StudioFonts.titilliumWeb_light
+ font.pixelSize: 36
+ horizontalAlignment: Text.AlignHCenter
+ verticalAlignment: Text.AlignVCenter
}
}
+}
- CustomButton {
- y: 430
- text: qsTr("Learn More")
- anchors.left: parent.left
- anchors.bottom: parent.bottom
- anchors.bottomMargin: 10
- anchors.leftMargin: 10
- onClicked: Qt.openUrlExternally("https://www.qt.io/terms-conditions/telemetry-privacy")
- }
+/*##^##
+Designer {
+ D{i:0;formeditorZoom:1.33}D{i:22}
}
+##^##*/
diff --git a/src/plugins/studiowelcome/qml/splashscreen/main.qml b/src/plugins/studiowelcome/qml/splashscreen/main.qml
index 9ada7e7504..b60e4668cb 100644
--- a/src/plugins/studiowelcome/qml/splashscreen/main.qml
+++ b/src/plugins/studiowelcome/qml/splashscreen/main.qml
@@ -27,7 +27,7 @@ import QtQuick 2.0
Item {
id: root
- width: 720
+ width: 600
height: 720
signal closeClicked