Using 'open' will not create an X11 window (while open_window does), so we will get spurious motion notify events when switching focus, leading to endless loops.