I am trying to monitor events between two widgets in another process.

I know from seeing some of the source that the event is sent like this:
XEvent e;
e.xclient.type = ClientMessage;

I can find the target window id and catch some events like xev does
using XSelectInput() and XNextEvent() (I looked at the xev source).
Unfortunately it doesn't see these client events. I only see events
generated by clicking the window, moving etc.

- I know I have the correct target window id (using xwininfo).
- I know I am capturing some events by moving the pointer over the
window and seeing a response from my code.

I admit I don't know much about the X system. What am I missing? Is it
even possible to do this?