Re: [gtkmm] Window Manager functionality via gtkmm



On Mon, 2004-02-23 at 21:27, Callum Prentice wrote:
> one of the responsibilities of my app is to provide some simple window manager type
> functionality so that when on startup and whenever windows are created or destroyed, my apps
> sees the relevant events and does the right thing.
> 
> i figure that either i can get what i need via the regular gtkmm event structure or else find
> some non-blocking alternative to Gtk::Main::run () and do the work myself in my main loop.
> 
> any suggestions ?

You would simply duplicate the main loop. Now, depending on what you
want, there are several ways to do it.
     1. set (on the X11 level) the CreateNotifyMask event on the root
        window to get events whenever windows are created. Problem is
        that you may not get the event as the window manager may have
        overridden the default behavior in order to put a frame around
        windows.
     2. If you just want application windows, you can have a look at the
        properties of each window. For an example, have a look at the
        taskmanager applet of gnome.
HTH,
Tassos Bassoukos
-- 
Beware of he who would deny you access to information, for in his
heart he dreams himself your master." 
	-- Commissioner Pravin Lal, Sid Meier's Alpha Centauri




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]