Capturing keyboard event of child components

I have added keyboard press listener in main component with


and I expected all typing in the low level components will generate event.
but the receiver is silent.

in case of mouse, using
addMouseListener (&xsnUserActionRecoder,true);

report all action event inside the main component.

How can I make a same function for keyboard like mouse case ?

Why do you want to capture all the key events? If it’s for implementing key shortcuts, you’d be much better off using the ApplicationCommand classes.

Or you could implement the keyPressed callback - the top level component will have any unwanted key events passed up to it if they’re not claimed by other components.

I made a temporal solution by looking some considerable components.