Which API to use?

Asked by Joe Warren-Meeks on 2014-03-24

Hi there,

I have written an extension to wmctrl to do some sane-ish auto-tiling of windows. It's in C and uses Xlib.

I would like to re-implement it as a new keyboard shortcut in Gala written in Vala. I'm not sure which is the best API to use though. I need to get the list of all windows on the current desktop, determine which screen they are on and then move and resize them, ideally understanding the true geometry of them, including window decorations etc.

Any pointers to where to start looking? I've trawled through the GTK3.0 docs, but can't find what I'm looking for..


 -- joe.

Question information

English Edit question
Gala Edit question
No assignee Edit question
Solved by:
Joe Warren-Meeks
Last query:
Last reply:
Tom Beckmann (tombeckmann) said : #1

If you can be patient, you'll be able to write plugins for gala once Isis is released. You'll get access to the entire libmutter API at that point. Otherwise you may want to try wnck, which is pretty much standard for wm interactions with gobject I'd say.

Hey Tom,

Thanks for that. I actually wrote itin C using wmctrl, so I might try to port it into mutter and see if that works.

If not, I'l pick up this.