Nicholas Marriott
6fee3e9e4b
Rename session idx to session id throughout and add $ prefix to targets
...
to use it, extended from a diff from George Nachman.
2013-03-25 10:11:45 +00:00
Nicholas Marriott
410a3abbef
Add a wait-for command which blocks a client on a named channel until it
...
is woken up again (with wait-for -S). From Thiago Padilha.
2013-03-25 10:09:05 +00:00
Nicholas Marriott
14fad6a5cc
Add -A flag to new-session to make it behave like attach-session if the
...
session exists. If -A is used, -D behaves like -d to attach-session.
2013-03-24 09:58:40 +00:00
Nicholas Marriott
20636d956d
Add a command queue to standardize and simplify commands that call other
...
commands and allow a command to block execution of subsequent
commands. This allows run-shell and if-shell to be synchronous which has
been much requested.
Each client has a default command queue and commands are consumed one at
a time from it. A command may suspend execution from the queue by
returning CMD_RETURN_WAIT and then resume it by calling cmd_continue() -
for example run-shell does this from the callback that is fired after
the job is freed.
When the command queue becomes empty, command clients are automatically
exited (unless attaching). A callback is also fired - this is used for
nested commands in, for example, if-shell which can block execution of
the client's cmdq until a new cmdq becomes empty.
Also merge all the old error/info/print functions together and lose the
old curclient/cmdclient distinction - a cmdq is bound to one client (or
none if in the configuration file), this is a command client if
c->session is NULL otherwise an attached client.
2013-03-24 09:54:10 +00:00
Nicholas Marriott
a60687f9ba
Handle focus events from the terminal, from Aaron Jensen.
2013-03-24 09:28:59 +00:00
Nicholas Marriott
eaaeb28cda
Add session_set_current helper function, extracted from a diff from
...
Aaron Jensen.
2013-03-22 16:00:26 +00:00
Nicholas Marriott
8478895eeb
Add -e flag to capture-pane to include embedded ANSI SGR escape
...
sequences, from George Nachman.
2013-03-22 15:51:54 +00:00
Nicholas Marriott
db66d85176
Fix double space in sessions template.
2013-03-22 10:38:13 +00:00
Nicholas Marriott
f0efa576e0
Add resize-pane -x and -y for absolute pane size (much requested).
2013-03-22 10:37:39 +00:00
Nicholas Marriott
67b4d5b609
Support the latest theory for mouse input, this is enabled/disabled with
...
SM/RM 1006 and is similar in style to SGR input: \033[<b;x;yM or
\033[b;x;ym. From Egmont Koblinger.
2013-03-22 10:33:50 +00:00
Nicholas Marriott
10682b9e7e
Instead of loads of little screen_write_*_on and off functions which
...
just change mode flags, just have screen_write_mode_set and
screen_write_mode_clear.
2013-03-21 18:47:56 +00:00
Nicholas Marriott
3665be7c44
Tidy by splitting default key tables into two.
2013-03-21 16:50:22 +00:00
Nicholas Marriott
c982279950
Fix constness of cmd_template_replace, window_choose_add_item and
...
window_choose_add_window.
2013-03-21 16:19:25 +00:00
Nicholas Marriott
180faf73af
Allow choose commands to be used outside tmux, so long as at least one
...
client is attached.
2013-03-21 16:09:59 +00:00
Nicholas Marriott
8903c1f167
Automatically reflow wrapped lines when a pane is resized, requested by
...
many over the years and finally implemented by Richard Woodbury.
2013-02-05 11:08:59 +00:00
Nicholas Marriott
fdbfc7e349
Rather than having two grids for each pane, one for ASCII and one for
...
UTF-8, collapse the two together. Simplifies the code at the expense of
more memory (which can probably be reduced again later).
2013-01-18 02:16:21 +00:00
Nicholas Marriott
e33ba57c13
Remove the layout undo/redo code which never really worked.
2013-01-17 00:11:22 +00:00
Nicholas Marriott
44f8e1caff
Implement ECH (erase character, CSI X). Reported by Christian Neukirchen.
2013-01-15 23:18:55 +00:00
Nicholas Marriott
bc2e4a36df
If timing between keys is less than (by default) 1 millisecond, assume
...
the text is being pasted. assume-paste-time option changes the value (0
disables). Based on a diff from Marcin Kulik.
2013-01-15 22:55:29 +00:00
Nicholas Marriott
a2c8af97e9
Add missing function prototype.
2012-12-24 12:33:05 +00:00
Nicholas Marriott
8264e92b37
Fix return value of load_cfg, from Thomas Adam.
2012-11-27 22:59:34 +00:00
Nicholas Marriott
47c097cb51
Support middle-click paste, based on a diff from Ailin Nemui.
2012-11-27 20:22:12 +00:00
Nicholas Marriott
24d7d073ff
Support the 47 and 1047 SM and RM sequences (alternate screen without
...
cursor), requested by I forget who ages ago.
2012-11-27 20:08:42 +00:00
Nicholas Marriott
9b8998aeec
Correctly aggregate together errors from nested config files (with
...
source-file). Fix by Thomas Adam, reported by Sam Livingstone-Gray
2012-11-27 16:12:29 +00:00
Nicholas Marriott
260419f48e
Put helper function back, will be needed in a bit.
2012-11-22 14:41:11 +00:00
Nicholas Marriott
827b311c81
Use a utility function for common code to show errors in config file,
...
from Thomas Adam.
2012-11-19 10:38:06 +00:00
Nicholas Marriott
c68efec6c0
Show last client activity time in default choose-client list.
2012-11-05 13:13:04 +00:00
Nicholas Marriott
d210d99cce
Make mouse event structure clearer by defining events (up, click, drag)
...
and simplifying how buttons and wheels are represented, from Ailin
Nemui. Should be no functional changes.
2012-10-26 14:35:42 +00:00
Nicholas Marriott
9107b0c69a
Allow session tree (C-b s) to expand and collapse sessions with
...
left/right/space keys. From Thomas Adam.
2012-10-02 08:16:28 +00:00
Nicholas Marriott
17bbf90393
Add notification for input from a pane, from George Nachman.
2012-09-25 07:41:22 +00:00
Nicholas Marriott
84612a8196
Add control_write_buffer, from George Nachman.
2012-09-24 13:39:10 +00:00
Nicholas Marriott
42272dfbd5
Use pgrp of pty fd not pid of immediate child when recovering current
...
working directory (like current process). From Marcel Partap.
2012-09-24 13:05:10 +00:00
Nicholas Marriott
9e7bbc7281
When choosing a pane found by find-window, switch to that pane rather
...
than just the window. Also use a helper function for the inner loop.
2012-09-03 12:20:17 +00:00
Nicholas Marriott
7263fa36eb
add cmd-choose-list to allow arbitrary options to be selected. From
...
Thomas Adam.
2012-09-03 09:57:57 +00:00
Nicholas Marriott
9247c90d69
Send notifications to control clients. Also don't redraw client when
...
suspended.
2012-09-03 09:32:38 +00:00
Nicholas Marriott
58e8e0eac8
Fix up window reference counting and don't crash if the rename timer
...
fires while the window is dead but still referenced. Fixes problem
reported by Michael Scholz.
2012-08-21 10:00:33 +00:00
Nicholas Marriott
73c6785538
Use a separate define for each default format template and strip clutter
...
from the choose-tree defaults.
2012-08-14 08:51:53 +00:00
Nicholas Marriott
a3dec6bece
Instead of numbering choose mode items 0-9a-z and then nothing, number
...
them all and if there are more than 10 use a prompt when 0-9 is
pressed. From Thomas Adam.
2012-08-11 06:45:33 +00:00
Nicholas Marriott
5385a9bb34
Add a queue of notifys and a way to turn them off and on (we do not want
...
notifys to happen during some commands). Based on code from George
Nachman.
2012-07-13 06:27:41 +00:00
Nicholas Marriott
ede8312d59
Make command exec functions return an enum rather than -1/0/1 values and
...
add a new value to mean "leave client running but don't attach" to fix
problems with using some commands in a command sequence. Most of the
work by Thomas Adam, problem reported by "jspenguin" on SF bug 3535531.
2012-07-11 07:10:15 +00:00
Nicholas Marriott
df912e3540
xfree is not particularly helpful, remove it. From Thomas Adam.
2012-07-10 11:53:01 +00:00
Nicholas Marriott
f20c6fe009
Add choose-tree command to show windows and sessions in the same
...
list. Change choose-window and -session to use the same code. From
Thomas Adam.
2012-07-08 16:04:38 +00:00
Nicholas Marriott
63f5c38023
Clear flags across all sessions, from Thomas Adam.
2012-07-08 07:27:32 +00:00
Nicholas Marriott
67b926cf3c
Provide common helper function for adding windows and sessions to choose
...
lists and expand %% in command before using it rather than at callback
time. From Thomas Adam.
2012-06-25 14:27:25 +00:00
Nicholas Marriott
5b6f78186c
Clean up and simplify the choose mode code, from Thomas Adam.
2012-06-25 14:08:55 +00:00
Nicholas Marriott
2942eca895
Add a skeleton mode to tmux (called "control mode") that let's tmux
...
commands be sent and output received on stdout. This can be used to
integrate with other terminal emulators and should allow some other
things to be made simpler later. More to come so doesn't do much yet and
deliberately not documented.
2012-06-18 13:16:42 +00:00
Nicholas Marriott
1845800651
Strip layout from choose-windows again (leave in list-windows),
...
suggested by Romain Francoise, diff from Thomas Adam.
2012-05-28 07:59:07 +00:00
Nicholas Marriott
993f1b96a3
Fix client templates, from Romain Francoise.
2012-05-27 21:43:57 +00:00
Nicholas Marriott
196710e2d3
Simplify logging and just fprintf(stderr, ...) for early errors.
2012-05-25 08:28:10 +00:00
Nicholas Marriott
1f23f6d686
Use a predefined structure for not-space cells used to set attributes.
2012-05-23 19:19:40 +00:00