Opening new window while out of focus using “keyboard”
问题 I am trying to track my keypresses, using the module "keyboard" while a PySide2 Widget is not in focus, which works fine. However when I try to create a new Widget using a "keyboard" shortcut the program crashes. Opening a window on a button press works fine. I can also call non UI functions using "keyboard" eg. the print function without any problem. Do you know a way to fix this and open a new window using "keyboard" or any other method, while a PySide2 window is not in focus. In this