Xfce Forum

Sub domains

You are not logged in.

#1 2021-01-22 11:21:10

Registered: 2021-01-22
Posts: 1

Issues with fullscreen SDL applications such as DOSBox and Pygame

Info: Xubuntu 18.04 (Xfce 4.12), with two monitors, Left: VGAtoDVI 1280x768 Right: DP 1440x900 (Also set as Primary in X conf and in Xfce). Setup as extended using the Xfce Display utility. There's also a LeftOf command in a /usr/share/X11/xorg.conf.d script, which seems to avoid a bug in Xfce which makes desktop icons only possible on one screen.

Initially, when I went fullscreen in SDL 1.2 based applications, they would mirror my monitors OR would go fullscreen across both monitors, and when I came out, all my icons would also be messed up. I resolved this issue by forcing: export SDL_VIDEO_FULLSCREEN_DISPLAY=0 into /etc/xprofile. This makes it fullscreen on my primary monitor. So good so far.

But, I recognised that sometimes, but sometimes not, I would go fullscreen, and it would flicker into fullscreen and out into windowed mode, offset from maximised. It would just keep doing this over and over. I finally figured out, that SDL seems to force the mouse to the centre of the left-hand monitor, which is NOT primary. When it does that, it loses focus -- which is because I set "mouse follows focus" with a delay of 0. When I turn this off, it all works perfectly. It was intermittent, because it depended whether I had a window on the left-hand screen! But I noticed each time it flickers, that the window gained focus, away from the fullscreen application.

Is there anyway to stop SDL applications from doing this, without having to do this? :-

xfconf-query -c xfwm4 -p /general/click_to_focus -s true
xfconf-query -c xfwm4 -p /general/click_to_focus -s false

For now, I've just turned it off. Looks like I'm back to old, Alt+Tabbing.


Board footer

Powered by FluxBB