Ticket #1540: shell-keys.diff

File shell-keys.diff, 1.3 KB (added by axeld, 17 years ago)

Fix for the bash defaults

  • readline.c

     
    885885  _rl_keymap = xkeymap;
    886886}
    887887
     888/* Bind some default keys in the standard keymap. */
     889static void
     890bind_default_keys_internal ()
     891{
     892  _rl_bind_if_unbound ("\033[[", rl_end_of_line);
     893  _rl_bind_if_unbound ("\033[@", rl_beg_of_line);
     894  _rl_bind_if_unbound ("\033[5~", rl_history_search_backward);
     895  _rl_bind_if_unbound ("\033[6~", rl_history_search_forward);
     896}
     897
    888898/* Try and bind the common arrow key prefixes after giving termcap and
    889899   the inputrc file a chance to bind them and create `real' keymaps
    890900   for the arrow key prefix. */
    891901static void
    892902bind_arrow_keys ()
    893903{
     904  bind_default_keys_internal ();
    894905  bind_arrow_keys_internal (emacs_standard_keymap);
    895906
    896907#if defined (VI_MODE)
  • keymaps.c

     
    105105    newmap[i].function = rl_insert;
    106106
    107107  newmap[TAB].function = rl_insert;
    108   newmap[RUBOUT].function = rl_rubout;  /* RUBOUT == 127 */
     108  newmap[RUBOUT].function = rl_delete;  /* RUBOUT == 127 */
    109109  newmap[CTRL('H')].function = rl_rubout;
    110110
    111111#if KEYMAP_SIZE > 128