[Top][All Lists]

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

Re: Should window manager bring menu back ?

From: Chris B. Vetter
Subject: Re: Should window manager bring menu back ?
Date: Thu, 23 Oct 2003 19:56:39 -0700

On Thu, 23 Oct 2003 22:24:34 -0400
"Yen-Ju Chen" <address@hidden> wrote:
>   I met a problem that menu doesn't come back even GNUstep window
>   receive  the focus (Check by --GNU-Debug=Focus with Ink) in StepBox.
>   Who is reponsible to make menu appear ? Window manager or GNUstep ?

The window manager is in charge, not GNUstep.

Mapping and Unmapping is task of the window manager, while it will send
a X11 notification to the client that the window
  a) will be un/mapped
  b) has finished un/mapping.

This to prepare the client for a possibly necessary redraw.

>   Any hint why menu doesn't come back even Ink document window got
>   focus?

Probably because one or both of them is/are ignoring the Un/map

The problem here is, that a Map request does not necessarily mean that a
window WILL be mapped (and therefor be visible).

Whether it is or not, depends on the state of its _ancestor_.

As long as a window's ancestor is unmapped (ie. not visible) the window
you want to map, won't be.

Only when ALL its ancestors are mapped, the window itself becomes
viewable and will be visible (if it is not obscured by another window,
of course ;-)

Think of it as a linked list (actually, I think they are). To get to the
nth window, you'll have to traverse down the list, accessing each of
the entries to see if it's the one you want. By accessing each entry,
you turn it visible. (Ok, bad analogy, but I think you understand)

>   By the way, from Xwindow's point of view, when GNUstep application
>   lost focus, menu and panel will disappear. Where do they go ? Just
>   hide ?

That depends on your WM and the notification it sends/receives. It may
be in a WithDrawn state or destroyed.

If you forcibly try to map the menu window and get an X11 error ala
"invalid window" it was destroyed (well, that should be obvious ;-)

>   PS. StepBox send a ClientMessage to notify GNUstep window to take
>   the focus. I think it is a right way.

It is a workaround.

I don't want to appear rude, but I suggest you read at least through the
manuals at http://tronche.com/gui/x/

Especially ICCCM chapter 4, Client to Window Manager Communication.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]