Bug 2370393 - --force-grab-cursor flag not functional in 3.16.4-2.fc42
Summary: --force-grab-cursor flag not functional in 3.16.4-2.fc42
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: gamescope
Version: 42
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Neal Gompa
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-06-05 07:23 UTC by owenhines
Modified: 2026-01-07 11:18 UTC (History)
8 users (show)

Fixed In Version: gamescope-3.16.15-1.fc42
Clone Of:
Environment:
Last Closed: 2025-09-04 00:50:41 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description owenhines 2025-06-05 07:23:34 UTC
In the most recent stable release of the gamescope package, the `--force-grab-cursor` flag does not seem to work properly, meaning that the cursor can escape game windows even when it should be capturing it. Adding the flag has no effect.

Reproducible: Always

Steps to Reproduce:
1. Launch a game with gamescope (without the `--force-grab-cursor` flag) that has issues with capturing the cursor. I used Counter-Strike 2 as my test game. The launch options I used were `gamescope -S stretch -f  -- %command%`
2. Notice that when in-game, the cursor escapes the window (i.e. another monitor).
3. Close the game and add the `--force-grab-cursor` flag to the launch options: `gamescope --force-grab-cursor -S stretch -f  -- %command%`.
4. Relaunch the game and test the behavior again.
Actual Results:
The behavior did not change, so the cursor still escaped the window.

Expected Results:
The game window should have captured the cursor.

Additional Information:
There seems to have been a regression introduced either in version 3.16.3 or 3.16.4 of gamescope, since downgrading to version 3.16.2 via `dnf downgrade gamescope` resolves the issue. This issue is already being tracked [here](https://github.com/ValveSoftware/gamescope/issues/1806). From that page, it seems like version `3.16.4-20` may have patched it, so a resolution could be upgrading the package to a more recent version from the source.

Comment 1 owenhines 2025-06-05 07:27:48 UTC
I forgot to include this in the original report, but I'm running the KDE Plasma version of Fedora 42, so I'm using Wayland. Also, this is my first bug report so please let me know if there's any other information that would be helpful to include, thanks!

Comment 2 owen 2025-08-04 16:17:47 UTC
This bug is fixed in the current rawhide/testing version, so you can use that if you're experiencing it (can grab on koji: https://koji.fedoraproject.org/koji/buildinfo?buildID=2720431)

I do have a question for maintainers, though - what's holding 3.16.11 back from main? It's been there since May from what I can tell, and seems to be very stable. 3.16.4 is a really old version, and, IMO, this bug is pretty severe - it pretty much makes the entire program useless on multi-monitor setups as any game that uses the mouse to look around (so most first/third person 3d games) cannot be played using gamescope as the cursor will leave the window if you look in one direction.

Comment 3 František Zatloukal 2025-08-04 17:18:30 UTC
(In reply to owen from comment #2)
> This bug is fixed in the current rawhide/testing version, so you can use
> that if you're experiencing it (can grab on koji:
> https://koji.fedoraproject.org/koji/buildinfo?buildID=2720431)
> 
> I do have a question for maintainers, though - what's holding 3.16.11 back
> from main? It's been there since May from what I can tell, and seems to be
> very stable. 3.16.4 is a really old version, and, IMO, this bug is pretty
> severe - it pretty much makes the entire program useless on multi-monitor
> setups as any game that uses the mouse to look around (so most first/third
> person 3d games) cannot be played using gamescope as the cursor will leave
> the window if you look in one direction.

Yeah, the issue is with mutter - it doesn't support gamescope >= 3.16.5. See more context at: https://github.com/ValveSoftware/gamescope/issues/1825 ; https://gitlab.gnome.org/GNOME/mutter/-/issues/4083 .

There is a PR fixing it proposed: https://github.com/ValveSoftware/gamescope/pull/1867 , but the discussion and solution was evolving, so I didn't want to backport something that's wrong somehow :/

Comment 4 Fedora Update System 2025-08-31 13:23:08 UTC
FEDORA-2025-ace7d75aa5 (gamescope-3.16.15-1.fc42) has been submitted as an update to Fedora 42.
https://bodhi.fedoraproject.org/updates/FEDORA-2025-ace7d75aa5

Comment 5 Fedora Update System 2025-09-01 01:49:41 UTC
FEDORA-2025-ace7d75aa5 has been pushed to the Fedora 42 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2025-ace7d75aa5`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2025-ace7d75aa5

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 6 Fedora Update System 2025-09-04 00:50:41 UTC
FEDORA-2025-ace7d75aa5 (gamescope-3.16.15-1.fc42) has been pushed to the Fedora 42 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 7 Mark Tuan 2026-01-07 11:18:32 UTC
Thank you for the update on this bug! It's great to see that the issue with the --force-grab-cursor flag has been addressed in the latest version. I appreciate the efforts of everyone involved in resolving it. Looking forward to testing the new update! https://sports-games.io/


Note You need to log in before you can comment on or make changes to this bug.