mirror of
https://github.com/tmux/tmux.git
synced 2025-09-03 22:43:58 +00:00
Add a mark in copy mode. Set with set-mark command (bound to 'X') by
default and the mark and cursor position are swapped with 'jump-to-mark' (bound to M-x). The line containing the mark is shown in copy-mode-mark-style with the horizontal position in reverse. From Anindya Mukherjee in GitHub issue 2209.
This commit is contained in:
@ -426,6 +426,7 @@ key_bindings_init(void)
|
||||
"bind -Tcopy-mode N send -X search-reverse",
|
||||
"bind -Tcopy-mode R send -X rectangle-toggle",
|
||||
"bind -Tcopy-mode T command-prompt -1p'(jump to backward)' 'send -X jump-to-backward \"%%%\"'",
|
||||
"bind -Tcopy-mode X send -X set-mark",
|
||||
"bind -Tcopy-mode f command-prompt -1p'(jump forward)' 'send -X jump-forward \"%%%\"'",
|
||||
"bind -Tcopy-mode g command-prompt -p'(goto line)' 'send -X goto-line \"%%%\"'",
|
||||
"bind -Tcopy-mode n send -X search-again",
|
||||
@ -467,6 +468,7 @@ key_bindings_init(void)
|
||||
"bind -Tcopy-mode M-r send -X middle-line",
|
||||
"bind -Tcopy-mode M-v send -X page-up",
|
||||
"bind -Tcopy-mode M-w send -X copy-pipe-and-cancel",
|
||||
"bind -Tcopy-mode M-x send -X jump-to-mark",
|
||||
"bind -Tcopy-mode 'M-{' send -X previous-paragraph",
|
||||
"bind -Tcopy-mode 'M-}' send -X next-paragraph",
|
||||
"bind -Tcopy-mode M-Up send -X halfpage-up",
|
||||
@ -521,6 +523,7 @@ key_bindings_init(void)
|
||||
"bind -Tcopy-mode-vi T command-prompt -1p'(jump to backward)' 'send -X jump-to-backward \"%%%\"'",
|
||||
"bind -Tcopy-mode-vi V send -X select-line",
|
||||
"bind -Tcopy-mode-vi W send -X next-space",
|
||||
"bind -Tcopy-mode-vi X send -X set-mark",
|
||||
"bind -Tcopy-mode-vi ^ send -X back-to-indentation",
|
||||
"bind -Tcopy-mode-vi b send -X previous-word",
|
||||
"bind -Tcopy-mode-vi e send -X next-word-end",
|
||||
@ -554,6 +557,7 @@ key_bindings_init(void)
|
||||
"bind -Tcopy-mode-vi Down send -X cursor-down",
|
||||
"bind -Tcopy-mode-vi Left send -X cursor-left",
|
||||
"bind -Tcopy-mode-vi Right send -X cursor-right",
|
||||
"bind -Tcopy-mode-vi M-x send -X jump-to-mark",
|
||||
"bind -Tcopy-mode-vi C-Up send -X scroll-up",
|
||||
"bind -Tcopy-mode-vi C-Down send -X scroll-down",
|
||||
};
|
||||
|
Reference in New Issue
Block a user