robotgo
robotgo copied to clipboard
Window possition on screen by hwnd (Windows)
How can I read the position and size of the window after hwnd?
https://github.com/go-vgo/robotgo/issues/87 Only Windows you can try package github.com/lxn/win.
var rect win.RECT
win.GetWindowRect(hwnd, &rect)
posionX := int(rect.Left)
posionY := int(rect.Top)
hwndWidth := int(rect.Right - rect.Left)
hwndHeight := int(rect.Bottom - rect.Top)