event propagation and window hierarchy

Jason Roscoe jason.roscoe at gmail.com
Tue Aug 22 14:30:04 UTC 2017


I am seeing a behavior difference between an older Xorg version and a newer
one and I would like to understand if this may be an old bug or a new bug.
I realize both of these servers are unsupported but based on my perusal of
the source code I would expect that the behavior of the current version of
Xorg is the same as in 1.15.0.

Old server version: 7.1.1 (RHEL5)
New server version: 1.15.0 (RHEL7.1)

The window tree looks essentially like this on both servers:

  Root window id: 0x10d (the root window) (has no name)
  Parent window id: 0x0 (none)
     3 children:
     0x20000a "dpmxinput": ("dpmxinput" "TopLevelShell")  500x500+0+0  +0+0
        1 child:
        0x20000f (has no name): ()  500x500+0+0  +0+0
     0x200003 (has no name): ()  1x1+0+0  +0+0
     0x200002 "dpmxinput": ("dpmxinput" "dpmxinput")  1x1+0+0  +0+0

The sequence of calls to create the above window hierarchy is as follows:

Note, I'm trying to be terse here but all details and source code can be
provided if necessary.


XtAppContext app_context = XtCreateApplicationContext()
Display *pD = XtOpenDisplay(app_context, ":0", NULL, "dpmxinput", ...)

Widget topLevel = XtVaAppCreateShell("dpmxinput", "dpmxinput",
topLevelShellWidgetClass, ...)

Widget topForm = XtVaCreateWidget("topForm", xmFormWidgetClass, topLevel,

Window event_win = XtWindow(topLevel)

Note, event_win is id 0x20000a.

XSelectExtensionEvent(pD, event_win, ...)

Now an event loop runs checking for the extension events from the

The problem is that on the older Xorg version, touch events are propagated
to the window with id 0x20000a, the "TopLevelShell".  However, on the newer
Xorg version, these events do not make it to this window.  Instead they go
to the window that was created with the Motif call to create a XmForm
widget (0x20000f in this example).

If the source code is changed so that the XmForm widget is not created at
all then the events go to the TopLevelShell window (0x20000a) on both Xorg

What *should* the behavior be here?

Note, I see that changes in this area between these versions of Xorg code
have to do with the implementation of the Xinput 2 extension.

Any help is greatly appreciated!  Thanks in advance and please let me know
if more information is needed or you have any questions.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.x.org/archives/xorg/attachments/20170822/56dd2be0/attachment.html>

More information about the xorg mailing list