diff --git a/DeltaruneQuickshell/Healthbar/Healthbar.qml b/DeltaruneQuickshell/Healthbar/Healthbar.qml new file mode 100644 index 0000000..6879448 --- /dev/null +++ b/DeltaruneQuickshell/Healthbar/Healthbar.qml @@ -0,0 +1,11 @@ +import QtQuick + +Item { + implicitWidth: 479 + implicitHeight: 137 + anchors.centerIn: parent + Image { + anchors.centerIn: parent + source: "kris.png" + } +} diff --git a/DeltaruneQuickshell/Healthbar/kris.png b/DeltaruneQuickshell/Healthbar/kris.png new file mode 100644 index 0000000..924a219 Binary files /dev/null and b/DeltaruneQuickshell/Healthbar/kris.png differ diff --git a/DeltaruneQuickshell/DeltaruneTopbar.qml b/DeltaruneQuickshell/Topbar/Topbar.qml similarity index 94% rename from DeltaruneQuickshell/DeltaruneTopbar.qml rename to DeltaruneQuickshell/Topbar/Topbar.qml index 6f31f1b..a2ea1bb 100644 --- a/DeltaruneQuickshell/DeltaruneTopbar.qml +++ b/DeltaruneQuickshell/Topbar/Topbar.qml @@ -9,7 +9,7 @@ Item { implicitHeight: 182 anchors.centerIn: parent - property var iconSources: ["./item.png", "./equip.png", "./power.png", "./settings.png"] + property var iconSources: ["item.png", "equip.png", "power.png", "settings.png"] property int iconCount: iconSources.length property int selectedIndex: 0 @@ -27,6 +27,8 @@ Item { } } + DarkDollarsDisplay {} + FocusScope { id: focusScope focus: true diff --git a/DeltaruneQuickshell/Topbar/topbar/DarkDollarsDisplay.qml b/DeltaruneQuickshell/Topbar/topbar/DarkDollarsDisplay.qml new file mode 100644 index 0000000..a57d04b --- /dev/null +++ b/DeltaruneQuickshell/Topbar/topbar/DarkDollarsDisplay.qml @@ -0,0 +1,27 @@ +import QtQuick +import Quickshell + +Item { + Text { + x: 1064 + 117 + y: 37 + 9 + color: "#ffffff" + text: "D$ 4294" + font.pixelSize: 64 + font.family: "8bitoperator JVE" + } + + SystemClock { + id: clock + precision: SystemClock.Minutes + } + + Text { + x: 1064 + 117 + y: 37 + 9 + 64 + color: "#777777" + text: Qt.formatDateTime(clock.date, "dd/MM - hh:mm") + font.pixelSize: 32 + font.family: "8bitoperator JVE" + } +} diff --git a/DeltaruneQuickshell/topbar/TopbarSettingIcon.qml b/DeltaruneQuickshell/Topbar/topbar/TopbarSettingIcon.qml similarity index 89% rename from DeltaruneQuickshell/topbar/TopbarSettingIcon.qml rename to DeltaruneQuickshell/Topbar/topbar/TopbarSettingIcon.qml index ba8454b..a438c9a 100644 --- a/DeltaruneQuickshell/topbar/TopbarSettingIcon.qml +++ b/DeltaruneQuickshell/Topbar/topbar/TopbarSettingIcon.qml @@ -7,6 +7,7 @@ Item { implicitHeight: 108 property url iconSource: "./settings.png" property bool selected: false + property bool showSoul: true readonly property color selectedColor: "#ffc90e" readonly property color unselectedColor: "#614e6b" state: selected ? "selected" : "" @@ -28,6 +29,6 @@ Item { source: "./soul.png" x: 19 y: 42 - visible: item.selected + visible: item.showSoul && item.selected } } diff --git a/DeltaruneQuickshell/topbar/equip.png b/DeltaruneQuickshell/Topbar/topbar/equip.png similarity index 100% rename from DeltaruneQuickshell/topbar/equip.png rename to DeltaruneQuickshell/Topbar/topbar/equip.png diff --git a/DeltaruneQuickshell/topbar/item.png b/DeltaruneQuickshell/Topbar/topbar/item.png similarity index 100% rename from DeltaruneQuickshell/topbar/item.png rename to DeltaruneQuickshell/Topbar/topbar/item.png diff --git a/DeltaruneQuickshell/topbar/power.png b/DeltaruneQuickshell/Topbar/topbar/power.png similarity index 100% rename from DeltaruneQuickshell/topbar/power.png rename to DeltaruneQuickshell/Topbar/topbar/power.png diff --git a/DeltaruneQuickshell/topbar/settings.png b/DeltaruneQuickshell/Topbar/topbar/settings.png similarity index 100% rename from DeltaruneQuickshell/topbar/settings.png rename to DeltaruneQuickshell/Topbar/topbar/settings.png diff --git a/DeltaruneQuickshell/topbar/soul.png b/DeltaruneQuickshell/Topbar/topbar/soul.png similarity index 100% rename from DeltaruneQuickshell/topbar/soul.png rename to DeltaruneQuickshell/Topbar/topbar/soul.png diff --git a/DeltaruneQuickshell/WLRLayerHealthbar.qml b/DeltaruneQuickshell/WLRLayerHealthbar.qml new file mode 100644 index 0000000..101c91c --- /dev/null +++ b/DeltaruneQuickshell/WLRLayerHealthbar.qml @@ -0,0 +1,26 @@ +import Quickshell +import Quickshell.Wayland +import "Healthbar" + +PanelWindow { + anchors { + left: true + right: true + bottom: true + } + + WlrLayershell.layer: WlrLayer.Overlay + WlrLayershell.focusable: true + WlrLayershell.keyboardFocus: WlrKeyboardFocus.None + WlrLayershell.namespace: "deltarune-quickshell-bottom" + + visible: true + exclusionMode: ExclusionMode.Ignore + aboveWindows: true + focusable: true + + implicitHeight: 137 + color: "#000000" + + Healthbar {} +} diff --git a/DeltaruneQuickshell/WLRLayerTopbar.qml b/DeltaruneQuickshell/WLRLayerTopbar.qml new file mode 100644 index 0000000..786747f --- /dev/null +++ b/DeltaruneQuickshell/WLRLayerTopbar.qml @@ -0,0 +1,27 @@ +import Quickshell +import Quickshell.Wayland + +import "Topbar" + +PanelWindow { + anchors { + top: true + left: true + right: true + } + + WlrLayershell.layer: WlrLayer.Overlay + WlrLayershell.focusable: true + WlrLayershell.keyboardFocus: WlrKeyboardFocus.OnDemand + WlrLayershell.namespace: "deltarune-quickshell" + + visible: true + exclusionMode: ExclusionMode.Ignore + aboveWindows: true + focusable: true + + implicitHeight: 182 + color: "#000000" + + Topbar {} +} diff --git a/README.md b/README.md index c52ff68..114aa68 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,8 @@ # DeltaruneQuickshell A [Quickshell](https://quickshell.org/) shell inspired by Deltarune. + +Dependencies: + +- `8bitoperator JVE` +- `Quickshell` (full) diff --git a/shell.qml b/shell.qml index 194a6b3..5312a22 100644 --- a/shell.qml +++ b/shell.qml @@ -1,19 +1,27 @@ -import Quickshell // for PanelWindow -import QtQuick // for Text +import QtQuick +import Quickshell.Io +import Quickshell import "DeltaruneQuickshell" -PanelWindow { - anchors { - top: true - left: true - right: true +ShellRoot { + id: baseShell + property bool isOpen: !true + + WLRLayerTopbar { + visible: baseShell.isOpen + } + WLRLayerHealthbar { + visible: baseShell.isOpen } - // exclusionMode:x ExclusionMode.Ignore - aboveWindows: true - focusable: false - implicitHeight: 182 - color: "#000000" - - DeltaruneTopbar {} + IpcHandler { + target: "deltarune.shell" + enabled: true + function open(): void { + baseShell.isOpen = true; + } + function close(): void { + baseShell.isOpen = false; + } + } }