summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/window.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* The mouse should only work in copy mode if mode-mouse is set, not justnicm2011-04-181-2/+3
| | | | mouse-select-pane.
* Give each pane created in a tmux server a unique id (starting from 0),nicm2011-03-271-2/+31
| | | | | put it in the TMUX_PANE environment variable and accept it as a target. Suggested by and with testing and tweaks from Ben Boeckel.
* Check if the index is in use and fail before creating the child process,nicm2011-01-251-10/+16
| | | | rather than leaving a stray child on failure.
* Move all calls to fcntl(...O_NONBLOCK) into a function and clear thenicm2011-01-081-6/+3
| | | | | flag on the stdio file descriptors before closing them (fixes things like "tmux ls && cat").
* Add a function to create window flags rather than doing the same thingnicm2010-12-301-1/+27
| | | | in two places. From Thomas Adam.
* Add an option to alert (monitor) for silence (lack of activity) in anicm2010-12-061-1/+9
| | | | window. From Thomas Adam.
* Don't allow last and active window to become the same - a very bad movenicm2010-11-141-2/+4
| | | | when the active window is closed and freed. Reported by sthen@.
* Add a last-pane command (bound to ; by default). Requested ages ago bynicm2010-10-231-5/+11
| | | | somebody whose name I have forgotten.
* When removing a pane, don't change the active pane unless the activenicm2010-10-231-4/+6
| | | | pane is actually the one being removed.
* Trying to set FD_CLOEXEC on every fd is a lost cause, just usenicm2010-10-161-3/+3
| | | | closefrom() before exec.
* When destroying a pane, reset any mode (which reenables panenicm2010-08-251-2/+3
| | | | bufferevent) before freeing the bufferevent.
* Do not call event_del() for signals after fork(), just use sigaction()nicm2010-08-191-2/+2
| | | | | directly instead - calling libevent functions after fork() w/o event_reinit() is a bad idea, even if in this case it was harmless.
* Make pane/window wrapping more logical (so with 10 windows, +10 fromnicm2010-07-141-5/+28
| | | | window 5 stays in the same place), and tidy the code. From Tiago Cunha.
* Extend the -t:+ and -t:- window targets for next and previous window tonicm2010-06-211-1/+23
| | | | accept an offset such as -t:+2. From Tiago Cunha.
* Pass in the session, rather than the client, to window modes' key()nicm2010-05-231-5/+5
| | | | | | | | | function. We were only ever using the client to find the session anyway. This allows send-key to work properly for manipulating copy mode from outside tmux. From Micah Cowan.
* Put this back in with the initialisation in the right order.nicm2010-05-041-2/+2
|
* Revert last change, it appears to be broken somehow.nicm2010-05-041-2/+2
|
* Make signal handler setup/teardown two common functions instead of six,nicm2010-05-031-2/+2
| | | | | and reset SIGCHLD after fork to fix problems with some shells. From Romain Francois.
* Run job commands explicitly in the global enviroment (which can benicm2010-04-041-23/+7
| | | | | modified with setenv -g) rather than with the environment tmux started with.
* Squash a function that is only called in a callback into the callbacknicm2010-04-041-20/+13
| | | | function.
* Support up, down, left, right movement through panes with -UDLR flags tonicm2010-03-221-1/+111
| | | | | | | select-pane. Also REMOVE the up- and down-pane commands: equivalent behaviour is now available using -t :.+ and -t :.-.
* New input parser based on http://vt100.net/emu/dec_ansi_parser.nicm2010-03-221-1/+76
|
* Instead of bailing out on the first configuration file error, carry on,nicm2010-02-061-4/+1
| | | | | collecting all the errors, then start with the active window in more mode displaying them.
* Massive spaces->tabs and trailing whitespace cleanup, hopefully for the lastnicm2009-12-031-6/+6
| | | | | time now I've configured emacs to make them displayed in really annoying colours...
* Remove a couple of unused arguments where possible, and add /* ARGSUSED */ tonicm2009-11-261-3/+5
| | | | the rest to reduce lint output.
* Change status line drawing to create the window list in a separate screen andnicm2009-11-191-1/+3
| | | | | then copy it into the status line screen. This allows UTF-8 in window names and fixes some problems with #[] in window-status-format.
* Destroy panes immediately rather than checking them all every loop.nicm2009-11-131-4/+2
|
* Change window name change to use a timer event rather than a gettimeofday()nicm2009-11-041-9/+6
| | | | check every loop.
* Convert the window pane (pty master side) fd over to use a bufferevent.nicm2009-11-041-13/+40
| | | | | The evbuffer API is very similar to the existing tmux buffer API so this was remarkably painless. Not many possible ways to do it, I suppose.
* Switch window pane pipe redirect fd over to a bufferevent.nicm2009-11-041-5/+4
|
* Initial changes to move tmux to libevent.nicm2009-11-041-2/+4
| | | | | | | | | This moves the client-side loops are pretty much fully over to event-based only (tmux.c and client.c) but server-side (server.c and friends) treats libevent as a sort of clever poll, waking up after every event to run various things. Moving the server stuff over to bufferevents and timers and so on will come later.
* Only redraw the pane when changing mode, not the entire window.nicm2009-10-221-3/+3
|
* Stop updating the screen when not in output mode, stops copy mode gettingnicm2009-10-191-1/+4
| | | | confused.
* Add a pipe-pane command to allow a pane to be piped to a shell command, fornicm2009-10-111-1/+18
| | | | | | | | | | | example: pipe-pane 'cat >~/out' No arguments stops outputing and closes the pipe; the -o flag toggles a pipe and on and off (useful for key bindings). Suggested by espie@.
* Clean up by introducing a wrapper struct for mouse clicks rather than passingnicm2009-10-111-10/+8
| | | | | | | three u_chars around. As a side-effect this fixes incorrectly rejecting high cursor positions (because it was comparing them as signed char), reported by Tom Doherty.
* Accept key and mouse input for keys in zombified windows if they are in a mode..nicm2009-10-101-5/+7
|
* New option, mouse-select-pane. If on, the mouse may be used to select thenicm2009-10-101-1/+18
| | | | | | current pane. Suggested by sthen@ and also by someone else ages ago who I have forgotten.
* Add "grouped sessions" which have independent name, options, current window andnicm2009-10-101-5/+5
| | | | | | | | so on but where the linked windows are synchronized (ie creating, killing windows and so on are mirrored between the sessions). A grouped session may be created by passing -t to new-session. Had this around for a while, tested by a couple of people.
* Add a simple synchronize-panes window option: when set, all input to any panenicm2009-10-091-3/+15
| | | | | that is part of the window is also sent to all other panes in the same window. Suggested by several, most recently Tomasz Pajor.
* Regularise some fatal messages.nicm2009-09-201-2/+2
|
* Rather than constructing an entire termios struct from ttydefaults.h, just letnicm2009-09-161-2/+11
| | | | | forkpty do it and then alter the bits that should be changed after fork. A little neater and more portable.
* If forking a login shell or if SHELL is otherwise not useful, set it to thenicm2009-09-011-1/+7
| | | | default shell. Based on a diff from martynas@.
* When using tmux as a login shell, there is currently no way to specify a shellnicm2009-09-011-42/+18
| | | | | | | | | | | | to be used as a login shell inside tmux, so add a default-shell session option. This sets the shell invoked as a login shell when the default-command option is empty. The default option value is whichever of $SHELL, getpwuid(getuid())'s pw_shell or /bin/sh is valid first. Based on a diff from martynas@, changed by me to be a session option rather than a window option.
* Add a base-index session option to specify the first index checked when lookingnicm2009-08-131-13/+15
| | | | for an index for a new window.
* When creating a new session from the command-line where there is an externalnicm2009-08-131-6/+7
| | | | | terminal, copy the termios(4) special characters and use them for new windows created in the new session. Suggested by Theo.
* When started as the shell, __progname contains a leading -, so hardcode "tmux"nicm2009-08-121-2/+6
| | | | for socket path and log files, and strip it when working out the shell.
* Have the client pass its stdin fd to the server when identifying itself andnicm2009-08-111-5/+16
| | | | | | | | | have the server use that rather than reopening the tty. If the fd isn't given, use the old behaviour (so no need for a version change). This allows tmux to be used as the shell, so also change so that when working out the command to execute if default-command is empty (the default), tmux will try not execute itself.
* Infrastructure and commands to manage the environment for processes startednicm2009-08-081-12/+27
| | | | | | | | | | | | | | | within tmux. There is a global environment, copied from the external environment when the server is started and each sesssion has an (initially empty) session environment which overrides it. New commands set-environment and show-environment manipulate or display the environments. A new session option, update-environment, is a space-separated list of variables which are updated from the external environment into the session environment every time a new session is created - the default is DISPLAY.
* If select-layout is not given an argument, repply the last layout used in thenicm2009-07-281-2/+2
| | | | window, if any.
* window_add_pane cannot fail, so remove the unused cause argument and don'tnicm2009-07-221-6/+3
| | | | bother to check for a NULL return.