Here is some weirdness- for me, EU4 Windowed at 1920×1080 works, but Windowed at 2560×1440 doesn’t!
Maybe internally it is checking if the windowed resolution matches native resolution, and if so, silently switch to Windowed (Fullscreen) aka Borderless. This is after exiting (not uninstalling) Geforce Experience btw. But running EU4 seems to start GFE in the background anyway.
I love my Tobii and its amazing how spoiled it made me. “Ugh, I have to move the cursor myself? Like the stone ages?” when I lose mouse warp.
What worked for me was switching from VS2019 to VS2017