### Godot version

4.0

### System information

Windows 11

### Issue description

So on my monitor with 2560x1440 resolution retrieved by the `DisplayServer.get_window_size` method shows 2562x1442, which I think is incorrect. A similar result returned by `get_viewport().size`. But it's become correct if the `Resizable` property is turned on.

![image](https://user-images.githubusercontent.com/3036176/212492776-5c09b12e-d25a-4951-8392-54f5a5e3bece.png)


### Steps to reproduce

Create the project, add a label to observe the resolution text, set the full-screen mode in the project settings, toggle off the `Resizable` property, and run the project.

### Minimal reproduction project

[TestResolution.zip](https://github.com/godotengine/godot/files/10418682/TestResolution.zip)

Color early_color;
			if (!_get_window_early_clear_override(early_color)) {
				break;
			}
			bool must_recreate_brush = !window_bkg_brush || window_bkg_brush_color != early_color.to_argb32();
			if (must_recreate_brush) {
				if (window_bkg_brush) {
					DeleteObject(window_bkg_brush);
				}
				window_bkg_brush = CreateSolidBrush(RGB(early_color.get_r8(), early_color.get_g8(), early_color.get_b8()));
			}
			HDC hdc = (HDC)wParam;
			RECT rect = {};
			if (GetUpdateRect(hWnd, &rect, true)) {
				FillRect(hdc, &rect, window_bkg_brush);
			}
			return 1;
		} break;
		case WM_PAINT: {
			Main::force_redraw();
		} break;
		case WM_SETTINGCHANGE: {
			if (lParam && CompareStringOrdinal(reinterpret_cast<LPCWCH>(lParam), -1, L"ImmersiveColorSet", -1, true) == CSTR_EQUAL) {
				if (is_dark_mode_supported() && dark_title_available) {
					BOOL value = is_dark_mode();
					::DwmSetWindowAttribute(windows[window_id].hWnd, DWMWA_USE_IMMERSIVE_DARK_MODE, &value, sizeof(value));
				}
			}
		} break;
		case WM_THEMECHANGED: {