aboutsummaryrefslogtreecommitdiff
path: root/xterm-keys.c
Commit message (Collapse)AuthorAge
* xterm-keys has been on by default for 5 years and all other modern terminalsNicholas Marriott2020-05-15
| | | | | | 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.
* 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.
* Revert previous for now, it will break TERM=screen.nicm2017-01-25
|
* If xterm-keys is on, use xterm(1) style keys for Home and End as well asnicm2017-01-25
| | | | modified keys.
* Remove some dead code in cmd-move-window.c and make a load of localnicm2016-10-03
| | | | functions static.
* I no longer use my SourceForge address so replace it.nicm2016-01-19
|
* Support UTF-8 key bindings by expanding the key type from int tonicm2015-11-12
| | | | | | uint64_t and converting UTF-8 to Unicode on input and the reverse on output. (This allows key bindings, there are still omissions - the largest being that the various prompts do not accept UTF-8.)
* Some style nits and dead assignments.nicm2015-08-30
|
* Drop explicit support for F13-F20 and change to match the xterm terminfonicm2014-07-21
| | | | | | | | | | | | | entry: F13-F24 are S-F1 to S-F12 F25-F36 are C-F1 to C-F12 F37-F48 are C-S-F1 to C-S-F12 F49-F60 are M-F1 to M-F12 and F61-F63 are M-S-F1 to M-S-F3 This should be no difference for applications inside tmux, but means that any key binding for F13 will need to be replaced by S-F1 and so on.
* Handle the top bit of xterm(1)-style modifier keys, based on a diff fromnicm2014-05-27
| | | | Balazs Kezes.
* The last fix to xterm keys meant that some keys such as \033OA werenicm2014-02-10
| | | | | | being wrongly treated as partial matches. So both check xterm keys after standard keys and only wildcard the minimum required ('1' to '8'). Problems reported by Ralf Horstmann and Tim van der Molen.
* Fix partial matches with xterm-keys on, from m0viefreak dot cm atnicm2014-01-31
| | | | googlemail dot com.
* In terminals with XT, turn on modifyOtherKeys=1 with the escape sequenceNicholas Marriott2013-03-22
| | | | and handle the most common set. Pass them through if xterm-keys is on.
* Add a couple of extra xterm-style keys that gnome terminal provides,Nicholas Marriott2011-06-23
| | | | from Dustin Kirkland.
* Don't include meta twice when working out the flags to output forNicholas Marriott2011-03-27
| | | | | xterm-style keys - bit 3 is accepted on input but not on output. Also a style nit in the header.
* Last few tables that should be const.Nicholas Marriott2011-01-01
|
* Treat the meta bit in the xterm extended modifier key set as the same asNicholas Marriott2010-10-14
| | | | escape (tmux's meta). From Emanuele Giaquinta.
* Simplify xterm modifier detection by treating as a bitmask + 1. SpottedNicholas Marriott2010-09-01
| | | | by and diff from Emanuele Giaquinta.
* Massive spaces->tabs and trailing whitespace cleanup, hopefully for the lastNicholas Marriott2009-12-03
| | | | | time now I've configured emacs to make them displayed in really annoying colours...
* Handle partial xterm function key sequences.Nicholas Marriott2009-11-30
|
* Old xterm F1-F4 are \033O_P not \033[O_P.Nicholas Marriott2009-11-05
|
* Nuke accidentally-committed debugging statement.Nicholas Marriott2009-10-26
|
* Rewrite xterm-keys code (both input and output) so that works (doesn't alwaysNicholas Marriott2009-10-26
output the same modifiers, accepts all the possible input keys) and is more understandable.