GetClientRect() fails on closed hwnd which left the rectangle uninitialized and copied to DisplaySize. Ensure it is zero + similar failsafe in io.WantSetMousePos path.
IM_ASSERT(io.Fonts->IsBuilt()&&"Font atlas not built! It is generally built by the renderer backend. Missing call to renderer _NewFrame() function? e.g. ImGui_ImplOpenGL3_NewFrame().");
// Setup display size (every frame to accommodate for window resizing)