From 505a831341680b484a456c836c9f7be4001810c0 Mon Sep 17 00:00:00 2001 From: sf-exg Date: Wed, 6 Jan 2010 12:10:44 +0000 Subject: [PATCH] Add iso14755 option to disable ISO 14755 at runtime. --- Changes | 2 ++ doc/rxvt.1.pod | 4 ++++ src/command.C | 5 +++-- src/init.C | 1 + src/optinc.h | 2 ++ src/rsinc.h | 1 + src/xdefaults.C | 1 + 7 files changed, 14 insertions(+), 2 deletions(-) diff --git a/Changes b/Changes index e0f04e3..3c7f541 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,7 @@ rxvt-unicode changelog <= google-friendly title + - new iso14755 option to disable ISO 14755 at runtime (Emanuele Giaquinta). + 9.07 Wed Dec 30 07:07:18 CET 2009 - port to glibc-2.10 changes (strchr etc. returning const char * in C++), based on patches by Milos Jakubicek and Oliver Mader. diff --git a/doc/rxvt.1.pod b/doc/rxvt.1.pod index 871251e..81fd8dc 100644 --- a/doc/rxvt.1.pod +++ b/doc/rxvt.1.pod @@ -1298,6 +1298,10 @@ Compile I: Sets the WM_TRANSIENT_FOR property to the given window id. Compile I: Sets override-redirect for the terminal window, making it almost invisible to window managers; option B<-override-redirect>. +=item B I + +Turn on/off ISO 14755 (default enabled). + =item B I Turn on/off ISO 14755 5.2 mode (default enabled). diff --git a/src/command.C b/src/command.C index 84efe3b..e9c2a16 100644 --- a/src/command.C +++ b/src/command.C @@ -621,8 +621,9 @@ rxvt_term::key_press (XKeyEvent &ev) iso14755buf = 0; } } - else if ((ctrl && (keysym == XK_Shift_L || keysym == XK_Shift_R)) - || (shft && (keysym == XK_Control_L || keysym == XK_Control_R))) + else if (option (Opt_iso14755) && + ((ctrl && (keysym == XK_Shift_L || keysym == XK_Shift_R)) + || (shft && (keysym == XK_Control_L || keysym == XK_Control_R)))) if (!(iso14755buf & ISO_14755_STARTED)) { iso14755buf |= ISO_14755_STARTED; diff --git a/src/init.C b/src/init.C index a352236..9af7bae 100644 --- a/src/init.C +++ b/src/init.C @@ -310,6 +310,7 @@ rxvt_term::init_vars () set_option (Opt_secondaryScroll); set_option (Opt_pastableTabs); set_option (Opt_intensityStyles); + set_option (Opt_iso14755); set_option (Opt_iso14755_52); set_option (Opt_buffered); } diff --git a/src/optinc.h b/src/optinc.h index 4492d82..ee046cc 100644 --- a/src/optinc.h +++ b/src/optinc.h @@ -52,8 +52,10 @@ nodef(intensityStyles) #endif #if ISO_14755 + def(iso14755, 35) def(iso14755_52, 32) #else + nodef(iso14755) nodef(iso14755_52) #endif def(console, 33) diff --git a/src/rsinc.h b/src/rsinc.h index 0667bf8..fa56424 100644 --- a/src/rsinc.h +++ b/src/rsinc.h @@ -112,6 +112,7 @@ def (perl_lib) #endif #if ISO_14755 + def (iso14755) def (iso14755_52) #endif #ifdef HAVE_AFTERIMAGE diff --git a/src/xdefaults.C b/src/xdefaults.C index 4717dd4..7188498 100644 --- a/src/xdefaults.C +++ b/src/xdefaults.C @@ -260,6 +260,7 @@ optList[] = { STRG (Rs_perl_ext_2, "perl-ext", "pe", "string", "colon-separated list of perl extensions to enable for this instance"), #endif #if ISO_14755 + BOOL (Rs_iso14755, "iso14755", NULL, Opt_iso14755, 0, NULL), BOOL (Rs_iso14755_52, "iso14755_52", NULL, Opt_iso14755_52, 0, NULL), #endif #ifdef HAVE_AFTERIMAGE -- 1.9.1