From e86931545352387e7a8c5929dee2e9934d042800 Mon Sep 17 00:00:00 2001 From: littleblack111 Date: Sun, 13 Jul 2025 21:51:30 +0800 Subject: finish style bar(almost) --- bar/Power.qml | 72 +++++++++++++++++++++++++++++++++++++---------------------- 1 file changed, 45 insertions(+), 27 deletions(-) (limited to 'bar/Power.qml') diff --git a/bar/Power.qml b/bar/Power.qml index f9a74ed..581e725 100644 --- a/bar/Power.qml +++ b/bar/Power.qml @@ -7,36 +7,54 @@ import qs.config as Config import qs.components Item { - id: root - RowLayout { - Item { - Layout.fillWidth: true - } - anchors.fill: parent - spacing: Config.Bar.resourceIconTextSpacing + implicitWidth: container.implicitWidth + implicitHeight: container.implicitHeight - Icons { - text: Config.Icons.power.shutdown - } + Rectangle { + id: container - Icons { - text: Config.Icons.power.dpms + anchors { + fill: parent + verticalCenter: parent.verticalCenter + horizontalCenter: parent.horizontalCenter } - - Icons { - text: Config.Icons.power.lock - } - - Icons { - text: Config.Icons.power.suspend - } - - Icons { - text: Config.Icons.power.reboot - } - - Item { - Layout.fillWidth: true + implicitWidth: layout.implicitWidth + Config.General.rectMargin * 2 + implicitHeight: Config.Bar.height - Config.General.rectMargin + + color: Config.Colors.alt + radius: Config.Style.rounding.large + + RowLayout { + id: layout + Item { + Layout.fillWidth: true + } + anchors.fill: parent + spacing: Config.Bar.resourceIconTextSpacing + + Icons { + text: Config.Icons.power.shutdown + } + + Icons { + text: Config.Icons.power.dpms + } + + Icons { + text: Config.Icons.power.lock + } + + Icons { + text: Config.Icons.power.suspend + } + + Icons { + text: Config.Icons.power.reboot + } + + Item { + Layout.fillWidth: true + } } } } -- cgit v1.2.3