Don't want to see articles from a certain category? When logged in, go to your User Settings and adjust your feed in the Content Preferences section where you can block tags!
Proton: Enabling Virtual Desktop and disabling mouse grabbing
Lakorta Sep 19, 2018
I just wanted to share a way to enable Virtual Desktop and disable mouse grabbing for Steam's Proton. Not having Virtual Desktop enabled is (imo) quite annoying for multi monitor user since most fullsreen applications will minimize if they lose focus. Mouse grabbing also annoys me since I can't use anything on my second monitor without Alt+Tabbing or using activating the Steam Overlay.

Method 1:
Spoiler, click me
One way is to run winecfg in the corresponding Proton prefix (e.g. "WINEPREFIX=~/.steam/steam/steamapps/compatdata/16700/pfx winecfg" for Stronghold Crusader Extreme HD (AppID 16700)). Mind though that "Automatically capture the mouse in full-screen windows" may appear as disabled already in which case you have to enable it, restart winecfg and then disable it. This probably happens since Proton has a different default value for that feature than standart wine has. Also steam may be at a different location (like ~/.local/share/steam) depending on your distro.

Method 2:
Spoiler, click me
Now for another method: Run the following commands preferable from your steamapps/compatdata directory:
printf "REGEDIT4\n[HKEY_CURRENT_USER\Software\Wine\\\Explorer]\n\"Desktop\"=\"Default\"\n[HKEY_CURRENT_USER\Software\Wine\\\Explorer\Desktops]\n\"Default\"=\"1920x1080\"\n[HKEY_CURRENT_USER\Software\Wine\\X11 Driver]\n\"GrabFullscreen\"=\"N\"" >> temp.reg && find -name "pfx" | xargs readlink -f | xargs -I{} env WINEPREFIX={} regedit temp.reg && rm temp.reg
This will change/add the registry keys needed to enable virtual desktop and disable mouse grabbing for all currently installed Proton prefixes (if you install any game later on you have to rerun those commands. Two important notes: This will create a temporary file called temp.reg and removes the file afterwards. If you already have a filled called that in the directory you're running those commands from it will overwrite and delete that file! Another thing is that mouse grabbing may actually be desired for some games since those may not work without that feature (which is the reason mouse grabbing was enabled by default). In that case you can use those commands which do the same as the ones above just without disabling mouse grabbing:
printf "REGEDIT4\n[HKEY_CURRENT_USER\Software\Wine\\\Explorer]\n\"Desktop\"=\"Default\"\n[HKEY_CURRENT_USER\Software\Wine\\\Explorer\Desktops]\n\"Default\"=\"1920x1080\"" >> temp.reg && find -name "pfx" | xargs readlink -f | xargs -I{} env WINEPREFIX={} regedit temp.reg && rm temp.reg

Running winecfg or regedit in a Proton prefix is not officially supported and winecfg/regedit initializes some stuff when run in one. While I did test several games after using it I can not promise that it won't cause unexpected behavior.
I'm a beginner when it comes to bash so if you have any suggestions please tell me :)
Also if you have any questions ask away.

PS: I give absolutely no warranty for doing any of the things I mentioned. Never run any commands you don't understand especially if you found them on the internet.
slaapliedje Sep 19, 2018
Ha, I thought this was for the VR program called Virtual Desktop. I still need to test that out to see if it works with Proton. I use it usually to watch movies as if I'm in my own IMAX theater.
whizse Sep 19, 2018
Quoting: LakortaRunning winecfg or regedit in a Proton prefix is not officially supported and winecfg/regedit initializes some stuff when run in one. While I did test several games after using it I can not promise that it won't cause unexpected behavior.
I'm a beginner when it comes to bash so if you have any suggestions please tell me :)
Also if you have any questions ask away.

Doing this will most likely update the wineprefix for a game to the version of Wine on your system. A much better way is to just use Proton to run winecfg or regedt:

Just use
.../steamapps/common/Proton 3.7 Beta/dist/bin/wine winecfg
instead.

You can also use this path with the WINE environment variable if you need to run winetricks for a proton prefix.
Xpander Sep 21, 2018
minimize on focus loss can be fixed with

export SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS=0
into /etc/environment for example.


multimonitor mouse grab, most games offer mouse release when bringing up the menu (escape menu), but some that don't i usually just switch workspace to chat on my other monitor, so i dont need to alt+tab then.
Lakorta Sep 23, 2018
Quoting: whizseDoing this will most likely update the wineprefix for a game to the version of Wine on your system. A much better way is to just use Proton to run winecfg or regedt:

Just use
.../steamapps/common/Proton 3.7 Beta/dist/bin/wine winecfg
instead.

You can also use this path with the WINE environment variable if you need to run winetricks for a proton prefix.
Running the game through Steam will make it use Proton. But yeah, using Proton's winecfg/regedit may be the better idea. Not sure why I didn't think of that :D

Quoting: Xpanderminimize on focus loss can be fixed with

export SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS=0
into /etc/environment for example.


multimonitor mouse grab, most games offer mouse release when bringing up the menu (escape menu), but some that don't i usually just switch workspace to chat on my other monitor, so i dont need to alt+tab then.
I already had SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS set to zero and while it works with most native games it doesn't work with proton.
Xpander Sep 23, 2018
Quoting: LakortaI already had SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS set to zero and while it works with most native games it doesn't work with proton.

hmm, i remember reading that proton is using SDL. Anyway i have yet to see a game in proton that minimizes when i go into my other monitor. Played: GTA V, DOOM, The Forest, Bioshock 2 Remastered, SCUM, Kingdom Come, Dishonored, Alan Wake, Trackmania 2, Mirrors Edge just to name few. Maybe im lucky then with the games i have played.
While you're here, please consider supporting GamingOnLinux on:

Reward Tiers: Patreon. Plain Donations: PayPal.

This ensures all of our main content remains totally free for everyone! Patreon supporters can also remove all adverts and sponsors! Supporting us helps bring good, fresh content. Without your continued support, we simply could not continue!

You can find even more ways to support us on this dedicated page any time. If you already are, thank you!
Login / Register


Or login with...
Sign in with Steam Sign in with Google
Social logins require cookies to stay logged in.