How can I input something like CTRL+'something' / SHIFT+'something' / ALT+ 'something' to my python script.
BACKGROUND: I'm trying to build a python based application where my script will keep running in the background no matter what application or program I'm actively using, and when I press a keyboard shortcut (that I want to know how to assign), the script will act up (do something that I've programmed it to do).
I'm a beginner and have no Idea how windows or other desktop applications take keyboard shortcuts as input and perform tasks.
I do know that keystrokes like CTRL/SHIFT/ALT cannot be given as console inputs to a python script. Then how can I program such shortcuts into my application?
All my web searches have led to questions like "How to 'simulate' keystrokes in python" but none have given me a basic explanation of how shortcuts actually work. Is there anything to this other than python (some windows framework maybe)? Please help!