Two new features in feature.h: CTRL_TAB_MAKES_META, MOD4_TAB_MAKES_META).
When enabled, Ctrl+Tab and/or Mod4+Tab emit "\e\t" (which is used for
filename completion in mc and history completion in bash).

Useful when the window manager grabs Alt+Tab.  Mod4 is mapped to the
Win9x (aka Penguin) keys on 104/105-key keyboards.  Ctrl is useful for
101/102-key keyboards (and older notebooks).

Marius Gedminas
-- 
The memory management on the PowerPC can be used to frighten small children.
                -- Linus Torvalds
Index: src/feature.h
===================================================================
RCS file: /cvsroot/rxvt/rxvt/src/feature.h,v
retrieving revision 1.52
diff -u -r1.52 feature.h
--- src/feature.h       2001/03/02 05:33:15     1.52
+++ src/feature.h       2001/03/06 12:54:18
@@ -210,6 +218,19 @@
  */
 #define PAGING_CONTEXT_LINES 1 /* */
 
+/*
+ * Ctrl+Tab emits \e\t (Useful when window manager grabs Alt+Tab)
+ *                                             -- mg
+ */
+/* #define CTRL_TAB_MAKES_META */
+
+/*
+ * Mod4+Tab emits \e\t (Useful when window manager grabs Alt+Tab, and you
+ * map one of Win95 keys to Mod4)
+ *                                             -- mg
+ */
+/* #define MOD4_TAB_MAKES_META */
+
 /*--------------------------------MOUSE---------------------------------*/
 /*
  * Disable sending escape sequences (up, down, page up/down)
Index: src/command.c
===================================================================
RCS file: /cvsroot/rxvt/rxvt/src/command.c,v
retrieving revision 1.202
diff -u -r1.202 command.c
--- src/command.c       2001/03/01 05:07:03     1.202
+++ src/command.c       2001/03/06 12:54:17
@@ -25,6 +25,8 @@
  * Copyright (C) 1998,1999,2000        Geoff Wing <[EMAIL PROTECTED]>
  *                             - extensive modifications
  * Copyright (C) 1998      Alfredo K. Kojima <[EMAIL PROTECTED]>
+ * Copyright (C) 2001      Marius Gedminas
+ *                             - Ctrl/Mod4+Tab works like Meta+Tab (options)
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -267,8 +302,17 @@
                case XK_Tab:
                    if (shft)
                        STRCPY(kbuf, "\033[Z");
-                   else
+                   else {
+#ifdef CTRL_TAB_MAKES_META
+                       if (ctrl)
+                           meta = 1;
+#endif
+#ifdef MOD4_TAB_MAKES_META
+                       if (ev->xkey.state & Mod4Mask)
+                           meta = 1;
+#endif
                        newlen = 0;
+                   }
                    break;
 
 

Reply via email to