Fullscreen backdrop lands over the game on window managers that restack new windows (xfwm4): black screen, the Alt-Tab thumbnail holds the picture #2031

Closed
opened 2026-11-29 08:04:04 +00:00 by github-bot · 4 comments
Owner

@⁠birdneststream on GitHub · 2026-11-29 08:00 UTC · original

Found while running the layer under Proton on an RTX 5090 (Linux); the fix is in our fork's tree and tested there. Diffs are against current main (e1f2eb60) and compile there.

What happens

With VICTORY_FULLSCREEN=1 and a picture smaller than the screen, lifecycle::fullscreen spawns the black backdrop window and shows it with SetWindowPos(backdrop, hwnd, …, SWP_SHOWWINDOW) — the insert-after the game window as the Z-order request. A window that has just been mapped lands on top whatever was asked for: under xfwm4 (Xfce, X11) the backdrop covered the game. The screen is black; the Alt-Tab thumbnail of the game window holds the right picture; the log says borderless fullscreen applied screen=(3440, 1440) content=(2560, 1440) placed=(440, 0, 2560, 1440) and the game runs.

Workaround: VICTORY_FULLSCREEN_BARS=0.

The change

After showing it, the backdrop goes to the bottom of the stack, where it was meant to be.

diff --git a/crates/victory-hle/src/modules/lifecycle.rs b/crates/victory-hle/src/modules/lifecycle.rs
index 05716cbda..53b9a251c 100644
--- a/crates/victory-hle/src/modules/lifecycle.rs
+++ b/crates/victory-hle/src/modules/lifecycle.rs
@@ -204,6 +204,19 @@ fn spawn_backdrop(hwnd: HWND, screen_w: i32, screen_h: i32) {
                 screen_h,
                 wm::SWP_NOACTIVATE | wm::SWP_SHOWWINDOW,
             );
+            // A window just mapped lands on top whatever Z-order was asked
+            // for: xfwm4 put this black backdrop over the game (2026-11-29,
+            // under Proton; the Alt-Tab thumbnail held the picture). To the
+            // bottom of the stack, where it was meant to be.
+            wm::SetWindowPos(
+                backdrop,
+                1usize as _, // HWND_BOTTOM
+                0,
+                0,
+                0,
+                0,
+                wm::SWP_NOMOVE | wm::SWP_NOSIZE | wm::SWP_NOACTIVATE,
+            );
         }
     }
 }
**@⁠birdneststream** on GitHub · 2026-11-29 08:00 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/2031) Found while running the layer under Proton on an RTX 5090 (Linux); the fix is in our fork's tree and tested there. Diffs are against current `main` (`e1f2eb60`) and compile there. ## What happens With `VICTORY_FULLSCREEN=1` and a picture smaller than the screen, `lifecycle::fullscreen` spawns the black backdrop window and shows it with `SetWindowPos(backdrop, hwnd, …, SWP_SHOWWINDOW)` — the insert-after the game window as the Z-order request. A window that has just been mapped lands on top whatever was asked for: under xfwm4 (Xfce, X11) the backdrop covered the game. The screen is black; the Alt-Tab thumbnail of the game window holds the right picture; the log says `borderless fullscreen applied screen=(3440, 1440) content=(2560, 1440) placed=(440, 0, 2560, 1440)` and the game runs. Workaround: `VICTORY_FULLSCREEN_BARS=0`. ## The change After showing it, the backdrop goes to the bottom of the stack, where it was meant to be. ```diff diff --git a/crates/victory-hle/src/modules/lifecycle.rs b/crates/victory-hle/src/modules/lifecycle.rs index 05716cbda..53b9a251c 100644 --- a/crates/victory-hle/src/modules/lifecycle.rs +++ b/crates/victory-hle/src/modules/lifecycle.rs @@ -204,6 +204,19 @@ fn spawn_backdrop(hwnd: HWND, screen_w: i32, screen_h: i32) { screen_h, wm::SWP_NOACTIVATE | wm::SWP_SHOWWINDOW, ); + // A window just mapped lands on top whatever Z-order was asked + // for: xfwm4 put this black backdrop over the game (2026-11-29, + // under Proton; the Alt-Tab thumbnail held the picture). To the + // bottom of the stack, where it was meant to be. + wm::SetWindowPos( + backdrop, + 1usize as _, // HWND_BOTTOM + 0, + 0, + 0, + 0, + wm::SWP_NOMOVE | wm::SWP_NOSIZE | wm::SWP_NOACTIVATE, + ); } } } ```
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-29 08:04:04 +00:00
Author
Owner

