Backspace doesn't work in filename search (C-s) in xterm

Pavel Roskin proski at gnu.org
Fri Mar 7 22:05:29 UTC 2003


Hello!

> Also M-Backspace works now as simple Backspace in command line in xterm
>   instead of previous word deleting as before.

It works for me on the command line in all 4 terminals (xterm, rxvt,
Konsole, gnome-terminal) on Red Hat 8.0.  I'm using Alt-Backspace.
XFree86 4.2.0.  Keyboard configuration:

        Option  "XkbOptions"    "grp:caps_toggle"
        Option  "XkbRules"      "xfree86"
        Option  "XkbModel"      "pc105"
        Option  "XkbLayout"     "ru"

> Well, these shortcuts were working in xterm before, and they work fine
> in the linux console now.

OK, I think I know.  Try this patch:

===========================
--- widget.c
+++ widget.c
@@ -1420,7 +1420,7 @@ static const struct {
     { XCTRL('d'),         delete_char },
     { ALT('d'),           kill_word },
     { ALT(KEY_BACKSPACE), back_kill_word },
-    { ALT(XCTRL('h')),    back_kill_word },
+    { KEY_M_ALT | ('h' & 31),    back_kill_word },
     { ALT(127),           back_kill_word },

     /* Region manipulation */
===========================

> P.S. There is working delete_word_left in the built-in editor, but I
> cannot find how to define M-Backspace in editkeys.c.

I've applied a patch (too early, before I realized what your problem is)
and it works for me.  You may need to add

KEY_M_ALT | ('h' & 31)

to the table.  We need to find a better way to detect backspace.

-- 
Regards,
Pavel Roskin



More information about the mc-devel mailing list