aboutsummaryrefslogtreecommitdiff
path: root/server-client.c
Commit message (Collapse)AuthorAge
...
| * Function to count clients.nicm2017-05-29
| |
* | Merge branch 'obsd-master'Thomas Adam2017-05-16
|\|
| * Line length and spaces to tabs.nicm2017-05-16
| |
* | Merge branch 'obsd-master'Thomas Adam2017-05-10
|\|
| * Insert copy mode bindings at the right place in the command queue.nicm2017-05-10
| |
* | Merge branch 'obsd-master'Thomas Adam2017-05-09
|\|
| * If the current screen was complex enough, it was possible to make redrawnicm2017-05-09
| | | | | | | | | | | | itself hit the "terminal can't keep up" check. To avoid this, record how much data we send during redraw (we know we will be starting with 0) and skip the check until it has been flushed. GitHub issue 912.
* | Merge branch 'obsd-master'Thomas Adam2017-05-09
|\| | | | | | | | | Conflicts: format.c
| * Up to now, tmux sees \033\033[OA as M-Up and since we turned onnicm2017-05-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | xterm-keys by default, generates \033[1;3A instead of \033\033[OA. Unfortunately this confuses vi, which doesn't understand xterm keys and now sees Escape+Up pressed within escape-time as Escape followed by A. The issue doesn't happen in xterm itself because it gets the keys from X and can distinguish between a genuine M-Up and Escape+Up. Because xterm can, tmux can too: xterm will give us \033[1;3A (that is, kUP3) for a real M-Up and \033\033OA for Escape+Up - in fact, we can be sure any \033 preceding an xterm key is a real Escape key press because Meta would be part of the xterm key instead of a separate \033. So change tmux to recognise both sequences as M-Up for its own purposes, but generate the xterm version of M-Up only if it originally received the xterm version from the terminal. This means we will return to sending \033\033OA instead of the xterm key for terminals that do not support xterm keys themselves, but there is no practical way around this because they do not allow us to distinguish between Escape+Up and M-Up. xterm style escape sequences are now the de facto standard for these keys in any case. Problem reported by jsing@ and subsequently by Cecile Tonglet in GitHub issue 907.
* | Merge branch 'obsd-master'Thomas Adam2017-05-01
|\|
| * In order that people can use formats like #D in #() in the status linenicm2017-05-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | and not have to wait for an update when they change pane, we allow commands to run more than once a second if the expanded form changes. Unfortunately this can mean them being run far too often (pretty much continually) when multiple clients exist, because some formats (including #D) will always differ between clients. To avoid this, give each client its own tree of jobs which means that the same command will be different instances for each client - similar to how we have the tag to separate commands for different panes. GitHub issue 889; test case reported by Paul Johnson.
* | Merge branch 'obsd-master'Thomas Adam2017-04-22
|\|
| * Mouse bindings and hooks set up an initial current state when running anicm2017-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | command. This is used for the session, window and pane for all commands in the command sequence if there is no -t or -s. However, using it for all commands in the command sequence means that if the active pane or current session is changed, subsequent commands still use the previous state. So make commands which explicitly change the current state (such as neww and selectp) update it themselves for later commands. Commands which may invalidate the state (like killp) are already OK because an invalid state will be ignored. Also fill in the current state for all key bindings rather than just the mouse, so that any omissions are easier to spot.
* | Merge branch 'obsd-master'Thomas Adam2017-04-22
|\|
| * Log error properly when no current state, and some other minor tweaks.nicm2017-04-21
| |
* | Merge branch 'obsd-master'Thomas Adam2017-04-21
|\|
| * Key needs to be initialized to zero now it has flags in it.nicm2017-04-21
| |
* | Merge branch 'obsd-master'Thomas Adam2017-04-21
|\|
| * Add cmd_find_from_winlink_pane and use it in a couple of places, andnicm2017-04-21
| | | | | | | | make functions that can't fail void.
* | Merge branch 'obsd-master'Thomas Adam2017-04-21
|\|
| * It is annoying that the copy mode key table (or any other key table)nicm2017-04-21
| | | | | | | | | | | | | | | | | | | | | | | | will suppress root key table bindings. So change to always check the root table if no binding is found in the current table (whether it be the prefix table from pressing the prefix or the copy mode table from a pane). A root key binding can be blocked by binding the key to a command that does nothing (like send-keys with no arguments). Problem reported by Thomas Sattler.
* | Merge branch 'obsd-master'Thomas Adam2017-04-21
|\|
| * Store state shared between multiple commands in the queue in a sharednicm2017-04-21
| | | | | | | | structure.
* | Merge branch 'obsd-master'Thomas Adam2017-04-20
|\|
| * Only set up a current target for mouse key bindings. Fixes:nicm2017-04-20
| | | | | | | | | | | | | | bind q select-pane -U \; resize-pane -Z (There is still some possible weirdness with the way we do current targets, it should probably be done in a different way at some point.)
* | Merge branch 'obsd-master'Thomas Adam2017-04-19
|\|
| * Add a suspend helper function, and do not allow detaching or suspendingnicm2017-04-19
| | | | | | | | while already doing so.
* | Merge branch 'obsd-master'Thomas Adam2017-04-19
|\|
| * When the data we have buffered to write to a terminal grows beyond anicm2017-04-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | reasonable amount (currently width * height * 8 bytes), discard all output to the terminal and start trying to redraw periodically instead. Continue with this until the amount of data we are trying to write falls to a low level again. This helps to prevent tmux sitting on a huge buffer of data when there are processes with fast output running inside tmux but the outside terminal is slow. A new client_discarded format holds the amount of data that has been discarded due to this mechanism. The three variables (when to start this, when to stop, and how often to redraw) are basically "works for me" at the moment, this is going in to see how it goes and if it causes problems for anyone else.
* | Merge branch 'obsd-master'Thomas Adam2017-04-19
|\|
| * On terminals without DECSLRM, when a pane that is less than the fullnicm2017-04-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | with of the terminal scrolls, tmux needs to redraw the entire pane. This results in a large amount of output data which can cause slow terminals to struggle, particularly when many lines are scrolled together quickly. This can be reduced by only redrawing when tmux doesn't hold any buffered data for the terminal. If a redraw is required and data is buffered, the redraw is deferred until all that data is consumed (it is checked after every event loop, a timer is used to ensure this happens at some point). While a redraw is pending, no additional data will be written to the terminal. The redraw still happens, now it is just pushed back if it is possible it would just add more data on top of a terminal that is already behind. This both gives the terminal a chance to catch up, and allows tmux to process more scrolling (that would require additional redraws) in the meantime. Helps with a problem reported by Greg Hurrell.
* | Merge branch 'obsd-master'Thomas Adam2017-04-17
|\|
| * Remove a couple of redraw flags that no longer have any effect.nicm2017-04-17
| |
* | Merge branch 'obsd-master'Thomas Adam2017-04-06
|\| | | | | | | | | | | Conflicts: server-client.c tmux.1
| * Give each client a name. This defaults to the tty name as before butnicm2017-04-05
| | | | | | | | | | | | | | falls back to an alternative if the tty name is not available. This is clearer than overloading the client ttyname member and allows us to remove the path stored in the tty struct, it should always be the same as the client.
* | Merge branch 'obsd-master'Thomas Adam2017-03-10
|\|
| * Clear the bracket paste mode when in the command prompt.nicm2017-03-09
| |
* | Merge branch 'obsd-master'Thomas Adam2017-03-09
|\|
| * Move the client identify (display-panes) code into server-client.c.nicm2017-03-09
| |
* | Merge branch 'obsd-master'Thomas Adam2017-02-14
|\|
| * Make source-file look for files relative to the client working directorynicm2017-02-14
| | | | | | | | | | (like load-buffer and save-buffer), from Chris Pickel. Also break the where-is-this-file code out into its own function for loadb and saveb.
* | Merge branch 'obsd-master'Thomas Adam2017-02-09
|\|
| * Break the message storage function into its own function, useful fornicm2017-02-09
| | | | | | | | debugging.
* | Merge branch 'obsd-master'Thomas Adam2017-02-08
|\|
| * Some other tidying bits.nicm2017-02-08
| |
* | Merge branch 'obsd-master'Thomas Adam2017-02-03
|\|
| * Add a window or pane id "tag" to each format tree and use it to separatenicm2017-02-03
| | | | | | | | | | | | jobs, this means that if the same job is used for different windows or panes (for example in pane-border-format), it will be run separately for each pane.
* | Merge branch 'obsd-master'Thomas Adam2017-02-01
|\|
| * Implement "all event" (1003) mouse mode but in a way that works. Thenicm2017-02-01
| | | | | | | | | | | | | | | | | | | | | | main issue is that if we have two panes, A with 1002 and B with 1003, we need to set 1003 outside tmux in order to get all the mouse events, but then we need to suppress the ones that pane A doesn't want. This is easy in SGR mouse mode, because buttons == 3 is only used for movement events (for other events the trailing m/M marks a release instead), but in normal mouse mode we can't tell so easily. So for that, look at the previous event instead - if it is drag+release as well, then the current event is a movement event.
* | Merge branch 'obsd-master'Thomas Adam2017-01-13
|\|