@⁠github-actions[bot] on GitHub · 2026-11-29 08:00 UTC · original

Please attach both logs from the run that went wrong. Without them we can only guess. Paste %LOCALAPPDATA% into the address bar of File Explorer to get there.

  1. The play log, in %LOCALAPPDATA%\victory\logs\: the newest victory-nvidia-play-<date>-<time>-<number>.log (from victory.exe) or victory-nvidia-<date>-<time>.log (from the script launcher). The window shows its path at the start, on the line Log: ....
  2. The crash log: %LOCALAPPDATA%\VIctory\data\7952987A\crashes.log, and, if there is one from that run, the newest victory-<date>-<time>-<number>.crash.log in %LOCALAPPDATA%\VIctory\data\7952987A\temp\.

Also say which GPU, Windows version (10 or 11)

**@⁠github-actions[bot]** on GitHub · 2026-11-29 08:00 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/2031#issuecomment-7252824688) Please attach both logs from the run that went wrong. Without them we can only guess. Paste `%LOCALAPPDATA%` into the address bar of File Explorer to get there. 1. The play log, in `%LOCALAPPDATA%\victory\logs\`: the newest `victory-nvidia-play-<date>-<time>-<number>.log` (from `victory.exe`) or `victory-nvidia-<date>-<time>.log` (from the script launcher). The window shows its path at the start, on the line `Log: ...`. 2. The crash log: `%LOCALAPPDATA%\VIctory\data\7952987A\crashes.log`, and, if there is one from that run, the newest `victory-<date>-<time>-<number>.crash.log` in `%LOCALAPPDATA%\VIctory\data\7952987A\temp\`. Also say which GPU, Windows version (10 or 11)
Author
Owner

@⁠birdneststream on GitHub · 2026-11-29 08:02 UTC · original

PR with the change: #2035 (one commit on main).

**@⁠birdneststream** on GitHub · 2026-11-29 08:02 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/2031#issuecomment-7252846470) PR with the change: #2035 (one commit on `main`).
Author
Owner

@⁠birdneststream on GitHub · 2026-11-29 08:08 UTC · original

Log excerpts and the environment: https://gist.github.com/birdneststream/3faf9545cecfc6ee5b2cf4e957d537e1

RTX 5090, Linux, Xfce (xfwm4) on X11, 3440x1440. With VICTORY_FULLSCREEN_BARS=0 the same build shows the game; with the backdrop, xfwm4 maps it over the game window.

**@⁠birdneststream** on GitHub · 2026-11-29 08:08 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/2031#issuecomment-7252911526) Log excerpts and the environment: https://gist.github.com/birdneststream/3faf9545cecfc6ee5b2cf4e957d537e1 RTX 5090, Linux, Xfce (xfwm4) on X11, 3440x1440. With `VICTORY_FULLSCREEN_BARS=0` the same build shows the game; with the backdrop, xfwm4 maps it over the game window.
Author
Owner

@⁠trustno1-coder on GitHub · 2026-11-30 15:37 UTC · original

Closing this because it was opened before v2026.11.29.01, and a great deal has changed since then. The latest release is v2026.11.30.01.

If this still happens, or still applies, on the latest release, please open a new issue. For a bug, attach both logs from that run:

  1. The play log: the newest victory-nvidia-play-<date>-<time>-<number>.log in %LOCALAPPDATA%\victory\logs\.
  2. The crash log: %LOCALAPPDATA%\VIctory\data\7952987A\crashes.log, plus the newest .crash.log in %LOCALAPPDATA%\VIctory\data\7952987A\temp\ if there is one from that run.
**@⁠trustno1-coder** on GitHub · 2026-11-30 15:37 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/2031#issuecomment-7283304492) Closing this because it was opened before v2026.11.29.01, and a great deal has changed since then. The latest release is [v2026.11.30.01](https://github.com/trustno1-coder/VIctory-NVIDIA/releases/tag/v2026.11.30.01). If this still happens, or still applies, on the latest release, please open a new issue. For a bug, attach both logs from that run: 1. The play log: the newest `victory-nvidia-play-<date>-<time>-<number>.log` in `%LOCALAPPDATA%\victory\logs\`. 2. The crash log: `%LOCALAPPDATA%\VIctory\data\7952987A\crashes.log`, plus the newest `.crash.log` in `%LOCALAPPDATA%\VIctory\data\7952987A\temp\` if there is one from that run.
This discussion has been locked. Commenting is limited to contributors.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/trustno1-coder--VIctory-NVIDIA#2031
No description provided.