I get the same problem and I am not using Msys2 but Ada under a version of GNAT Studio and Gtkada from 2021. Searching on internet show as a probable cause the fact that I am using now an high definition screen. Programs that I had compiled earlier also had the problem just by running there exe file.The new one also shows this problem while the compilation crates a .exe file.