linux: add persistent 'Start Hidden (Tray Only)' setting - #759
Open
cvanelteren wants to merge 1 commit into
Open
linux: add persistent 'Start Hidden (Tray Only)' setting#759cvanelteren wants to merge 1 commit into
cvanelteren wants to merge 1 commit into
Conversation
Adds a 'Start Hidden' toggle in the settings page that persists to QSettings (window/startHidden). When enabled, the app starts with the main window hidden regardless of whether --hide was passed, which is useful for tiling window managers where the window otherwise appears as an overlay at startup.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
LibrePods is a tray app, but the main window pops up at startup whenever it is launched without
--hide. The built-in auto-start entry already passes--hide, but users who start the app some other way — e.g.spawn-at-startupin tiling compositors like niri/Hyprland/sway, or launching from an app launcher — get the 400x300 window shown on every boot. On tiling window managers this appears as an unwanted overlay window.Changes
Adds a persistent Start Hidden (Tray Only) toggle to the settings page:
window/startHiddenQSettings key, exposed to QML asairPodsTrayApp.startHidden--hide || startHidden, so the persisted preference works no matter how the app is launchedTested
Built on Arch Linux (Qt 6, cmake) and verified under niri: with the setting enabled and no
--hideflag, the process starts and the tray icon works while no window is created (niri msg windowsshows nothing). The window still opens normally from the tray icon.No behavior change for users who don't enable the toggle (default
false).Note: created with Qwen3.8max as I was annoyed in my niri setup that librepods has this big banner that may look nice on non-tiling managers, but gets in the way of tiling managers, at least on niri.