Hello I’m not sure if its a bug or something wrong on my part but window rules don’t apply the settings I set correctly or I’m missing something. I’m trying to set a rule for apps to start minimized on startup and some have worked but others have not. One of the apps that on startup is launched minimized is from flatpak and the other which is also from flatpak just won’t work. Some others installed via yay when setting “apply initially” nothing happens but when setting “force” or “force temporarily” they get minimized just fine (and won’t open but thats just the setting). I have used both the “add new” then "detect window properties to set the settings and also by right clicking on the title bar of the app and selecting “special window settings” and settings everything from there, nothing so far with both options.
Is this a bug with window rules or i’m forgetting something?
Hi! It might be easiest to look at the specifics of your issue, and then see if folks can help figure things out more generally from there. Could you share:
- The name of the application that isn’t getting its Window Rule applied?
- A screenshot of the Window Rule settings dialog for that rule?
Of course! Here are a few screenshots from apps that work vs apps that don’t work. Vesktop was installed via flatpak while viber was via yay and these two work while teams for linux and obsidian don’t with teams being installed via yay and obsidian via flatpak. I would include steam but im guessing steam has some background shenanigans that make it not work.
Hmm, maybe one idea to try to figure out whether or not it’s property matching, or rule application that’s the problem: Using Obsidian as an example, what if you set the Window class matching to Unimportant, and just have it match a substring of the window title? Does that impact whether or not the rule gets applied?
It’s probably not a long-term best practice, but this is an example of what I’m thinking about from my own system (this is a janky version of a “web app” for Firefox ):
Did select those options and obsidian now its minimized on startup but teams-for-linux doesn’t get minimized at all, seems I have to find a solution outside of window rules to get it minimized like I did with steam.
So from what I have gathered the window rules work better with Flatpak applications rather than pacman or yay installed ones. A good solution I found for pacman and yay applications starting minimized is to go to autostart, select “see properties” (window icon next to “running”, go to “application” and on arguments add either --start minimized or --minimized. To see what works for each app, start the konsole and type the name of the app and --help (for example “teams-for-linux --help”) and then search if --minimized or --start minimized is listed. Whatever is listed is the thing you’ll have to add on arguments at the start of the already existing sentence if there is something (for teams-for-linux it was %U so add --minimized %U). This will start the app minimized on startup.