xwininfo

Print window properties and geometry on X11 servers.

brewmacoslinux
Try with needOr install directly
Source

About

Print information about windows on an X server

Commands

xwininfo

Examples

get window size and position$ xwininfo
find window ID by clicking on it$ xwininfo -id $(xdotool getactivewindow)
show all properties of a specific window$ xwininfo -id 0x4a00001 -all
get window tree and hierarchy information$ xwininfo -root -tree
display pixel coordinates and color under cursor$ xwininfo -pixel