How to detect if an Xwindow has focus?

Printable View