diff --git a/include/notcurses.h b/include/notcurses.h index 48a6a4b22..1860fb634 100644 --- a/include/notcurses.h +++ b/include/notcurses.h @@ -192,6 +192,16 @@ wchar_supppuab_p(wchar_t w){ #define NCKEY_F18 suppuabize(38) #define NCKEY_F19 suppuabize(39) #define NCKEY_F20 suppuabize(40) +#define NCKEY_F21 suppuabize(41) +#define NCKEY_F22 suppuabize(42) +#define NCKEY_F23 suppuabize(43) +#define NCKEY_F24 suppuabize(44) +#define NCKEY_F25 suppuabize(45) +#define NCKEY_F26 suppuabize(46) +#define NCKEY_F27 suppuabize(47) +#define NCKEY_F28 suppuabize(48) +#define NCKEY_F29 suppuabize(49) +#define NCKEY_F30 suppuabize(50) // ... leave room for up to 100 function keys, egads #define NCKEY_ENTER suppuabize(121) #define NCKEY_CLS suppuabize(122) // "clear-screen or erase" diff --git a/src/input/input.cpp b/src/input/input.cpp index 7feca5685..def083630 100644 --- a/src/input/input.cpp +++ b/src/input/input.cpp @@ -39,6 +39,24 @@ const char* nckeystr(wchar_t spkey){ case NCKEY_F10: return "F10"; case NCKEY_F11: return "F11"; case NCKEY_F12: return "F12"; + case NCKEY_F13: return "F13"; + case NCKEY_F14: return "F14"; + case NCKEY_F15: return "F15"; + case NCKEY_F16: return "F16"; + case NCKEY_F17: return "F17"; + case NCKEY_F18: return "F18"; + case NCKEY_F19: return "F19"; + case NCKEY_F20: return "F20"; + case NCKEY_F21: return "F21"; + case NCKEY_F22: return "F22"; + case NCKEY_F23: return "F23"; + case NCKEY_F24: return "F24"; + case NCKEY_F25: return "F25"; + case NCKEY_F26: return "F26"; + case NCKEY_F27: return "F27"; + case NCKEY_F28: return "F28"; + case NCKEY_F29: return "F29"; + case NCKEY_F30: return "F30"; case NCKEY_BACKSPACE: return "backspace"; case NCKEY_CENTER: return "center"; case NCKEY_ENTER: return "enter"; diff --git a/src/lib/input.c b/src/lib/input.c index 1fc285138..d4726c2c0 100644 --- a/src/lib/input.c +++ b/src/lib/input.c @@ -256,6 +256,16 @@ int prep_special_keys(notcurses* nc){ { .tinfo = "kf18", .key = NCKEY_F18, }, { .tinfo = "kf19", .key = NCKEY_F19, }, { .tinfo = "kf20", .key = NCKEY_F20, }, + { .tinfo = "kf21", .key = NCKEY_F21, }, + { .tinfo = "kf22", .key = NCKEY_F22, }, + { .tinfo = "kf23", .key = NCKEY_F23, }, + { .tinfo = "kf24", .key = NCKEY_F24, }, + { .tinfo = "kf25", .key = NCKEY_F25, }, + { .tinfo = "kf26", .key = NCKEY_F26, }, + { .tinfo = "kf27", .key = NCKEY_F27, }, + { .tinfo = "kf28", .key = NCKEY_F28, }, + { .tinfo = "kf29", .key = NCKEY_F29, }, + { .tinfo = "kf30", .key = NCKEY_F30, }, { .tinfo = "kent", .key = NCKEY_ENTER, }, { .tinfo = "kclr", .key = NCKEY_CLS, }, { .tinfo = "kc1", .key = NCKEY_DLEFT, },