diff options
author | Paul LeoNerd Evans <leonerd@leonerd.org.uk> | 2008-10-06 22:39:00 +0100 |
---|---|---|
committer | Paul LeoNerd Evans <leonerd@leonerd.org.uk> | 2008-10-06 22:39:00 +0100 |
commit | e0671d1a01dcac4d69087127122daa89188fab5e (patch) | |
tree | 8730f8f84d9aa555d224bb2eba6daf6c1dcaef17 /termkey.c | |
parent | 0b8680daa45d22b3d61b064faaf4114d0cf57d0c (diff) | |
download | termo-e0671d1a01dcac4d69087127122daa89188fab5e.tar.gz termo-e0671d1a01dcac4d69087127122daa89188fab5e.tar.xz termo-e0671d1a01dcac4d69087127122daa89188fab5e.zip |
Print Alt/Meta before Ctrl
Diffstat (limited to 'termkey.c')
-rw-r--r-- | termkey.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -884,12 +884,6 @@ size_t termkey_snprint_key(termkey_t *tk, char *buffer, size_t len, termkey_key } } - if(key->modifiers & TERMKEY_KEYMOD_CTRL) { - l = snprintf(buffer + pos, len - pos, longmod ? "Ctrl-" : "C-"); - if(l <= 0) return pos; - pos += l; - } - if(key->modifiers & TERMKEY_KEYMOD_ALT) { int altismeta = format & TERMKEY_FORMAT_ALTISMETA; @@ -899,6 +893,12 @@ size_t termkey_snprint_key(termkey_t *tk, char *buffer, size_t len, termkey_key pos += l; } + if(key->modifiers & TERMKEY_KEYMOD_CTRL) { + l = snprintf(buffer + pos, len - pos, longmod ? "Ctrl-" : "C-"); + if(l <= 0) return pos; + pos += l; + } + if(key->modifiers & TERMKEY_KEYMOD_SHIFT) { l = snprintf(buffer + pos, len - pos, longmod ? "Shift-" : "S-"); if(l <= 0) return pos; |