feat: inventory + ipc
11
DeltaruneQuickshell/Healthbar/Healthbar.qml
Normal file
@@ -0,0 +1,11 @@
|
||||
import QtQuick
|
||||
|
||||
Item {
|
||||
implicitWidth: 479
|
||||
implicitHeight: 137
|
||||
anchors.centerIn: parent
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
source: "kris.png"
|
||||
}
|
||||
}
|
||||
BIN
DeltaruneQuickshell/Healthbar/kris.png
Normal file
|
After Width: | Height: | Size: 257 KiB |
@@ -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
|
||||
27
DeltaruneQuickshell/Topbar/topbar/DarkDollarsDisplay.qml
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
@@ -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
|
||||
}
|
||||
}
|
||||
|
Before Width: | Height: | Size: 63 KiB After Width: | Height: | Size: 63 KiB |
|
Before Width: | Height: | Size: 63 KiB After Width: | Height: | Size: 63 KiB |
|
Before Width: | Height: | Size: 63 KiB After Width: | Height: | Size: 63 KiB |
|
Before Width: | Height: | Size: 63 KiB After Width: | Height: | Size: 63 KiB |
|
Before Width: | Height: | Size: 4.1 KiB After Width: | Height: | Size: 4.1 KiB |
26
DeltaruneQuickshell/WLRLayerHealthbar.qml
Normal file
@@ -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 {}
|
||||
}
|
||||
27
DeltaruneQuickshell/WLRLayerTopbar.qml
Normal file
@@ -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 {}
|
||||
}
|
||||
@@ -1,3 +1,8 @@
|
||||
# DeltaruneQuickshell
|
||||
|
||||
A [Quickshell](https://quickshell.org/) shell inspired by Deltarune.
|
||||
|
||||
Dependencies:
|
||||
|
||||
- `8bitoperator JVE`
|
||||
- `Quickshell` (full)
|
||||
|
||||
38
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
|
||||
}
|
||||
// exclusionMode:x ExclusionMode.Ignore
|
||||
aboveWindows: true
|
||||
focusable: false
|
||||
ShellRoot {
|
||||
id: baseShell
|
||||
property bool isOpen: !true
|
||||
|
||||
implicitHeight: 182
|
||||
color: "#000000"
|
||||
|
||||
DeltaruneTopbar {}
|
||||
WLRLayerTopbar {
|
||||
visible: baseShell.isOpen
|
||||
}
|
||||
WLRLayerHealthbar {
|
||||
visible: baseShell.isOpen
|
||||
}
|
||||
|
||||
IpcHandler {
|
||||
target: "deltarune.shell"
|
||||
enabled: true
|
||||
function open(): void {
|
||||
baseShell.isOpen = true;
|
||||
}
|
||||
function close(): void {
|
||||
baseShell.isOpen = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||