From: Rémi Bernon <rbernon@codeweavers.com> It already includes the present rect if any, relative to the toplevel visible rect. We lost the latter here, when rect computation was moved to win32u, and rendering was offsetted when present rect is set. --- dlls/winex11.drv/init.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/dlls/winex11.drv/init.c b/dlls/winex11.drv/init.c index a3078d73d64..e8bfe11509d 100644 --- a/dlls/winex11.drv/init.c +++ b/dlls/winex11.drv/init.c @@ -382,23 +382,21 @@ static void X11DRV_client_surface_present( struct client_surface *client, HDC hd { struct x11drv_client_surface *surface = impl_from_client_surface( client ); HWND hwnd = client->hwnd, toplevel = client->toplevel; - RECT rect_dst, rect_src = client->virtual_rect, rect; + RECT rect_dst = client->monitor_rect, rect_src = client->virtual_rect, rect; Drawable window; HRGN region; if (!hdc) return; window = X11DRV_get_whole_window( toplevel ); - if (NtUserGetPresentRect( toplevel, &rect_dst, -1 /* raw dpi */ )) + if (NtUserGetPresentRect( toplevel, &rect, -1 /* raw dpi */ )) { region = 0; /* window is exclusive fullscreen, ignore everything else */ if (toplevel != hwnd) return; /* toplevel is exclusive fullscreen, don't present */ - OffsetRect( &rect_dst, -rect_dst.left, -rect_dst.top ); } else { region = get_dc_monitor_region( hwnd, hdc ); /* otherwise use the window region for clipping rules */ - rect_dst = client->monitor_rect; } if (get_dc_drawable( surface->hdc_dst, &rect ) != window || !EqualRect( &rect, &rect_dst )) -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/11726