2025-12-28 13:25:31 +01:00
|
|
|
pragma ComponentBehavior: Bound
|
|
|
|
|
pragma Singleton
|
|
|
|
|
import QtQuick
|
|
|
|
|
import Quickshell
|
|
|
|
|
import Quickshell.Io
|
|
|
|
|
|
2025-12-31 01:37:27 +01:00
|
|
|
FileView {
|
|
|
|
|
id: settingsView
|
|
|
|
|
path: "/home/lucy/.cache/quickshell_settings.json"
|
2025-12-28 13:25:31 +01:00
|
|
|
|
2025-12-31 01:37:27 +01:00
|
|
|
watchChanges: true
|
|
|
|
|
onAdapterChanged: writeAdapter()
|
2025-12-28 13:25:31 +01:00
|
|
|
|
2025-12-31 01:37:27 +01:00
|
|
|
adapter: JsonAdapter {
|
|
|
|
|
id: jsonAdapter
|
|
|
|
|
property string currentWall: ""
|
|
|
|
|
property string wallDir: "/home/lucy/.walls/"
|
|
|
|
|
property string font: "SFMono Nerd Font Propo"
|
|
|
|
|
property real fontSize: 14
|
2025-12-28 13:25:31 +01:00
|
|
|
|
2025-12-31 01:37:27 +01:00
|
|
|
onCurrentWallChanged: settingsView.writeAdapter()
|
|
|
|
|
onWallDirChanged: settingsView.writeAdapter()
|
|
|
|
|
onFontChanged: settingsView.writeAdapter()
|
|
|
|
|
onFontSizeChanged: settingsView.writeAdapter()
|
2025-12-28 13:25:31 +01:00
|
|
|
}
|
2025-12-31 01:37:27 +01:00
|
|
|
property alias currentWall: jsonAdapter.currentWall
|
|
|
|
|
property alias font: jsonAdapter.font
|
|
|
|
|
property alias fontSize: jsonAdapter.fontSize
|
|
|
|
|
property alias wallDir: jsonAdapter.wallDir
|
2025-12-28 13:25:31 +01:00
|
|
|
}
|