That looks great. Maybe I can update libQt5Pas for next major lazarus version so no need for extra c library. You code can be added to qt5 interface (with your permission of course), but in that case it can be splitted for gtk2,gtk3,qt and qt5 interfaces. Or create package for hotkeys and use it on demand.