Commit Graph

504 Commits

Author SHA1 Message Date
Thomas Adam
c6215b55e0 Merge branch 'obsd-master' into master 2021-02-09 16:01:18 +00:00
nicm
1492ae11a5 Do not expand times and #() inside #(). 2021-02-09 14:25:40 +00:00
Thomas Adam
39904f7fc6 Merge branch 'obsd-master' into master 2021-02-05 14:01:23 +00:00
nicm
be471c328e Add a -S flag to new-window to make it select the existing window if one
with the given name already exists rather than failing with an error.
Also add a format to check if a window or session name exists which
allows the same with other commands. Requested by and discussed with
kn@.
2021-02-05 12:23:49 +00:00
Thomas Adam
545a610c6b Merge branch 'obsd-master' into master 2021-01-29 12:01:21 +00:00
nicm
255802d8d7 Trim output overwritten by later text or clears completely rather than
only in a few cases. This means we can better track when a line should
wrap. GitHub issue 2537.
2021-01-29 09:48:43 +00:00
Thomas Adam
9ff017e908 Merge branch 'obsd-master' into master 2021-01-20 08:01:22 +00:00
nicm
fb774b77d0 Change so that window_flags escapes # automatically which means configs
will not have to change. A new format window_raw_flags contains the old
unescaped version.
2021-01-20 07:16:54 +00:00
Thomas Adam
f72deb092a Merge branch 'obsd-master' into master 2020-12-30 22:01:23 +00:00
nicm
f97305af31 Use right format for session loop, GitHub issue 2519. 2020-12-30 18:29:40 +00:00
Thomas Adam
950e982001 Merge branch 'obsd-master' into master 2020-12-15 10:01:22 +00:00
nicm
8bd29a30bf Make synchronize-panes a pane option and add -U flag to set-option to
unset an option on all panes. GitHub issue 2491 from Rostislav Nesin.
2020-12-15 08:31:50 +00:00
Thomas Adam
27634645e9 Merge branch 'obsd-master' into master 2020-12-01 10:01:22 +00:00
nicm
9a74bba007 Make replacement of ##s consistent when drawing formats, whether
followed by [ or not. Add a flag (e) to the q: format modifier to double
up #s and use it for the window_flags format variable so it doesn't end
up escaping any following text. GitHub issue 2485.
2020-12-01 08:12:58 +00:00
Thomas Adam
5ddbf0c918 Merge branch 'obsd-master' 2020-11-09 10:01:27 +00:00
nicm
61e55fa50d Change how escaping is processed for formats so that ## and # can be
used in styles. Also add a 'w' format modifier for the width. From Chas
J Owens IV in GitHub issue 2389.
2020-11-09 09:10:10 +00:00
Thomas Adam
ff53eed402 Merge branch 'obsd-master' 2020-11-02 10:01:20 +00:00
nicm
ac5045a00f Add numeric comparisons for formats, from teo_paul1 at yahoo dot com in
GitHub issue 2442.
2020-11-02 08:21:30 +00:00
Thomas Adam
57168f3f59 Merge branch 'obsd-master' 2020-10-06 10:01:20 +01:00
nicm
7e319756d2 Fix a last minute change in previous. 2020-10-06 07:36:42 +00:00
nicm
e369f64669 Add a state struct to store working state during format expansion
instead of modiyfing the format tree.

Use this to disable nested job expansion so that the result of #() is
not expanded again. Reported by Chas J Owens IV, GitHub issue 2390.
2020-10-06 07:36:05 +00:00
Thomas Adam
c3e1b841f9 Merge branch 'obsd-master' 2020-09-16 20:01:19 +01:00
nicm
869c0e860f Fix some warnings, GitHub issue 2382. 2020-09-16 18:37:55 +00:00
Thomas Adam
b895ffbf37 Merge branch 'obsd-master' 2020-08-27 10:01:20 +01:00
nicm
2ab289980a Add pane_last format, GitHub issue 2353. 2020-08-27 06:55:54 +00:00
Thomas Adam
769ae10658 Merge branch 'obsd-master' 2020-08-20 20:01:19 +01:00
nicm
d0957529ed Add n: modifier to get length of a format, also automatically expand
variable name arguments again if they contain a #{.
2020-08-20 16:57:40 +00:00
Thomas Adam
1f515663d1 Merge branch 'obsd-master' 2020-06-23 08:01:18 +01:00
nicm
2964dde903 Use xvasprintf not vasprintf. 2020-06-23 05:23:26 +00:00
Thomas Adam
b5c86fdc0c Merge branch 'obsd-master' 2020-06-11 22:01:23 +01:00
nicm
63c2ed1483 Add some formats for search in copy mode (search_present, search_match).
GitHub issue 2268.
2020-06-11 19:43:34 +00:00
Thomas Adam
31a51cae1d Merge branch 'obsd-master' 2020-06-02 11:29:48 +01:00
nicm
9819470058 Change format callback to return value rather than storing it in the entry. 2020-06-01 19:39:25 +00:00
Thomas Adam
b34af611a5 Merge branch 'obsd-master' 2020-05-25 18:01:20 +01:00
nicm
bbfb44e9b2 Make some data types consistent. 2020-05-25 15:02:25 +00:00
nicm
d67245c734 Add a customize mode where keys and options may be browsed and changed,
includes adding a brief description of each option. Bound to "C" by
default.
2020-05-16 16:02:24 +00:00
nicm
daa95810b5 Allow a custom time format to be given to the t format modifier. 2020-05-16 15:48:35 +00:00
nicm
367b4e4e0f Change message log to be per server rather than per client and include
every command that is run.
2020-05-16 15:47:22 +00:00
nicm
cf9baddd6f Change the existing client flags for control mode to apply for any
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.
2020-05-16 15:45:29 +00:00
nicm
0487029fc5 Call format_defaults_window for panes as well. 2020-05-16 14:55:38 +00:00
nicm
0dd1944206 Tweak the default choose modes formats:
- Only show pane title if it is not default and not empty.
- Add a prettier time format and use that instead of long ctime().
- Remove clutter and change the order.
2020-05-16 14:10:29 +00:00
Nicholas Marriott
a61cbf1c33 Add a customize mode where options may be browsed and changed, includes adding
a brief description of each option. Bound to "C" by default.
2020-05-08 19:10:09 +01:00
Nicholas Marriott
708e9bc072 Allow a custom time format to be given to the t format modifier. 2020-05-07 11:04:43 +01:00
Nicholas Marriott
b0fa36734e Fix pretty time function to actually work and allow time format to be applied
to any string that is suitable.
2020-05-07 09:55:06 +01:00
Nicholas Marriott
7a95e9bf7e Change message log to be per server rather than per client and include every
command that is run.
2020-05-06 13:43:22 +01:00
Nicholas Marriott
2f89d2e7d8 Change the existing client flags for control mode to apply for any 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.
2020-05-05 15:42:20 +01:00
Nicholas Marriott
a43a156846 Call format_defaults_window for panes as well. 2020-04-28 10:53:35 +01:00
Nicholas Marriott
c30e765c7b Add some additional format helper functions. 2020-04-27 14:33:17 +01:00
Nicholas Marriott
8650f44340 Move terminal features into a single file. 2020-04-24 06:40:51 +01:00
Nicholas Marriott
106e5d07be Tweak the default choose modes formats:
- Only show pane title if it is not default and not empty.
- Add a prettier time format and use that instead of long ctime().
- Remove clutter and change the order.
2020-04-23 06:30:15 +01:00