diff options
| author | Laurens Duin <85798751+Laurens256@users.noreply.github.com> | 2025-08-13 06:31:48 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-08-13 14:31:48 +1000 |
| commit | 3710df29f588c2aa430d9797a36afa1cbd85b128 (patch) | |
| tree | 5f804118369ab2db0dbffbbd604b4ddc33af93ed /modules/bar/components/Power.qml | |
| parent | nix: add home manager module (#402) (diff) | |
| download | caelestia-shell-3710df29f588c2aa430d9797a36afa1cbd85b128.tar.gz caelestia-shell-3710df29f588c2aa430d9797a36afa1cbd85b128.tar.bz2 caelestia-shell-3710df29f588c2aa430d9797a36afa1cbd85b128.zip | |
bar: allow hiding items and reordering (#379)
* feat: reorder bar, no popout yet
* chore: cleanup
* refactor: use DelegateChooser
* feat: popouts
* chore: cleanup
* better popout check + fix async stuff + bar interaction
+ a bunch of other fixes
* fix activewindow and bar vertical padding
* readme: add config opt
* bar: fix top/bottom padding
* bar: better wheel behaviour
---------
Co-authored-by: 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>
Diffstat (limited to 'modules/bar/components/Power.qml')
| -rw-r--r-- | modules/bar/components/Power.qml | 28 |
1 files changed, 19 insertions, 9 deletions
diff --git a/modules/bar/components/Power.qml b/modules/bar/components/Power.qml index 71dc296..917bdf7 100644 --- a/modules/bar/components/Power.qml +++ b/modules/bar/components/Power.qml @@ -2,24 +2,22 @@ import qs.components import qs.services import qs.config import Quickshell +import QtQuick -MaterialIcon { +Item { id: root required property PersistentProperties visibilities - text: "power_settings_new" - color: Colours.palette.m3error - font.bold: true - font.pointSize: Appearance.font.size.normal + implicitWidth: icon.implicitHeight + Appearance.padding.small * 2 + implicitHeight: icon.implicitHeight StateLayer { + // Cursed workaround to make the height larger than the parent anchors.fill: undefined anchors.centerIn: parent - anchors.horizontalCenterOffset: 1 - - implicitWidth: parent.implicitHeight + Appearance.padding.small * 2 - implicitHeight: implicitWidth + implicitWidth: implicitHeight + implicitHeight: icon.implicitHeight + Appearance.padding.small * 2 radius: Appearance.rounding.full @@ -27,4 +25,16 @@ MaterialIcon { root.visibilities.session = !root.visibilities.session; } } + + MaterialIcon { + id: icon + + anchors.centerIn: parent + anchors.horizontalCenterOffset: -1 + + text: "power_settings_new" + color: Colours.palette.m3error + font.bold: true + font.pointSize: Appearance.font.size.normal + } } |