Opening a window without activating it

Andreas Falkenhahn andreas at airsoftsoftwair.de
Sun May 16 07:27:57 PDT 2010


> On Sun, May 16, 2010 at 11:42:59AM +0200, Andreas Falkenhahn wrote:
>> Hi,
>>
>> is it possible to open a window without it automatically becoming
>> active?
>> I see that there are two different calls to map a window: XMapWindow()
>> and
>> XMapRaised(). However, both calls open the window and make it active.
>> Can
>> I change this behaviour? I'd like to open a window and prevent it from
>> taking away user focus.
>
> That's really the responsibility of the window manager. Maybe you can
> set certain window properties or WM hints to prevent the WM from
> giving focus to the new window. Check out EWMH[0].

I already checked out EWMH but I don't see any properties in that
specification which could do what I want. But it must be possible to open
a window without taking away focus from the currently active window
because, for instance, on my openSUSE installation, I often get reminders
that new updates are available. These reminders are displayed in a little
pop up that opens right above the task bar but does *not* take away the
focus.

What I'm also wondering is where is the difference between XMapWindow()
and XMapRaised()? AFAICS, both calls do exactly the same...

Greets,

Andreas



More information about the xorg mailing list