Odd behavior with borderless window

I have implemented a menu for changing resolution and display mode (fullscreen/windowed/borderless window) and I am seeing some odd behavior when using a borderless window at the desktop resolution (1920x1080 in my case).

When the game window has focus the game is drawn across the entire screen regardless of the game window position.

If the game window is placed across two screens the game is drawn on one screen while the game window is still open on the other screen. The game window does not get redrawn, only the screen filling view. I tried taking a screenshot to show this, but the screen filling view did not show up in it.

Even if only using a single monitor, the game window appears to shift around when alt+tabbing.

Mouse input appears to be relative to the game window, not where the game is being drawn.

These issues can be avoided by setting the window position to 0, 0.

I also can’t alt+tab away when execution is frozen by the debugger.

None of this happens when using a borderless window at a lower resolution.

I am using the 3.8 prerelease of DesktopGL on Window

I have seen similar issues when I have a bordered window placed partially off screen. I’ve also observed these issues outside of MonoGame in a window system developed using the Win32 API, so I think it might be something related to the core API.

I know there are games that handle rendering across multiple monitors, and 3rd party devices that facilitate ultra wide resolutions, but I suspect this is a challenging issue to solve.

I’m sorry I don’t have any solutions for you, but I wanted to let you know that you’re not the only one who has experienced this weirdness!