From 4c20c7e896e97f8af6a468bc16ff2b38e0e54be4 Mon Sep 17 00:00:00 2001 From: ndwarshuis Date: Tue, 29 Jun 2021 13:23:25 -0400 Subject: [PATCH] ENH remove extended keys (they do weird things) --- dot_config/X11/xresources | 12 ++++-------- dot_config/tmux/tmux.conf.tmpl | 12 ++++-------- 2 files changed, 8 insertions(+), 16 deletions(-) diff --git a/dot_config/X11/xresources b/dot_config/X11/xresources index 9121a20..c102933 100644 --- a/dot_config/X11/xresources +++ b/dot_config/X11/xresources @@ -84,11 +84,7 @@ URxvt.keysym.Control-B: perl:clipboard:paste_escaped ! URxvt.keysym.Control-Shift-R: perl:tabbedex:rename_tab ! URxvt.tabbed.no-tabbedex-keys: true -! WARNING: this is a giant hack to enable extended keys support (like xterm has). -! See here: http://www.leonerd.org.uk/hacks/fixterms/ -! The main reason for this is that I really really wanted to use C-Tab in tmux -! but also did not want to use xterm since urxvt is lighter and awesome-r -URxvt.keysym.C-Tab: \033[27;5;9~ -! make shift-tab send M-F12 since I there appears to not be anything for this -! even in extended keys from xterm -URxvt.keysym.C-ISO_Left_Tab: \033\033[24~ +! because C-Tab does not actually exist in terminals, bind them to something +! random that I can use in tmux (in this case M-F11 and M-F12) +URxvt.keysym.C-Tab: \033\033[24~ +URxvt.keysym.C-ISO_Left_Tab: \033\033[23~ diff --git a/dot_config/tmux/tmux.conf.tmpl b/dot_config/tmux/tmux.conf.tmpl index 15fb171..6c40016 100644 --- a/dot_config/tmux/tmux.conf.tmpl +++ b/dot_config/tmux/tmux.conf.tmpl @@ -2,10 +2,6 @@ set -g status-keys vi set -g mode-keys vi -# enable extended keys -set -s extended-keys on -set -as terminal-features 'xterm*:extkeys' - # change prefix unbind C-b set -g prefix C-f @@ -30,10 +26,10 @@ bind - split-window -v bind | split-window -h # window navigation -bind -n C-Tab next-window -bind -n M-F12 previous-window # use this since BTab = S-Esc (even in extended keys) -bind C-Tab swap-window -t +1 \; next-window -bind M-F12 swap-window -t -1 \; previous-window +bind -n M-F12 next-window # use this since C-Tab doesn't exist in most terminals +bind -n M-F11 previous-window # use this since BTab = S-Esc +bind M-F12 swap-window -t +1 \; next-window +bind M-F11 swap-window -t -1 \; previous-window bind -n M-| choose-window "join-pane -h -t '%%'" bind -n M-- choose-window "join-pane -v -t '%%'"