aboutsummaryrefslogtreecommitdiffstats
path: root/src/imports/effects/designer/InnerShadowEffectSpecifics.qml
diff options
context:
space:
mode:
Diffstat (limited to 'src/imports/effects/designer/InnerShadowEffectSpecifics.qml')
-rw-r--r--src/imports/effects/designer/InnerShadowEffectSpecifics.qml123
1 files changed, 73 insertions, 50 deletions
diff --git a/src/imports/effects/designer/InnerShadowEffectSpecifics.qml b/src/imports/effects/designer/InnerShadowEffectSpecifics.qml
index 32ac0bd..8160925 100644
--- a/src/imports/effects/designer/InnerShadowEffectSpecifics.qml
+++ b/src/imports/effects/designer/InnerShadowEffectSpecifics.qml
@@ -1,6 +1,6 @@
/****************************************************************************
**
-** Copyright (C) 2020 The Qt Company Ltd.
+** Copyright (C) 2021 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of Qt Quick Designer Components.
@@ -27,9 +27,10 @@
**
****************************************************************************/
-import QtQuick 2.0
+import QtQuick 2.15
+import QtQuick.Layouts 1.15
import HelperWidgets 2.0
-import QtQuick.Layouts 1.0
+import StudioTheme 1.0 as StudioTheme
Column {
anchors.left: parent.left
@@ -40,10 +41,13 @@ Column {
anchors.right: parent.right
caption: qsTr("Inner Shadow Color")
- ColorEditor {
- caption: qsTr("Inner Shadow Color")
- backendValue: backendValues.color
- supportGradient: false
+ SectionLayout {
+ PropertyLabel { text: qsTr("Inner shadow color") }
+
+ ColorEditor {
+ backendValue: backendValues.color
+ supportGradient: false
+ }
}
}
@@ -53,75 +57,82 @@ Column {
caption: qsTr("Inner Shadow")
SectionLayout {
- rows: 2
- Label {
+ PropertyLabel {
text: qsTr("Radius")
- toolTip: qsTr("The softness of the shadow. A larger radius causes the edges of the "
+ tooltip: qsTr("The softness of the shadow. A larger radius causes the edges of the "
+ "shadow to appear more blurry.")
}
+
SecondColumnLayout {
SpinBox {
backendValue: backendValues.radius
- Layout.preferredWidth: 80
decimals: 1
minimumValue: 0
maximumValue: 100
stepSize: 1
+ implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ + StudioTheme.Values.actionIndicatorWidth
}
- ExpandingSpacer {
- }
+
+ ExpandingSpacer {}
}
- Label {
+ PropertyLabel {
text: qsTr("Samples")
- toolTip: qsTr("Samples per pixel for edge softening blur calculation. Ideally, "
+ tooltip: qsTr("Samples per pixel for edge softening blur calculation. Ideally, "
+ "this value should be twice as large as the highest required "
+ "radius value plus one.")
}
+
SecondColumnLayout {
SpinBox {
backendValue: backendValues.samples
- Layout.preferredWidth: 80
decimals: 0
minimumValue: 0
maximumValue: 201
stepSize: 1
+ implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ + StudioTheme.Values.actionIndicatorWidth
}
- ExpandingSpacer {
- }
+
+ ExpandingSpacer {}
}
- Label {
+ PropertyLabel {
text: qsTr("Spread")
- toolTip: qsTr("The part of the shadow color that is strengthened near the source "
+ tooltip: qsTr("The part of the shadow color that is strengthened near the source "
+ "edges.")
}
+
SecondColumnLayout {
SpinBox {
backendValue: backendValues.spread
- Layout.preferredWidth: 80
decimals: 2
minimumValue: 0
maximumValue: 1
stepSize: 0.1
+ implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ + StudioTheme.Values.actionIndicatorWidth
}
- ExpandingSpacer {
- }
+
+ ExpandingSpacer {}
}
- Label {
+ PropertyLabel {
text: qsTr("Fast")
- toolTip: qsTr("The blurring algorithm that is used to produce the softness for the "
+ tooltip: qsTr("The blurring algorithm that is used to produce the softness for the "
+ "effect.")
}
+
SecondColumnLayout {
CheckBox {
- Layout.fillWidth: true
backendValue: backendValues.fast
text: backendValues.fast.valueToString
+ implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ + StudioTheme.Values.actionIndicatorWidth
}
- ExpandingSpacer {
- }
+
+ ExpandingSpacer {}
}
}
}
@@ -132,41 +143,52 @@ Column {
caption: qsTr("Offsets")
SectionLayout {
- rows: 2
- Label {
- text: qsTr("Horizontal offset")
- toolTip: qsTr("The horizontal offset for the rendered shadow compared to the inner "
- + "shadow component's horizontal position.")
+ PropertyLabel {
+ text: qsTr("Offset")
}
+
SecondColumnLayout {
SpinBox {
backendValue: backendValues.horizontalOffset
- Layout.preferredWidth: 80
decimals: 1
minimumValue: -1000
maximumValue: 1000
stepSize: 1
+ implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ + StudioTheme.Values.actionIndicatorWidth
}
- ExpandingSpacer {
+
+ Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
+
+ ControlLabel {
+ //: The horizontal offset
+ text: qsTr("H", "horizontal")
+ tooltip: qsTr("The horizontal offset for the rendered shadow compared to the " +
+ "inner shadow component's horizontal position.")
}
- }
- Label {
- text: qsTr("Vertical offset")
- toolTip: qsTr("The vertical offset for the rendered shadow compared to the inner "
- + "shadow component's vertical position. ")
- }
- SecondColumnLayout {
+ Spacer { implicitWidth: StudioTheme.Values.controlGap }
+
SpinBox {
backendValue: backendValues.verticalOffset
- Layout.preferredWidth: 80
decimals: 1
minimumValue: -1000
maximumValue: 1000
stepSize: 1
+ implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ + StudioTheme.Values.actionIndicatorWidth
}
- ExpandingSpacer {
+
+ Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
+
+ ControlLabel {
+ //: The vertical offset
+ text: qsTr("V", "vertical")
+ tooltip: qsTr("The vertical offset for the rendered shadow compared to the " +
+ "inner shadow component's vertical position. ")
}
+
+ ExpandingSpacer {}
}
}
}
@@ -177,20 +199,21 @@ Column {
caption: qsTr("Caching")
SectionLayout {
- rows: 2
- Label {
+ PropertyLabel {
text: qsTr("Cached")
- toolTip: qsTr("Caches the effect output pixels to improve the rendering "
+ tooltip: qsTr("Caches the effect output pixels to improve the rendering "
+ "performance.")
}
+
SecondColumnLayout {
CheckBox {
- Layout.fillWidth: true
backendValue: backendValues.cached
text: backendValues.cached.valueToString
+ implicitWidth: StudioTheme.Values.twoControlColumnWidth
+ + StudioTheme.Values.actionIndicatorWidth
}
- ExpandingSpacer {
- }
+
+ ExpandingSpacer {}
}
}
}