Replace bar-settings with unified settings plugin

Consolidates bar-settings into a single 'settings' plugin with sidebar
categories: Defaults, Style, Bar, System, Plugins. Updates supporting
commands (omarchy-launch-settings, omarchy-style-corners-quickshell,
omarchy-theme-list-with-previews, omarchy-hyprland-monitor-scaling-set)
and refreshes sidebar glyphs to Nerd Font icons.
This commit is contained in:
Ryan Hughes
2026-05-14 02:25:05 -04:00
parent e54648dfd5
commit c7da0f74aa
27 changed files with 3023 additions and 1596 deletions
@@ -16,7 +16,7 @@ Item {
// The omarchy-shell host injects omarchyPath when it instantiates this Bar.
// Default fallback keeps the file loadable in isolation (e.g. for QML tooling).
required property string omarchyPath
// Injected by the host shell. Shared with the bar-settings panel so both
// Injected by the host shell. Shared with the settings panel so both
// see the same widget catalogue.
required property var barWidgetRegistry
// Injected by the host shell every time shell.json is reloaded. Holds the
@@ -29,6 +29,10 @@ Item {
// Injected by the host shell. Used so Noctalia plugins that reach for
// shell-wide APIs (openPanel, currentScreen) can do so via pluginApi.
property var shell: null
// Mirrors the on-disk `bar-off` flag so the user can hide the bar without
// killing the entire shell. Wired to BarPanel.visible below; updated by the
// FileView watcher further down.
property bool barHidden: false
property string home: Quickshell.env("HOME")
property string omarchyConfigDir: home + "/.config/omarchy"
property var fallbackBarConfig: ({
@@ -691,13 +695,39 @@ Item {
// The host owns shell.json loading and injects `barConfig`. Bar still keeps
// its own theme FileView since theme colors are independent of shell.json.
// `omarchy-theme-set` recreates the entire theme/ directory via rm+mv, which
// invalidates the inotify watch on colors.toml. Use theme.name (overwritten
// in place) to force a fresh reload after each swap.
FileView {
id: themeColorsFile
path: root.home + "/.config/omarchy/current/theme/colors.toml"
watchChanges: true
printErrors: false
onLoaded: root.loadTheme(text())
onFileChanged: reload()
}
FileView {
path: root.home + "/.config/omarchy/current/theme.name"
watchChanges: true
printErrors: false
onFileChanged: themeColorsFile.reload()
}
// Presence of the `bar-off` flag = bar hidden. Watching the parent toggles
// directory because FileView can't observe a file that doesn't exist yet,
// and the flag is created/removed by `omarchy-toggle-bar`.
Process {
id: barHiddenProbe
running: true
command: ["bash", "-lc", "[[ -f $HOME/.local/state/omarchy/toggles/bar-off ]] && echo yes || echo no"]
stdout: SplitParser { onRead: function(line) { root.barHidden = String(line).trim() === "yes" } }
}
FileView {
path: root.home + "/.local/state/omarchy/toggles"
watchChanges: true
printErrors: false
onFileChanged: barHiddenProbe.running = true
}
Process {
id: weatherProc
@@ -844,6 +874,8 @@ Item {
component BarPanel: PanelWindow {
id: barWindow
visible: !root.barHidden
anchors {
top: root.position === "top" || root.vertical
bottom: root.position === "bottom" || root.vertical
@@ -14,9 +14,9 @@ the shell for its whole session.
## Customizing
The bar config lives under the `bar:` key of [`~/.config/omarchy/shell.json`](../../README.md#shelljson-shape). Out of the box the shell uses [`shell-defaults.json`](../../shell-defaults.json). Once you customize anything via `omarchy launch bar-settings` or by editing shell.json directly, your file is canonical — there is no deep-merge.
The bar config lives under the `bar:` key of [`~/.config/omarchy/shell.json`](../../README.md#shelljson-shape). Out of the box the shell uses [`shell-defaults.json`](../../shell-defaults.json). Once you customize anything via `omarchy launch settings` or by editing shell.json directly, your file is canonical — there is no deep-merge.
Launch the visual editor with `omarchy launch bar-settings` (or run `omarchy-launch-bar-settings`) to reorder widgets, add/remove them, and tweak per-widget options without editing JSON by hand.
Launch the visual editor with `omarchy launch settings` (or run `omarchy-launch-settings`) to reorder widgets, add/remove them, and tweak per-widget options without editing JSON by hand.
Example `shell.json` (bar subtree only shown):
@@ -171,5 +171,5 @@ Third-party widgets ship as separate plugins under
`~/.config/omarchy/plugins/<plugin-id>/` with their own `manifest.json`
declaring `kinds: ["bar-widget"]` and a `barWidget` entry point. See
[../../README.md](../../README.md) for the manifest schema and the
Plugin Manager tab in `omarchy launch bar-settings` for enable/disable
Plugin Manager tab in `omarchy launch settings` for enable/disable
controls.
@@ -362,11 +362,11 @@ Item {
Common.PillButton {
width: parent.width
iconText: "󰙪"
text: "Customize bar…"
text: "Settings…"
foreground: root.bar.foreground
horizontalPadding: 10
verticalPadding: 8
onClicked: { root.run("omarchy-launch-bar-settings"); root.popupOpen = false }
onClicked: { root.run("omarchy-launch-settings"); root.popupOpen = false }
}
}
}