views:

63

answers:

2

Hi all,

I am looking for a library to get some information from the active windows. By "information" I mean the absolute/relative position of the window, the size, the list of all the windows.

There is a function in GTK+ called get_window_list_toplevels() or get_root_window() but I get only the windows information realized with GTK.

I want a library compatible with all more used operating system (like Windows/Linux/Mac OS).

I have already studded some binaries like xwininfo given by X11 but the information is extracted only for X system. There is also some information regarding how to get window information on Win32-based system on MSDNAA but it still not enough. I want to know if there is something already done before doing that my self what I do not hide that it may be a big work.

Thanks in advance for your answer.

A: 

gdk_screen_get_toplevel_windows (doc) should return list of all toplevel windows on a given screen.

dmitry_vk
A: 

Window management works very differently on different platforms, so each major platform will probably need a separate back end.

Under Linux, you may want to look at libwnck (Window Navigator Construction Kit) which provides the details you need. As far as I know, this isn't cross-platform.

Kai