### Godot version

 Latest 4.0.dev (a3a42159e31db27f8ae7c1ecad6a9ed417cb05de)

### System information

Ubuntu 22.04.1 LTS

### Issue description

![image](https://user-images.githubusercontent.com/85438892/214476911-0ce83a43-b959-4b13-88fd-d6b9af0cd63a.png)

### Steps to reproduce

Open any script

### Minimal reproduction project

N/A
XSendEvent(x11_display, DefaultRootWindow(x11_display), False, SubstructureRedirectMask | SubstructureNotifyMask, &xev);
	
	Atom bypass_compositor = XInternAtom(x11_display, "_NET_WM_BYPASS_COMPOSITOR", False);
	unsigned long compositing_disable_on = 0; 
	if (p_enabled) {
		if (p_exclusive) {
			compositing_disable_on = 1; 
		} else {
			compositing_disable_on = 2; 
		}
	}
	if (bypass_compositor != None) {
		XChangeProperty(x11_display, wd.x11_window, bypass_compositor, XA_CARDINAL, 32, PropModeReplace, (unsigned char *)&compositing_disable_on, 1);
	}
	XFlush(x11_display);
	if (!p_enabled) {
		
		_update_size_hints(p_window);
		
		Hints hints;
		Atom property;
		hints.flags = 2;
		hints.decorations = wd.borderless ? 0 : 1;
		property = XInternAtom(x11_display, "_MOTIF_WM_HINTS", True);
		if (property != None) {
			XChangeProperty(x11_display, wd.x11_window, property, property, 32, PropModeReplace, (unsigned char *)&hints, 5);
		}
	}
}
void DisplayServerX11::window_set_mode(WindowMode p_mode, WindowID p_window) {