tmuxはctrl-shift-矢印シーケンスを正しく渡しません

tmuxはctrl-shift-矢印シーケンスを正しく渡しません

Tmuxはctrl-shift-矢印シーケンスを正しく渡しません。 Emacsでは動作しません。使用時に、sed -n lシーケンス全体ではなく矢印キーのエスケープシーケンスのみが表示されることを確認しました。

たとえば、ctrl-shift-rightは(tmuxの外側)^[[Cではなく(右側のキーと同じエスケープシーケンス)として渡されます^[OC

この問題を解決する方法を知っていますか? Ctrl - 矢印キー(Shiftなし)とShift -矢印キー(Ctrlなし)は正しく渡されます。

私の.tmux.confは次のようになります。

# Changes prefix from Ctrl-b to Alt-a
unbind C-b
set -g prefix M-a

set-option -g default-terminal "xterm-256color"




# choosing windows with Alt-#
bind -n M-0 select-window -t 0
bind -n M-1 select-window -t 1
bind -n M-2 select-window -t 2
bind -n M-3 select-window -t 3
bind -n M-4 select-window -t 4
bind -n M-5 select-window -t 5
bind -n M-6 select-window -t 6
bind -n M-7 select-window -t 7
bind -n M-8 select-window -t 8
bind -n M-9 select-window -t 9


setw -g monitor-activity on
set -g visual-activity on

set-window-option -g window-status-current-bg white

set -g mode-mouse on
set -g mouse-resize-pane on
set -g mouse-select-pane on
set -g mouse-select-window on


# Toggle mouse on
bind m \
    set -g mode-mouse on \;\
    set -g mouse-resize-pane on \;\
    set -g mouse-select-pane on \;\
    set -g mouse-select-window on \;\
    display 'Mouse: ON'

# Toggle mouse off
bind M \
    set -g mode-mouse off \;\
    set -g mouse-resize-pane off \;\
    set -g mouse-select-pane off \;\
    set -g mouse-select-window off \;\
    display 'Mouse: OFF'

# disable selecting panes with mouse (because enabling mess with copy-paste)
set-option -g mouse-select-pane off


# display status bar message for 4 sec
set-option -g display-time 4000


# Start windows and panes at 1, not 0
set -g base-index 1
set -g pane-base-index 1


# enable shift-arrow keys
set-window-option -g xterm-keys on

# start default shell
set-option -g default-shell $SHELL

# support for escape char for vi
set -s escape-time 0

ベストアンサー1

tmuxあなたの例に合ったもののようです。

たとえば、ctrl-shift-rightは(tmuxの外側)^[[Cではなく(右側のキーと同じエスケープシーケンス)として渡されます^[OC

このシーケンスの一般的な意味は、ホストから送信されたカーソルの移動と同じです。 ㅏ若いパラメーターが欠落しているパラメーターと同じです。一つ

端末が認識されません。xtermこれをしないでください。の場合をcontrolshiftright-arrow送信xtermできます^[[1;6C。この場合、tmux送信されたエスケープシーケンスは、認識されている既知のxtermスタイルのキーテーブルにないために吸収されます。のtmuxファイルには、xterm-keys.c説明を含むテーブルが含まれています。

/*                                                     
 * xterm-style function keys append one of the following values before the last
 * character:
 *
 * 2 Shift
 * 3 Alt
 * 4 Shift + Alt                               
 * 5 Ctrl
 * 6 Shift + Ctrl
 * 7 Alt + Ctrl
 * 8 Shift + Alt + Ctrl
 *
 * Rather than parsing them, just match against a table.
 *
 * There are three forms for F1-F4 (\\033O_P and \\033O1;_P and \\033[1;_P).
 * We accept any but always output the latter (it comes first in the table).
 */

おすすめ記事