forked from: https://github.com/MOZGIII/QxtGlobalShortcut
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
1 year ago | |
---|---|---|
example/demo | 8 years ago | |
src | 1 year ago | |
.gitignore | 10 years ago | |
COPYING | 12 years ago | |
QxtGlobalShortcut.pri | 8 years ago | |
README.md | 8 years ago | |
cpl1.0.txt | 16 years ago | |
lgpl-2.1.txt | 15 years ago |
README.md
QxtGlobalShortcut
Extracted from libqxt.
History and initial file structure is preserved to make possible cherry-picking potential changes from libqxt.
Everything not required for QxtGlobalShortcut
to work is removed.
For more info on the original libqxt
project check out their repo on Bitbucket: https://bitbucket.org/libqxt/libqxt
Usage
This project is designed for static linking.
- Add source code to your project.
I recommend using git submodules unless you have a better option.
- Enable
QxtGlobalShortcut
by importing provided.pri
file:
In your .pro
file add:
# Adding QxtGlobalShortcut
include(path/to/QxtGlobalShortcut/QxtGlobalShortcut.pri)
- Include
"qxtglobalshortcut.h"
and useQxtGlobalShortcut
class:
#include "qxtglobalshortcut.h"
...
QxtGlobalShortcut myShortcut(QKeySequence("Shift+F1"));
QObject::connect(&myShortcut, SIGNAL(activated()), something, SLOT(shortcutActivated()));
For a more complete usage example see examples
dir.