Re: Recording Window Coordinates



On 12 Mar 2006 10:40:20 -0800, Fahd staggered into the Black Sun and
said:
I am trying to record window coordinates for all open windows in a
session. I have tried using xwininfo, however, for many windows it
simply reports the same x,y coordinates, specifically 10.

xwininfo is probably the wrong tool for this job. Try "wmctrl -l -G" ,
and you'll get a bunch of lines like so:

0x01200008 -1 0 977 1280 47 samantha kicker

....meaning window 0x01200008 (kicker) starts at (0,977) and is 1280
pixels wide and 47 pixels high. Much easier to interpret than
xwininfo's output. Note that the geometries that wmctrl lists don't
take titlebars or window borders into account, though, just the windows.
HTH,

--
Matt G|There is no Darkness in Eternity/But only Light too dim for us to see
Brainbench MVP for Linux Admin / mail: TRAP + SPAN don't belong
http://www.brainbench.com / "He is a rhythmic movement of the
-----------------------------/ penguins, is Tux." --MegaHAL
.



Relevant Pages