Class ManagedKeyboardShortcut encapsulates the combination of modifier keys and another key that activates a command.
More...
#include <ManagedKeyboardShortcut.h>
|
static ManagedKeyboardShortcut | fromString (const std::string &s) |
| Creates a shortcut from a string. More...
|
|
static std::list< std::string > | splitString (const std::string &s, char c, bool doNotSplitAtLastChar=false) |
|
static std::string | strip (const std::string &s) |
| Strips whitespaces away. More...
|
|
template<typename T > |
static std::string | join (const std::list< T > &l, const std::string &s) |
| Joins a list of objects having a .toString() method, using a separator string s. More...
|
|
Class ManagedKeyboardShortcut encapsulates the combination of modifier keys and another key that activates a command.
Definition at line 26 of file ManagedKeyboardShortcut.h.
◆ ManagedKeyboardShortcut() [1/2]
ManagedKeyboardShortcut::ManagedKeyboardShortcut |
( |
| ) |
|
|
inline |
◆ ManagedKeyboardShortcut() [2/2]
ManagedKeyboardShortcut::ManagedKeyboardShortcut |
( |
int |
modifiers, |
|
|
SoKeyboardEvent::Key |
key |
|
) |
| |
|
inline |
◆ fromString()
Creates a shortcut from a string.
Strings can take the form "[S[hift]-][C[trl]-][A[lt]-]Keyname". For acceptable keynames look at ManagedKeyboardShortcut.cpp.
◆ getKey()
SoKeyboardEvent::Key ManagedKeyboardShortcut::getKey |
( |
| ) |
const |
|
inline |
◆ getModifiers()
int ManagedKeyboardShortcut::getModifiers |
( |
| ) |
const |
|
inline |
◆ isValid()
bool ManagedKeyboardShortcut::isValid |
( |
| ) |
const |
- Returns
- whether the shortcut is valid.
◆ matches()
bool ManagedKeyboardShortcut::matches |
( |
int |
modifiers, |
|
|
SoKeyboardEvent::Key |
key |
|
) |
| const |
- Returns
- whether the shortcut matches the given modifiers and key; see SoInteraction for possible modifiers.
◆ toString()
std::string ManagedKeyboardShortcut::toString |
( |
| ) |
const |
- Returns
- a string representation of this shortcut (see fromString()).
The documentation for this class was generated from the following file: