Windows IME position is wrong when Aero glass is enabled
Submitted by Mikayla Hutchinson
Assigned to gtk-win32 maintainers
The GTK+ Windows IME uses the Win32 function GetWindowRect to get the window position because the caret position it passes to ImmSetCandidateWindow must be relative to the window origin, not the client origin. However, on Vista/Win7, GetWindowRect doesn't return the correct value if DWM compositing (Aero Glass) is enabled. The correct value can be obtained using DwmGetWindowAttribute when DwmIsCompositionEnabled indicates that DWM is enabled.