Files
dotfiles/.config/quickshell/own/Bar.qml
T

64 lines
1.8 KiB
QML

// Bar.qml - top panel
import Quickshell
import Quickshell.Wayland
import QtQuick
import QtQuick.Layouts
import "./modules"
PanelWindow {
id: root
WlrLayershell.namespace: "quickshell-bar"
WlrLayershell.layer: WlrLayer.Top
WlrLayershell.keyboardFocus: WlrKeyboardFocus.None
anchors {
top: true
left: true
right: true
}
margins {
left: 0
right: 0
bottom: 0
top: 0
}
function setColorAlpha(color, alpha) {
return Qt.hsla(color.hslHue, color.hslSaturation, color.hslLightness, alpha)
}
implicitHeight: Theme.barHeight + Theme.barPadding * 2
exclusiveZone: Theme.barHeight + Theme.barPadding * 2
color: setColorAlpha(Theme.background, 0)
RowLayout {
anchors.fill: parent
anchors.leftMargin: Theme.barPadding
anchors.topMargin: Theme.barPadding
anchors.bottomMargin: Theme.barPadding
anchors.rightMargin: Theme.barPadding
spacing: Theme.spacing
// ─── LEFT ──────────────────────────────────────────
SysTrayWidget { parentWindow: root }
ClockWidget {}
WeatherWidget {}
WorkspacesWidget { screen: root.screen }
WindowTitleWidget { screen: root.screen }
Item { Layout.fillWidth: true }
// ─── RIGHT ─────────────────────────────────────────
MediaCavaWidget {}
MemoryWidget {}
CpuWidget {}
TemperatureWidget {}
BatteryWidget {}
//BluetoothWidget {}
PowerProfilesWidget {}
PowerMenuWidget {}
}
}