diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2017-06-09 15:57:13 +0100 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2017-06-09 15:57:13 +0100 |
commit | 411640c0327525f2e5e6d61bd81623ce64d0d811 (patch) | |
tree | 4db1efa532e87664cd9e749c7173ef01fec9033e | |
parent | eea93638c6885e45c8e103acf882f1c58b550a95 (diff) | |
parent | e640907d2416b3112f428852aeeff9c9648790a9 (diff) |
Merge branch 'master' of github.com:tmux/tmux
-rw-r--r-- | input.c | 1 | ||||
-rw-r--r-- | tmux.1 | 14 | ||||
-rw-r--r-- | window-copy.c | 2 |
3 files changed, 13 insertions, 4 deletions
@@ -2174,6 +2174,7 @@ input_osc_52(struct window_pane *wp, const char *p) screen_write_start(&ctx, wp, NULL); screen_write_setselection(&ctx, out, outlen); screen_write_stop(&ctx); + notify_pane("pane-set-clipboard", wp); paste_add(out, outlen); } @@ -2424,13 +2424,15 @@ The default is 100. .Op Ic on | external | off .Xc Attempt to set the terminal clipboard content using the -\ee]52;...\e007 .Xr xterm 1 -escape sequences, if there is an +escape sequence, if there is an .Em \&Ms entry in the .Xr terminfo 5 -description. +description (see the +.Sx TERMINFO EXTENSIONS +section). +.Pp If set to .Ic on , .Nm @@ -3234,7 +3236,7 @@ set-hook after-split-window "selectl even-vertical" .Ed .Pp In addition, the following hooks are available: -.Bl -tag -width "XXXXXXXXXXXXXXXX" +.Bl -tag -width "XXXXXXXXXXXXXXXXXXXXXX" .It alert-activity Run when a window has activity. See @@ -3259,6 +3261,10 @@ Run when the program running in a pane exits, but is on so the pane has not closed. .It pane-exited Run when the program running in a pane exits. +.It pane-set-clipboard +Run when the terminal clipboard is set using the +.Xr xterm 1 +escape sequence. .It session-created Run when a new session created. .It session-closed diff --git a/window-copy.c b/window-copy.c index 31826861..3ad6084f 100644 --- a/window-copy.c +++ b/window-copy.c @@ -1633,6 +1633,7 @@ window_copy_copy_buffer(struct window_pane *wp, const char *bufname, void *buf, screen_write_start(&ctx, wp, NULL); screen_write_setselection(&ctx, buf, len); screen_write_stop(&ctx); + notify_pane("pane-set-clipboard", wp); } if (paste_set(buf, len, bufname, NULL) != 0) @@ -1690,6 +1691,7 @@ window_copy_append_selection(struct window_pane *wp, const char *bufname) screen_write_start(&ctx, wp, NULL); screen_write_setselection(&ctx, buf, len); screen_write_stop(&ctx); + notify_pane("pane-set-clipboard", wp); } if (bufname == NULL || *bufname == '\0') |