title: GetWindowRect returns different values than Spy++
body: <p>I am trying to get a HWND's rectangle by the use of the Win32 <code>GetWindowRect</code> function. However, such a function does not seem to retrieve the correct values.</p>
  
  <p>The window that I want the size of is a DosBox window, and I can see the correct values through Spy++. As you can see, the HWND I'm querying the size of is the correct one, but the values do not match.</p>
  
  <p><a href="https://i.stack.imgur.com/dSFGn.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/dSFGn.png" alt="enter image description here"></a></p>
  
  <p>I've tried also to use <code>DwmGetWindowAttribute</code>, but the values returned are the same, wrong ones.</p>