How to make Flatpaks effectively start on pre-selected screen

It took me a while to figure out how to change the flatpak’s icon.
How to make it effectively start on pre-selected screen? Both setting special application or window setting do not seem to work.
It’s probably an entry in ~/.local/share/applications to make it work (like for the icon).
Duolingo always starts on my TV which I usually keep turned off.

Flathub recommends contacting package maintainer for support
GitHub - hmlendea/dl-desktop: Desktop client for the Duolingo language learning application

What exactly did you try to make it open on a specific monitor?

right click > Configure Special Applications/Window Settings > + Add: Screen > 0-3
to no avail

When you selected + Add: Screen > 0-3 what option did you choose? Was it Apply Initially?

yes and i tried all of them
with force, it would not be drag-able across screens anymore

You might try KWin scrips Always Open on Primary Screen or Always Open on Focused Screen

1 Like

I had tried the latter to no avail. There is Primary and Active which I can’t install right now because KDE Store gives me Cloudlare unreachable errors.

But they are prbb. the same as Focused.

If that didn’t work then you don’t have a lot of options.

Either use Ctrl + Super + Arrow shortcut to move window between screens or try to make a script that will do that for you automatically after app launch

1 Like

Can’t I like put a screen entry in here?

[Desktop Entry]
Encoding=UTF-8
Name=Duolingo
Type=Application
Comment=Learn new languages in bite-sized lessons
Comment[ro]=Învață limbi noi în lecții mărunte
Exec=/usr/bin/flatpak run --branch=stable --arch=x86_64 --command=dl-desktop ro.go.hmlendea.DL-Desktop
Icon=/home/1efaf7d71a8637c6800a/.local/share/icons/Gruvbox-Plus-Dark/mimetypes/22@2x/mimetype-wolfram-wl.svg
StartupWMClass=DL: language lessons
Categories=Education;
Keywords=Duolingo;Languages;
Keywords[ro]=Duolingo;Limbi;
X-Desktop-File-Install-Version=0.26
X-Flatpak=ro.go.hmlendea.DL-Desktop

“Screen=…” or so?

You can but it won’t work. There is no key with such functionality in .desktop files:
https://specifications.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html

I have 3 monitors and I use window rule Screen Force [0-2]. But if you want a window to open on a specific monitor and also be drag-able between monitors then there are no easy solutions for you. A custom script is your best hope. You might search for wmctrl and xdotool

1 Like