=== modified file 'termkey.c' --- termkey.c 2008-10-06 21:39:00 +0000 +++ termkey.c 2008-10-06 21:33:49 +0000 @@ -884,6 +884,12 @@ } } + 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; @@ -893,12 +899,6 @@ 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;