mirror of
https://github.com/tmux/tmux.git
synced 2025-09-02 05:21:10 +00:00
Improve #? conditional expression in formats:
1) add support for else if, so #{?cond1,value1,#{?cond2,value2,else-value}} can be changed to #{?cond1,value1,cond2,value2,else-value}; 2) add default empty string if there's no else value, so #{?cond1,value1,} can be changed to #{?cond1,value1}. From David Mandelberg in GitHub issue 4451.
This commit is contained in:
@ -44,12 +44,8 @@ static void window_buffer_key(struct window_mode_entry *,
|
||||
#define WINDOW_BUFFER_DEFAULT_KEY_FORMAT \
|
||||
"#{?#{e|<:#{line},10}," \
|
||||
"#{line}" \
|
||||
"," \
|
||||
"#{?#{e|<:#{line},36}," \
|
||||
"M-#{a:#{e|+:97,#{e|-:#{line},10}}}" \
|
||||
"," \
|
||||
"" \
|
||||
"}" \
|
||||
",#{e|<:#{line},36}," \
|
||||
"M-#{a:#{e|+:97,#{e|-:#{line},10}}}" \
|
||||
"}"
|
||||
|
||||
static const struct menu_item window_buffer_menu_items[] = {
|
||||
|
Reference in New Issue
Block a user