is resized multiple times during one event loop, it is forced to resize
at the end. Also don't zoom/unzoom in switch-client if the pane hasn't
changed. GitHub issue 2260.
mode client gets too far behind. The pause-after flag with a time is set
on the pane with refresh-client -f and a paused pane may be resumed with
refresh-client -A. GitHub issue 2217.
add a limit of how much data will be sent to the client and try to use
it for panes with some degree of fairness. GitHub issue 2217, with
George Nachman.
that 14 bytes are wasted for each character in the BMP, only store
characters of three bytes or less in the cell itself and store others
(outside the BMP or with combining characters) in a separate global
tree. Can reduce grid memory use for heavy Unicode users by around 30%.
separate offsets (used and acknowleged) into the pane buffers; turn off
reading from panes when no clients can accept the data; and add a -A
flag to refresh-client to let clients turn receiving a pane on and off.
resizing the window unless it is the current window, and if we do and
don't resize the pane until later there are problems if the size changes
from A to B then back to A.
lines (ACS or UTF-8), double or heavy (UTF-8), simple (plain ASCII) or
number (the pane numbers). Lines that won't work on a non-UTF-8 terminal
are translated back into ACS when they are output.
client and allows it to be changed independently from the real active
pane stored in the window. This is can be used with session groups which
allow an independent current window (although it would be nice to have a
flag for this too and remove session groups). The client active pane is
only really useful interactively, many things (hooks, window-style,
zooming) still use the window active pane.
client, use the same mechanism for the read-only flag and add an
ignore-size flag.
refresh-client -F has become -f (-F stays for backwards compatibility)
and attach-session and switch-client now have -f flags also. A new
format "client_flags" lists the flags and is shown by list-clients by
default.
This separates the read-only flag from "ignore size" behaviour (new
ignore-size) flag - both behaviours are useful in different
circumstances.
attach -r and switchc -r remain and set or toggle both flags together.
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.
- Add styles for the search marking styles (copy-mode-match-style and
copy-mode-current-match-style).
- Show the current match (the one with the cursor on it) in a different style.
- Copying without a selection will copy the current match if there is one.
- Show a menu with completions if there are multiple.
- Don't complete argument stuff (options, layouts) at start of text.
- For -t and -s, if there is no : then complete sessions but if there is
a :, show a menu of all windows in the session rather than trying to
complete the window name which is a bit useless if there are
duplicates.
which allows formats to be expanded. Any styles without a '#{' are still
validated when they are set but any with a '#{' are not. Formats are not
expanded usefully in many cases yet, that will be changed later.
To make this work, a few other changes:
- set-option -a with a style option automatically appends a ",".
- OSC 10 and 11 don't set the window-style option anymore, instead the
fg and bg are stored in the pane struct and act as the defaults that
can be overridden by window-style.
- status-fg and -bg now override status-style instead of trying to keep
them in sync.
window unless it is the current window, and if we do and don't resize the pane
until later there are problems if the size changes from A to B then back to A.
use these key sequences by default. Merge the code into the main tty and input
tree processing (convering the latter to use a tree rather than a table at the
same time) and make the option a no-op.
(ACS or UTF-8), double or heavy (UTF-8), simple (plain ASCII) or number (the
pane numbers). Lines that won't work on a non-UTF-8 terminal are translated
back into ACS when they are output.
allows it to be changed independently from the real active pane stored in the
window. This is can be used with session groups which allow an independent
current window (although it would be nice to have a flag for this too and
remove session groups). The client active pane is only really useful
interactively, many things (hooks, window-style, zooming) still use the window
active pane.
the same mechanism for the read-only flag and add an ignore-size flag.
refresh-client -F has become -f (-F stays for backwards compatibility) and
attach-session and switch-client now have -f flags also. A new format
"client_flags" lists the flags and is shown by list-clients by default.
This separates the read-only flag from "ignore size" behaviour (new
ignore-size) flag - both behaviours are useful in different circumstances.
attach -r and switchc -r remain and set or toggle both flags together.
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in the same
way as panes do, rather than forcing a full redraw on every change.
- Add styles for the search marking styles (copy-mode-match-style and
copy-mode-current-match-style).
- Show the current match (the one with the cursor on it) in a different style.
- Copying without a selection will copy the current match if there is one.
- Show a menu with completions if there are multiple.
- Don't complete argument stuff (options, layouts) at start of text.
- For -t and -s, if there is no : then complete sessions but if there is a :,
show a menu of all windows in the session rather than trying to complete the
window name which is a bit useless if there are duplicates.
Lots of scope for being more sophisticated left here.
allows formats to be expanded. Any styles without a '#{' are still validated
when they are set but any with a '#{' are not. Formats are not expanded
usefully in many cases yet, that will be changed later.
To make this work, a few other changes:
- set-option -a with a style option automatically appends a ",".
- OSC 10 and 11 don't set the window-style option anymore, instead the fg and
bg are stored in the pane struct and act as the defaults that can be
overridden by window-style.
- status-fg and -bg now override status-style instead of trying to keep them in
sync.
added and using that as a marker for xterm(1)-like, assume that if the
terminfo(5) entry already has XT or the clear capability starts with CSI then
the terminal is VT100-like and it should be safe to send DA requests. The DA
responses trigger additional features being added.
This is all to detect extensions if terminfo(5) is wrong or inadequate. If it
fails, tmux will just fall back to using the capabilities in the terminfo(5)
entry alone.
terminal features, each of which are defined in one place and map to a
builtin set of terminfo(5) capabilities. Features can be specified based
on TERM with a new terminal-features option or with the -T flag when
running tmux. tmux will also detect a few common terminals from the DA
and DSR responses.
This is intended to make it easier to configure tmux's use of
terminfo(5) even in the presence of outdated ncurses(3) or terminfo(5)
databases or for features which do not yet have a terminfo(5) entry.
Instead of having to grok terminfo(5) capability names and what they
should be set to in the terminal-overrides option, the user can
hopefully just give tmux a feature name and let it do the right thing.
The terminal-overrides option remains both for backwards compatibility
and to allow tweaks of individual capabilities.
tmux already did much of this already, this makes it tidier and simpler
to configure.
clear it on the first redraw, and it can't be set when we are finished
or they would be redrawn again, so if the redraw is deferred for a
client, copy the redraw flag into a separate set of bits just for that
client.
the data from the last one, other panes could update while waiting, so
we set the flag to redraw them all when the new redraw actually
happened. But this means a lot of redrawing panes unnecessarily if they
haven't changed - so instead set a flag to say "at least one pane needs
to be redrawed" then look at the invidual pane flags to see which ones
need it.
created, resize it and let the resize/reflow code fix it up and return
it. Solves various problems with cursor position and resizing when in
copy mode. With Anindya Mukherjee.
newlines. This means that for example bind q { a \n b } and bind q "a ;
b" are the same. Also log commands in different groups separated by ;;
rather than ; (a command list like this should never be user visible).
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).
reference to it, it isn't necessary that the pane in copy mode is the
same as the one copying from. Add a -s flag to copy-mode to specify a
different pane for the source content. This means it is possible to view
two places in a pane's history at the same time in different panes, or
copy from a pane's history into an editor or shell in the same pane.
From Anindya Mukherjee.
attributes request and other bits that prompt a reply from the terminal.
This means that stray relies are not left on the terminal if the command
has attached and then immediately detached and tmux will not be around
to receive them. Prompted by a problem report from espie@.
freeze updates (which does not play nicely with some applications, a
longstanding problem) and will allow some other changes later. From
Anindya Mukherjee.
double click, even if the timer hasn't expired to confirm it isn't
actually a triple click. Provides a way for people who don't care about
triple clicks or can make their commands have no side effects to avoid
the double click timer delay.
umask 177 instead of 117 because it may not be in a safe directory like
the default directory in /tmp. The user can chmod it more open after it
is created if they want.
use this to add descriptions to the default key bindings. A new -N flag
to list-keys shows key bindings with notes rather than the default
bind-key command used to create them. Change the default ? binding to
use this to show a readable summary of keys.
Also extend command-prompt to return the name of the key pressed and add
a default binding (/) to show the note for the next key pressed
Suggested by Alex Tremblay in GitHub issue 2000.
confused with mouse sequences. Also set a flag and don't bother checking
for it if we have already seen it (same for DA), and don't check if we
never asked for it.
ends up pointing to the wrong place before it is passed to the client.
The path is only used internally so there is no real need for
realpath(), remove it and move the get_path function to file.c where all
the callers are.
not attached, the server process asks it to open the file, similar to
how works for stdin, stdout, stderr. This makes special files like
/dev/fd/X work (used by some shells). stdin, stdout and stderr and
control mode are now just special cases of the same mechanism. This will
also make it easier to use for other commands that read files such as
source-file.
and attributes and use them to restore the previous behaviour of
window-status-style being the default for window-status-format in the
status line. From John Drouhard in GitHub issue 1912.
was output in the pane faster than the timer would fire, so change how
it works to only defer the timer again if the pane was actually resized
within the last timer period. Reported by James Tai in GitHub issue
1880.
(needed for control clients to send mouse sequences). Also add some
format flags for UTF-8 and SGR mouse mode. Requested by Bradley Smith in
GitHub issues 1832 and 1833.
there should be no change to existing behaviour) and are set and shown
with set-option -p and show-options -p.
Change remain-on-exit and window-style/window-active-style to be pane
options (some others will be changed later).
This makes select-pane -P and -g unnecessary so no longer document them
(they still work) and no longer document set-window-option and
show-window-options in favour of set-option -w and show-options -w.
to start, otherwise commands like lsk which start the server again can
end up looping infinitely. Also make the first client exit
correctly. Problem reported by Wael M Nasreddine.