diff --git a/nymea-app/styles/dark/Button.qml b/nymea-app/styles/dark/Button.qml index 40bcbe36..488249dc 100644 --- a/nymea-app/styles/dark/Button.qml +++ b/nymea-app/styles/dark/Button.qml @@ -75,13 +75,13 @@ T.Button { // TODO: Add a proper ripple/ink effect for mouse/touch input and focus state background: Rectangle { implicitWidth: 64 - implicitHeight: 40 + implicitHeight: Style.smallDelegateHeight // external vertical padding is 6 (to increase touch area) y: 6 width: parent.width height: parent.height - 12 - radius: height / 2 + radius: Style.smallCornerRadius color: !control.enabled ? control.Material.buttonDisabledColor : control.highlighted ? control.Material.highlightedButtonColor : control.Material.accentColor diff --git a/nymea-app/styles/energize/Button.qml b/nymea-app/styles/energize/Button.qml index 2d6afc11..0edbde5d 100644 --- a/nymea-app/styles/energize/Button.qml +++ b/nymea-app/styles/energize/Button.qml @@ -80,7 +80,7 @@ T.Button { y: 6 width: parent.width height: parent.height - 12 - radius: height / 2 + radius: Style.smallCornerRadius color: !control.enabled ? control.Material.buttonDisabledColor : control.highlighted ? control.Material.highlightedButtonColor : control.Material.accentColor diff --git a/nymea-app/styles/light/Button.qml b/nymea-app/styles/light/Button.qml index 508250dd..f3602b80 100644 --- a/nymea-app/styles/light/Button.qml +++ b/nymea-app/styles/light/Button.qml @@ -74,13 +74,13 @@ T.Button { // TODO: Add a proper ripple/ink effect for mouse/touch input and focus state background: Rectangle { implicitWidth: 64 - implicitHeight: 40 + implicitHeight: Style.smallDelegateHeight // external vertical padding is 6 (to increase touch area) y: 6 width: parent.width height: parent.height - 12 - radius: height / 2 + radius: Style.smallCornerRadius color: !control.enabled ? control.Material.buttonDisabledColor : control.highlighted ? control.Material.highlightedButtonColor : control.Material.accentColor diff --git a/nymea-app/styles/lime/Button.qml b/nymea-app/styles/lime/Button.qml index b563b518..5086d55a 100644 --- a/nymea-app/styles/lime/Button.qml +++ b/nymea-app/styles/lime/Button.qml @@ -74,13 +74,13 @@ T.Button { // TODO: Add a proper ripple/ink effect for mouse/touch input and focus state background: Rectangle { implicitWidth: 64 - implicitHeight: 40 + implicitHeight: Style.smallDelegateHeight // external vertical padding is 6 (to increase touch area) y: 6 width: parent.width height: parent.height - 12 - radius: height / 2 + radius: Style.smallCornerRadius color: !control.enabled ? control.Material.buttonDisabledColor : control.highlighted ? control.Material.highlightedButtonColor : control.Material.accentColor diff --git a/nymea-app/styles/noir/Button.qml b/nymea-app/styles/noir/Button.qml index 5a5298df..4957061c 100644 --- a/nymea-app/styles/noir/Button.qml +++ b/nymea-app/styles/noir/Button.qml @@ -74,13 +74,13 @@ T.Button { // TODO: Add a proper ripple/ink effect for mouse/touch input and focus state background: Rectangle { implicitWidth: 64 - implicitHeight: 40 + implicitHeight: Style.smallDelegateHeight // external vertical padding is 6 (to increase touch area) y: 6 width: parent.width height: parent.height - 12 - radius: height / 2 + radius: Style.smallCornerRadius color: !control.enabled ? control.Material.buttonDisabledColor : control.highlighted ? control.Material.highlightedButtonColor : control.Material.accentColor diff --git a/nymea-app/ui/StyleBase.qml b/nymea-app/ui/StyleBase.qml index b9c570eb..4a19abae 100644 --- a/nymea-app/ui/StyleBase.qml +++ b/nymea-app/ui/StyleBase.qml @@ -15,7 +15,9 @@ Item { property color tileOverlayColor: Qt.tint(backgroundColor, Qt.rgba(foregroundColor.r, foregroundColor.g, foregroundColor.b, 0.1)) property color tileOverlayForegroundColor: foregroundColor property color tileOverlayIconColor: iconColor - property int tileRadius: 6 + + property int cornerRadius: 6 + property int smallCornerRadius: 4 readonly property int smallMargins: 8 readonly property int margins: 16 diff --git a/nymea-app/ui/components/BigTile.qml b/nymea-app/ui/components/BigTile.qml index 8a7346f5..b158d4f7 100644 --- a/nymea-app/ui/components/BigTile.qml +++ b/nymea-app/ui/components/BigTile.qml @@ -66,7 +66,7 @@ Item { id: background anchors.fill: parent anchors.margins: app.margins / 2 - radius: Style.tileRadius + radius: Style.cornerRadius gradient: Gradient { GradientStop { diff --git a/nymea-app/ui/components/BrightnessSlider.qml b/nymea-app/ui/components/BrightnessSlider.qml index 7cf1de28..edc3d570 100644 --- a/nymea-app/ui/components/BrightnessSlider.qml +++ b/nymea-app/ui/components/BrightnessSlider.qml @@ -55,7 +55,7 @@ Item { Rectangle { id: clipRect anchors.fill: parent - radius: Style.tileRadius + radius: Style.cornerRadius color: Style.tileOverlayColor } diff --git a/nymea-app/ui/components/ColorTemperaturePicker.qml b/nymea-app/ui/components/ColorTemperaturePicker.qml index 3646aa42..483b49a6 100644 --- a/nymea-app/ui/components/ColorTemperaturePicker.qml +++ b/nymea-app/ui/components/ColorTemperaturePicker.qml @@ -25,7 +25,7 @@ Item { Rectangle { id: clipRect anchors.fill: parent - radius: Style.tileRadius + radius: Style.cornerRadius } LinearGradient { diff --git a/nymea-app/ui/components/MainPageTile.qml b/nymea-app/ui/components/MainPageTile.qml index e9e67dee..354da903 100644 --- a/nymea-app/ui/components/MainPageTile.qml +++ b/nymea-app/ui/components/MainPageTile.qml @@ -70,7 +70,7 @@ Item { } } - radius: Style.tileRadius + radius: Style.cornerRadius } Image { diff --git a/nymea-app/ui/components/SmartMeterChart.qml b/nymea-app/ui/components/SmartMeterChart.qml index a66b7c3a..2a3a1e81 100644 --- a/nymea-app/ui/components/SmartMeterChart.qml +++ b/nymea-app/ui/components/SmartMeterChart.qml @@ -38,7 +38,7 @@ import Nymea 1.0 ChartView { id: chart backgroundColor: Style.tileBackgroundColor - backgroundRoundness: Style.tileRadius + backgroundRoundness: Style.cornerRadius theme: ChartView.ChartThemeLight legend.labelColor: Style.foregroundColor legend.font.pixelSize: app.smallFont diff --git a/nymea-app/ui/customviews/GenericTypeGraph.qml b/nymea-app/ui/customviews/GenericTypeGraph.qml index 93420888..2a553690 100644 --- a/nymea-app/ui/customviews/GenericTypeGraph.qml +++ b/nymea-app/ui/customviews/GenericTypeGraph.qml @@ -81,7 +81,7 @@ Item { margins.left: 0 margins.right: 0 backgroundColor: Style.tileBackgroundColor - backgroundRoundness: Style.tileRadius + backgroundRoundness: Style.cornerRadius legend.visible: false legend.labelColor: Style.foregroundColor diff --git a/nymea-app/ui/devicelistpages/LightThingsListPage.qml b/nymea-app/ui/devicelistpages/LightThingsListPage.qml index e82bc127..040bb43e 100644 --- a/nymea-app/ui/devicelistpages/LightThingsListPage.qml +++ b/nymea-app/ui/devicelistpages/LightThingsListPage.qml @@ -123,7 +123,7 @@ ThingsListPageBase { color: itemDelegate.tileColored ? itemDelegate.colorState.value : "#00000000" implicitHeight: contentColumn.implicitHeight Behavior on implicitHeight { NumberAnimation { duration: 100 } } - radius: Style.tileRadius + radius: Style.cornerRadius ColumnLayout { id: contentColumn @@ -253,7 +253,7 @@ ThingsListPageBase { Layout.fillWidth: true Layout.preferredHeight: 12 visible: itemDelegate.powerState.value === true && itemDelegate.brightnessState != null - radius: Style.tileRadius + radius: Style.cornerRadius color: Style.tileOverlayColor enabled: itemDelegate.isEnabled diff --git a/nymea-app/ui/devicelistpages/MediaDeviceListPage.qml b/nymea-app/ui/devicelistpages/MediaDeviceListPage.qml index 1cdc9543..6f4f1695 100644 --- a/nymea-app/ui/devicelistpages/MediaDeviceListPage.qml +++ b/nymea-app/ui/devicelistpages/MediaDeviceListPage.qml @@ -150,7 +150,7 @@ ThingsListPageBase { anchors.centerIn: parent height: parent.width width: parent.height - radius: Style.tileRadius + radius: Style.cornerRadius gradient: Gradient { GradientStop { position: 0; color: "#00FF0000" } GradientStop { position: 0.2; color: "#15FF0000" } diff --git a/nymea-app/ui/devicepages/LightDevicePage.qml b/nymea-app/ui/devicepages/LightDevicePage.qml index 2de9ecf2..cbf445a1 100644 --- a/nymea-app/ui/devicepages/LightDevicePage.qml +++ b/nymea-app/ui/devicepages/LightDevicePage.qml @@ -96,7 +96,7 @@ ThingPageBase { contentItem: Rectangle { color: model.color - radius: Style.tileRadius + radius: Style.cornerRadius ColorIcon { anchors.fill: parent @@ -157,7 +157,7 @@ ThingPageBase { Rectangle { Layout.preferredWidth: Style.hugeIconSize Layout.preferredHeight: width - radius: Style.tileRadius + radius: Style.cornerRadius color: root.colorState ? root.colorState.value : "red" // color: Qt.tint(Style.backgroundColor, Qt.rgba(Style.foregroundColor.r, Style.foregroundColor.g, Style.foregroundColor.b, 0.1)) ColorIcon { diff --git a/nymea-app/ui/devicepages/ShutterDevicePage.qml b/nymea-app/ui/devicepages/ShutterDevicePage.qml index 860dd96b..a4046232 100644 --- a/nymea-app/ui/devicepages/ShutterDevicePage.qml +++ b/nymea-app/ui/devicepages/ShutterDevicePage.qml @@ -195,7 +195,7 @@ ThingPageBase { Rectangle { id: mask anchors.fill: parent - radius: Style.tileRadius + radius: Style.cornerRadius color: "blue" visible: false } diff --git a/nymea-app/ui/mainviews/EnergyView.qml b/nymea-app/ui/mainviews/EnergyView.qml index 013a5439..67d7667e 100644 --- a/nymea-app/ui/mainviews/EnergyView.qml +++ b/nymea-app/ui/mainviews/EnergyView.qml @@ -83,7 +83,7 @@ MainViewBase { legend.font.pixelSize: app.smallFont legend.visible: false backgroundColor: Style.tileBackgroundColor - backgroundRoundness: Style.tileRadius + backgroundRoundness: Style.cornerRadius titleColor: Style.foregroundColor title: qsTr("Power usage history") @@ -359,7 +359,7 @@ MainViewBase { Layout.fillWidth: true Layout.preferredHeight: width * .7 backgroundColor: Style.tileBackgroundColor - backgroundRoundness: Style.tileRadius + backgroundRoundness: Style.cornerRadius meters: producers title: qsTr("Total produced energy") visible: producers.count > 0