* key.c (init_key): Load xterm_key_defines for terminals with

names starting with "rxvt".
This commit is contained in:
Pavel Roskin 2005-03-21 20:27:55 +00:00
parent bda4ef1f88
commit 504faf19d4
2 changed files with 17 additions and 11 deletions

View File

@ -1,3 +1,8 @@
2005-03-21 Pavel Roskin <proski@gnu.org>
* key.c (init_key): Load xterm_key_defines for terminals with
names starting with "rxvt".
2005-03-19 Pavel Roskin <proski@gnu.org> 2005-03-19 Pavel Roskin <proski@gnu.org>
* slint.c: Don't use private S-Lang functions if they are * slint.c: Don't use private S-Lang functions if they are

View File

@ -422,22 +422,24 @@ init_key_x11 (void)
/* This has to be called before slang_init or whatever routine /* This has to be called before slang_init or whatever routine
calls any define_sequence */ calls any define_sequence */
void init_key (void) void
init_key (void)
{ {
const char *term = getenv ("TERM"); const char *term = getenv ("TERM");
/* This has to be the first define_sequence */ /* This has to be the first define_sequence */
/* So, we can assume that the first keys member has ESC */ /* So, we can assume that the first keys member has ESC */
define_sequences (mc_default_keys); define_sequences (mc_default_keys);
/* Terminfo on irix does not have some keys */ /* Terminfo on irix does not have some keys */
if (term && if (term
((!strncmp (term, "iris-ansi", 9)) || (!strncmp (term, "xterm", 5)))) && (!strncmp (term, "iris-ansi", 9) || !strncmp (term, "xterm", 5)
|| !strncmp (term, "rxvt", 4)))
define_sequences (xterm_key_defines); define_sequences (xterm_key_defines);
/* load some additional keys (e.g. direct Alt-? support) */ /* load some additional keys (e.g. direct Alt-? support) */
load_xtra_key_defines(); load_xtra_key_defines ();
#ifdef __QNX__ #ifdef __QNX__
if (term && strncmp (term, "qnx", 3) == 0) { if (term && strncmp (term, "qnx", 3) == 0) {
/* Modify the default value of use_8th_bit_as_meta: we would /* Modify the default value of use_8th_bit_as_meta: we would
@ -455,17 +457,16 @@ void init_key (void)
*/ */
use_8th_bit_as_meta = 0; use_8th_bit_as_meta = 0;
} }
#endif /* __QNX__ */ #endif /* __QNX__ */
#ifdef HAVE_TEXTMODE_X11_SUPPORT #ifdef HAVE_TEXTMODE_X11_SUPPORT
init_key_x11 (); init_key_x11 ();
#endif /* HAVE_TEXTMODE_X11_SUPPORT */ #endif /* HAVE_TEXTMODE_X11_SUPPORT */
/* Load the qansi-m key definitions /* Load the qansi-m key definitions
if we are running under the qansi-m terminal */ if we are running under the qansi-m terminal */
if ((term) && (strncmp (term, "qansi-m", 7) == 0)) if ((term) && (strncmp (term, "qansi-m", 7) == 0)) {
{ define_sequences (qansi_key_defines);
define_sequences(qansi_key_defines);
} }
} }