X11 error from home grown application

Aaron Plattner aplattner at nvidia.com
Wed May 19 15:39:43 PDT 2010


On Wed, May 19, 2010 at 01:02:35PM -0700, Keith Packard wrote:
> On Wed, 19 May 2010 14:58:16 -0400, Geoffrey <lists at serioustechnology.com> wrote:
> 
> > Can you define 'viewable'?
> 
> From the X protocol glossary:
> 
> .LP
> \fBViewable\fP
> .IN "Viewable" "" "@DEF@"
> .IP
> A window is viewable if it and all of its ancestors are mapped.
> This does not imply that any portion of the window is actually visible.
> Graphics requests can be performed on a window when it is not viewable,
> but output will not be retained unless the server is maintaining
> backing store.

That seems misleading... the server makes a distinction between 'realized'
and 'viewable':

1. The root window is always realized.
2. A window is realized if it's mapped and its parent is realized.
3. A window is viewable if it's realized and its class is InputOutput.

SetInputFocus only checks that the window is realized, so it should work
with InputOnly windows.  The comment is pretty fantastic:

        /* It is a match error to try to set the input focus to an
        unviewable window. */
        if(!focusWin->realized)
            return(BadMatch);



More information about the xorg mailing list