From bc0efb86a9879584aa809d95200a09e6b4ec0481 Mon Sep 17 00:00:00 2001 From: Hilderin <81109165+Hilderin@users.noreply.github.com> Date: Sat, 1 Feb 2025 22:27:57 -0500 Subject: [PATCH] Fix Floating Window overlapping when on screen edge --- platform/linuxbsd/x11/display_server_x11.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/platform/linuxbsd/x11/display_server_x11.cpp b/platform/linuxbsd/x11/display_server_x11.cpp index cbd3662986..620f1bf30b 100644 --- a/platform/linuxbsd/x11/display_server_x11.cpp +++ b/platform/linuxbsd/x11/display_server_x11.cpp @@ -1364,8 +1364,6 @@ Rect2i DisplayServerX11::screen_get_usable_rect(int p_screen) const { } if (desktop_valid) { - use_simple_method = false; - // Handle bad window errors silently because there's no other way to check // that one of the windows has been destroyed in the meantime. int (*oldHandler)(Display *, XErrorEvent *) = XSetErrorHandler(&bad_window_error_handler); @@ -1393,6 +1391,8 @@ Rect2i DisplayServerX11::screen_get_usable_rect(int p_screen) const { } } if (!g_bad_window && strut_found && (format == 32) && (strut_len >= 4) && strut_data) { + use_simple_method = false; + long *struts = (long *)strut_data; long left = struts[0];