Your window needs to get the list of all other windows, find the one directly below it, and send a mouse click programmatically, using something like accessibility API.
Are you writing a keylogger?
Linux
Welcome to c/linux!
Welcome to our thriving Linux community! Whether you're a seasoned Linux enthusiast or just starting your journey, we're excited to have you here. Explore, learn, and collaborate with like-minded individuals who share a passion for open-source software and the endless possibilities it offers. Together, let's dive into the world of Linux and embrace the power of freedom, customization, and innovation. Enjoy your stay and feel free to join the vibrant discussions that await you!
Rules:
-
Stay on topic: Posts and discussions should be related to Linux, open source software, and related technologies.
-
Be respectful: Treat fellow community members with respect and courtesy.
-
Quality over quantity: Share informative and thought-provoking content.
-
No spam or self-promotion: Avoid excessive self-promotion or spamming.
-
No NSFW adult content
-
Follow general lemmy guidelines.
i thought there was a way to do it in kde window settings
different approach: if you see mixed content of two windows, it doesn't really matter which one is on top.
if you have many stacked, it's a different thing. maybe you could use nested wayland sessions to group all other windows into one, then you're dealing with only two again and can have the group on top.
I actually tried this right after I made this post, and it was not where near as smooth as I wanted. KDE would put the window that I had assigned to all desktops on top, whenever I would switch virtual desktops.
I found a solution though, it looks like mpv has support.