xref: /openbsd-src/usr.bin/tmux/options-table.c (revision 4e1ee0786f11cc571bd0be17d38e46f635c719fc)
1 /* $OpenBSD: options-table.c,v 1.152 2021/10/14 13:19:01 nicm Exp $ */
2 
3 /*
4  * Copyright (c) 2011 Nicholas Marriott <nicholas.marriott@gmail.com>
5  *
6  * Permission to use, copy, modify, and distribute this software for any
7  * purpose with or without fee is hereby granted, provided that the above
8  * copyright notice and this permission notice appear in all copies.
9  *
10  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14  * WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
15  * IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
16  * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17  */
18 
19 #include <sys/types.h>
20 
21 #include <string.h>
22 #include <paths.h>
23 
24 #include "tmux.h"
25 
26 /*
27  * This file has a tables with all the server, session and window
28  * options. These tables are the master copy of the options with their real
29  * (user-visible) types, range limits and default values. At start these are
30  * copied into the runtime global options trees (which only has number and
31  * string types). These tables are then used to look up the real type when the
32  * user sets an option or its value needs to be shown.
33  */
34 
35 /* Choice option type lists. */
36 static const char *options_table_mode_keys_list[] = {
37 	"emacs", "vi", NULL
38 };
39 static const char *options_table_clock_mode_style_list[] = {
40 	"12", "24", NULL
41 };
42 static const char *options_table_status_list[] = {
43 	"off", "on", "2", "3", "4", "5", NULL
44 };
45 static const char *options_table_status_keys_list[] = {
46 	"emacs", "vi", NULL
47 };
48 static const char *options_table_status_justify_list[] = {
49 	"left", "centre", "right", "absolute-centre", NULL
50 };
51 static const char *options_table_status_position_list[] = {
52 	"top", "bottom", NULL
53 };
54 static const char *options_table_bell_action_list[] = {
55 	"none", "any", "current", "other", NULL
56 };
57 static const char *options_table_visual_bell_list[] = {
58 	"off", "on", "both", NULL
59 };
60 static const char *options_table_pane_status_list[] = {
61 	"off", "top", "bottom", NULL
62 };
63 static const char *options_table_pane_border_lines_list[] = {
64 	"single", "double", "heavy", "simple", "number", NULL
65 };
66 static const char *options_table_popup_border_lines_list[] = {
67 	"single", "double", "heavy", "simple", "rounded", "padded", "none", NULL
68 };
69 static const char *options_table_set_clipboard_list[] = {
70 	"off", "external", "on", NULL
71 };
72 static const char *options_table_window_size_list[] = {
73 	"largest", "smallest", "manual", "latest", NULL
74 };
75 static const char *options_table_remain_on_exit_list[] = {
76 	"off", "on", "failed", NULL
77 };
78 static const char *options_table_detach_on_destroy_list[] = {
79 	"off", "on", "no-detached", NULL
80 };
81 static const char *options_table_extended_keys_list[] = {
82 	"off", "on", "always", NULL
83 };
84 
85 /* Status line format. */
86 #define OPTIONS_TABLE_STATUS_FORMAT1 \
87 	"#[align=left range=left #{E:status-left-style}]" \
88 	"#[push-default]" \
89 	"#{T;=/#{status-left-length}:status-left}" \
90 	"#[pop-default]" \
91 	"#[norange default]" \
92 	"#[list=on align=#{status-justify}]" \
93 	"#[list=left-marker]<#[list=right-marker]>#[list=on]" \
94 	"#{W:" \
95 		"#[range=window|#{window_index} " \
96 			"#{E:window-status-style}" \
97 			"#{?#{&&:#{window_last_flag}," \
98 				"#{!=:#{E:window-status-last-style},default}}, " \
99 				"#{E:window-status-last-style}," \
100 			"}" \
101 			"#{?#{&&:#{window_bell_flag}," \
102 				"#{!=:#{E:window-status-bell-style},default}}, " \
103 				"#{E:window-status-bell-style}," \
104 				"#{?#{&&:#{||:#{window_activity_flag}," \
105 					     "#{window_silence_flag}}," \
106 					"#{!=:" \
107 					"#{E:window-status-activity-style}," \
108 					"default}}, " \
109 					"#{E:window-status-activity-style}," \
110 				"}" \
111 			"}" \
112 		"]" \
113 		"#[push-default]" \
114 		"#{T:window-status-format}" \
115 		"#[pop-default]" \
116 		"#[norange default]" \
117 		"#{?window_end_flag,,#{window-status-separator}}" \
118 	"," \
119 		"#[range=window|#{window_index} list=focus " \
120 			"#{?#{!=:#{E:window-status-current-style},default}," \
121 				"#{E:window-status-current-style}," \
122 				"#{E:window-status-style}" \
123 			"}" \
124 			"#{?#{&&:#{window_last_flag}," \
125 				"#{!=:#{E:window-status-last-style},default}}, " \
126 				"#{E:window-status-last-style}," \
127 			"}" \
128 			"#{?#{&&:#{window_bell_flag}," \
129 				"#{!=:#{E:window-status-bell-style},default}}, " \
130 				"#{E:window-status-bell-style}," \
131 				"#{?#{&&:#{||:#{window_activity_flag}," \
132 					     "#{window_silence_flag}}," \
133 					"#{!=:" \
134 					"#{E:window-status-activity-style}," \
135 					"default}}, " \
136 					"#{E:window-status-activity-style}," \
137 				"}" \
138 			"}" \
139 		"]" \
140 		"#[push-default]" \
141 		"#{T:window-status-current-format}" \
142 		"#[pop-default]" \
143 		"#[norange list=on default]" \
144 		"#{?window_end_flag,,#{window-status-separator}}" \
145 	"}" \
146 	"#[nolist align=right range=right #{E:status-right-style}]" \
147 	"#[push-default]" \
148 	"#{T;=/#{status-right-length}:status-right}" \
149 	"#[pop-default]" \
150 	"#[norange default]"
151 #define OPTIONS_TABLE_STATUS_FORMAT2 \
152 	"#[align=centre]#{P:#{?pane_active,#[reverse],}" \
153 	"#{pane_index}[#{pane_width}x#{pane_height}]#[default] }"
154 static const char *options_table_status_format_default[] = {
155 	OPTIONS_TABLE_STATUS_FORMAT1, OPTIONS_TABLE_STATUS_FORMAT2, NULL
156 };
157 
158 /* Helpers for hook options. */
159 #define OPTIONS_TABLE_HOOK(hook_name, default_value) \
160 	{ .name = hook_name, \
161 	  .type = OPTIONS_TABLE_COMMAND, \
162 	  .scope = OPTIONS_TABLE_SESSION, \
163 	  .flags = OPTIONS_TABLE_IS_ARRAY|OPTIONS_TABLE_IS_HOOK, \
164 	  .default_str = default_value,	\
165 	  .separator = "" \
166 	}
167 
168 #define OPTIONS_TABLE_PANE_HOOK(hook_name, default_value) \
169 	{ .name = hook_name, \
170 	  .type = OPTIONS_TABLE_COMMAND, \
171 	  .scope = OPTIONS_TABLE_WINDOW|OPTIONS_TABLE_PANE, \
172 	  .flags = OPTIONS_TABLE_IS_ARRAY|OPTIONS_TABLE_IS_HOOK, \
173 	  .default_str = default_value,	\
174 	  .separator = "" \
175 	}
176 
177 #define OPTIONS_TABLE_WINDOW_HOOK(hook_name, default_value) \
178 	{ .name = hook_name, \
179 	  .type = OPTIONS_TABLE_COMMAND, \
180 	  .scope = OPTIONS_TABLE_WINDOW, \
181 	  .flags = OPTIONS_TABLE_IS_ARRAY|OPTIONS_TABLE_IS_HOOK, \
182 	  .default_str = default_value,	\
183 	  .separator = "" \
184 	}
185 
186 /* Map of name conversions. */
187 const struct options_name_map options_other_names[] = {
188 	{ "display-panes-color", "display-panes-colour" },
189 	{ "display-panes-active-color", "display-panes-active-colour" },
190 	{ "clock-mode-color", "clock-mode-colour" },
191 	{ "pane-colors", "pane-colours" },
192 	{ NULL, NULL }
193 };
194 
195 /* Top-level options. */
196 const struct options_table_entry options_table[] = {
197 	/* Server options. */
198 	{ .name = "backspace",
199 	  .type = OPTIONS_TABLE_KEY,
200 	  .scope = OPTIONS_TABLE_SERVER,
201 	  .default_num = '\177',
202 	  .text = "The key to send for backspace."
203 	},
204 
205 	{ .name = "buffer-limit",
206 	  .type = OPTIONS_TABLE_NUMBER,
207 	  .scope = OPTIONS_TABLE_SERVER,
208 	  .minimum = 1,
209 	  .maximum = INT_MAX,
210 	  .default_num = 50,
211 	  .text = "The maximum number of automatic buffers. "
212 		  "When this is reached, the oldest buffer is deleted."
213 	},
214 
215 	{ .name = "command-alias",
216 	  .type = OPTIONS_TABLE_STRING,
217 	  .scope = OPTIONS_TABLE_SERVER,
218 	  .flags = OPTIONS_TABLE_IS_ARRAY,
219 	  .default_str = "split-pane=split-window,"
220 			 "splitp=split-window,"
221 			 "server-info=show-messages -JT,"
222 			 "info=show-messages -JT,"
223 			 "choose-window=choose-tree -w,"
224 			 "choose-session=choose-tree -s",
225 	  .separator = ",",
226 	  .text = "Array of command aliases. "
227 		  "Each entry is an alias and a command separated by '='."
228 	},
229 
230 	{ .name = "copy-command",
231 	  .type = OPTIONS_TABLE_STRING,
232 	  .scope = OPTIONS_TABLE_SERVER,
233 	  .default_str = "",
234 	  .text = "Shell command run when text is copied. "
235 		  "If empty, no command is run."
236 	},
237 
238 	{ .name = "default-terminal",
239 	  .type = OPTIONS_TABLE_STRING,
240 	  .scope = OPTIONS_TABLE_SERVER,
241 	  .default_str = TMUX_TERM,
242 	  .text = "Default for the 'TERM' environment variable."
243 	},
244 
245 	{ .name = "editor",
246 	  .type = OPTIONS_TABLE_STRING,
247 	  .scope = OPTIONS_TABLE_SERVER,
248 	  .default_str = _PATH_VI,
249 	  .text = "Editor run to edit files."
250 	},
251 
252 	{ .name = "escape-time",
253 	  .type = OPTIONS_TABLE_NUMBER,
254 	  .scope = OPTIONS_TABLE_SERVER,
255 	  .minimum = 0,
256 	  .maximum = INT_MAX,
257 	  .default_num = 500,
258 	  .text = "Time to wait before assuming a key is Escape."
259 	},
260 
261 	{ .name = "exit-empty",
262 	  .type = OPTIONS_TABLE_FLAG,
263 	  .scope = OPTIONS_TABLE_SERVER,
264 	  .default_num = 1,
265 	  .text = "Whether the server should exit if there are no sessions."
266 	},
267 
268 	{ .name = "exit-unattached",
269 	  .type = OPTIONS_TABLE_FLAG,
270 	  .scope = OPTIONS_TABLE_SERVER,
271 	  .default_num = 0,
272 	  .text = "Whether the server should exit if there are no attached "
273 		  "clients."
274 	},
275 
276 	{ .name = "extended-keys",
277 	  .type = OPTIONS_TABLE_CHOICE,
278 	  .scope = OPTIONS_TABLE_SERVER,
279 	  .choices = options_table_extended_keys_list,
280 	  .default_num = 0,
281 	  .text = "Whether to request extended key sequences from terminals "
282 	          "that support it."
283 	},
284 
285 	{ .name = "focus-events",
286 	  .type = OPTIONS_TABLE_FLAG,
287 	  .scope = OPTIONS_TABLE_SERVER,
288 	  .default_num = 0,
289 	  .text = "Whether to send focus events to applications."
290 	},
291 
292 	{ .name = "history-file",
293 	  .type = OPTIONS_TABLE_STRING,
294 	  .scope = OPTIONS_TABLE_SERVER,
295 	  .default_str = "",
296 	  .text = "Location of the command prompt history file. "
297 		  "Empty does not write a history file."
298 	},
299 
300 	{ .name = "message-limit",
301 	  .type = OPTIONS_TABLE_NUMBER,
302 	  .scope = OPTIONS_TABLE_SERVER,
303 	  .minimum = 0,
304 	  .maximum = INT_MAX,
305 	  .default_num = 1000,
306 	  .text = "Maximum number of server messages to keep."
307 	},
308 
309 	{ .name = "prompt-history-limit",
310 	  .type = OPTIONS_TABLE_NUMBER,
311 	  .scope = OPTIONS_TABLE_SERVER,
312 	  .minimum = 0,
313 	  .maximum = INT_MAX,
314 	  .default_num = 100,
315 	  .text = "Maximum number of commands to keep in history."
316 	},
317 
318 	{ .name = "set-clipboard",
319 	  .type = OPTIONS_TABLE_CHOICE,
320 	  .scope = OPTIONS_TABLE_SERVER,
321 	  .choices = options_table_set_clipboard_list,
322 	  .default_num = 1,
323 	  .text = "Whether to attempt to set the system clipboard ('on' or "
324 		  "'external') and whether to allow applications to create "
325 		  "paste buffers with an escape sequence ('on' only)."
326 	},
327 
328 	{ .name = "terminal-overrides",
329 	  .type = OPTIONS_TABLE_STRING,
330 	  .scope = OPTIONS_TABLE_SERVER,
331 	  .flags = OPTIONS_TABLE_IS_ARRAY,
332 	  .default_str = "",
333 	  .separator = ",",
334 	  .text = "List of terminal capabilities overrides."
335 	},
336 
337 	{ .name = "terminal-features",
338 	  .type = OPTIONS_TABLE_STRING,
339 	  .scope = OPTIONS_TABLE_SERVER,
340 	  .flags = OPTIONS_TABLE_IS_ARRAY,
341 	  .default_str = "xterm*:clipboard:ccolour:cstyle:focus:title,"
342 			 "screen*:title",
343 	  .separator = ",",
344 	  .text = "List of terminal features, used if they cannot be "
345 		  "automatically detected."
346 	},
347 
348 	{ .name = "user-keys",
349 	  .type = OPTIONS_TABLE_STRING,
350 	  .scope = OPTIONS_TABLE_SERVER,
351 	  .flags = OPTIONS_TABLE_IS_ARRAY,
352 	  .default_str = "",
353 	  .separator = ",",
354 	  .text = "User key assignments. "
355 		  "Each sequence in the list is translated into a key: "
356 		  "'User0', 'User1' and so on."
357 	},
358 
359 	/* Session options. */
360 	{ .name = "activity-action",
361 	  .type = OPTIONS_TABLE_CHOICE,
362 	  .scope = OPTIONS_TABLE_SESSION,
363 	  .choices = options_table_bell_action_list,
364 	  .default_num = ALERT_OTHER,
365 	  .text = "Action to take on an activity alert."
366 	},
367 
368 	{ .name = "assume-paste-time",
369 	  .type = OPTIONS_TABLE_NUMBER,
370 	  .scope = OPTIONS_TABLE_SESSION,
371 	  .minimum = 0,
372 	  .maximum = INT_MAX,
373 	  .default_num = 1,
374 	  .unit = "milliseconds",
375 	  .text = "Maximum time between input to assume it is pasting rather "
376 		  "than typing."
377 	},
378 
379 	{ .name = "base-index",
380 	  .type = OPTIONS_TABLE_NUMBER,
381 	  .scope = OPTIONS_TABLE_SESSION,
382 	  .minimum = 0,
383 	  .maximum = INT_MAX,
384 	  .default_num = 0,
385 	  .text = "Default index of the first window in each session."
386 	},
387 
388 	{ .name = "bell-action",
389 	  .type = OPTIONS_TABLE_CHOICE,
390 	  .scope = OPTIONS_TABLE_SESSION,
391 	  .choices = options_table_bell_action_list,
392 	  .default_num = ALERT_ANY,
393 	  .text = "Action to take on a bell alert."
394 	},
395 
396 	{ .name = "default-command",
397 	  .type = OPTIONS_TABLE_STRING,
398 	  .scope = OPTIONS_TABLE_SESSION,
399 	  .default_str = "",
400 	  .text = "Default command to run in new panes. If empty, a shell is "
401 		  "started."
402 	},
403 
404 	{ .name = "default-shell",
405 	  .type = OPTIONS_TABLE_STRING,
406 	  .scope = OPTIONS_TABLE_SESSION,
407 	  .default_str = _PATH_BSHELL,
408 	  .text = "Location of default shell."
409 	},
410 
411 	{ .name = "default-size",
412 	  .type = OPTIONS_TABLE_STRING,
413 	  .scope = OPTIONS_TABLE_SESSION,
414 	  .pattern = "[0-9]*x[0-9]*",
415 	  .default_str = "80x24",
416 	  .text = "Initial size of new sessions."
417 	},
418 
419 	{ .name = "destroy-unattached",
420 	  .type = OPTIONS_TABLE_FLAG,
421 	  .scope = OPTIONS_TABLE_SESSION,
422 	  .default_num = 0,
423 	  .text = "Whether to destroy sessions when they have no attached "
424 		  "clients."
425 	},
426 
427 	{ .name = "detach-on-destroy",
428 	  .type = OPTIONS_TABLE_CHOICE,
429 	  .scope = OPTIONS_TABLE_SESSION,
430 	  .choices = options_table_detach_on_destroy_list,
431 	  .default_num = 1,
432 	  .text = "Whether to detach when a session is destroyed, or switch "
433 		  "the client to another session if any exist."
434 	},
435 
436 	{ .name = "display-panes-active-colour",
437 	  .type = OPTIONS_TABLE_COLOUR,
438 	  .scope = OPTIONS_TABLE_SESSION,
439 	  .default_num = 1,
440 	  .text = "Colour of the active pane for 'display-panes'."
441 	},
442 
443 	{ .name = "display-panes-colour",
444 	  .type = OPTIONS_TABLE_COLOUR,
445 	  .scope = OPTIONS_TABLE_SESSION,
446 	  .default_num = 4,
447 	  .text = "Colour of not active panes for 'display-panes'."
448 	},
449 
450 	{ .name = "display-panes-time",
451 	  .type = OPTIONS_TABLE_NUMBER,
452 	  .scope = OPTIONS_TABLE_SESSION,
453 	  .minimum = 1,
454 	  .maximum = INT_MAX,
455 	  .default_num = 1000,
456 	  .unit = "milliseconds",
457 	  .text = "Time for which 'display-panes' should show pane numbers."
458 	},
459 
460 	{ .name = "display-time",
461 	  .type = OPTIONS_TABLE_NUMBER,
462 	  .scope = OPTIONS_TABLE_SESSION,
463 	  .minimum = 0,
464 	  .maximum = INT_MAX,
465 	  .default_num = 750,
466 	  .unit = "milliseconds",
467 	  .text = "Time for which status line messages should appear."
468 	},
469 
470 	{ .name = "history-limit",
471 	  .type = OPTIONS_TABLE_NUMBER,
472 	  .scope = OPTIONS_TABLE_SESSION,
473 	  .minimum = 0,
474 	  .maximum = INT_MAX,
475 	  .default_num = 2000,
476 	  .unit = "lines",
477 	  .text = "Maximum number of lines to keep in the history for each "
478 		  "pane. "
479 		  "If changed, the new value applies only to new panes."
480 	},
481 
482 	{ .name = "key-table",
483 	  .type = OPTIONS_TABLE_STRING,
484 	  .scope = OPTIONS_TABLE_SESSION,
485 	  .default_str = "root",
486 	  .text = "Default key table. "
487 		  "Key presses are first looked up in this table."
488 	},
489 
490 	{ .name = "lock-after-time",
491 	  .type = OPTIONS_TABLE_NUMBER,
492 	  .scope = OPTIONS_TABLE_SESSION,
493 	  .minimum = 0,
494 	  .maximum = INT_MAX,
495 	  .default_num = 0,
496 	  .unit = "seconds",
497 	  .text = "Time after which a client is locked if not used."
498 	},
499 
500 	{ .name = "lock-command",
501 	  .type = OPTIONS_TABLE_STRING,
502 	  .scope = OPTIONS_TABLE_SESSION,
503 	  .default_str = "lock -np",
504 	  .text = "Shell command to run to lock a client."
505 	},
506 
507 	{ .name = "message-command-style",
508 	  .type = OPTIONS_TABLE_STRING,
509 	  .scope = OPTIONS_TABLE_SESSION,
510 	  .default_str = "bg=black,fg=yellow",
511 	  .flags = OPTIONS_TABLE_IS_STYLE,
512 	  .separator = ",",
513 	  .text = "Style of the command prompt when in command mode, if "
514 		  "'mode-keys' is set to 'vi'."
515 	},
516 
517 	{ .name = "message-style",
518 	  .type = OPTIONS_TABLE_STRING,
519 	  .scope = OPTIONS_TABLE_SESSION,
520 	  .default_str = "bg=yellow,fg=black",
521 	  .flags = OPTIONS_TABLE_IS_STYLE,
522 	  .separator = ",",
523 	  .text = "Style of the command prompt."
524 	},
525 
526 	{ .name = "mouse",
527 	  .type = OPTIONS_TABLE_FLAG,
528 	  .scope = OPTIONS_TABLE_SESSION,
529 	  .default_num = 0,
530 	  .text = "Whether the mouse is recognised and mouse key bindings are "
531 		  "executed. "
532 		  "Applications inside panes can use the mouse even when 'off'."
533 	},
534 
535 	{ .name = "prefix",
536 	  .type = OPTIONS_TABLE_KEY,
537 	  .scope = OPTIONS_TABLE_SESSION,
538 	  .default_num = '\002',
539 	  .text = "The prefix key."
540 	},
541 
542 	{ .name = "prefix2",
543 	  .type = OPTIONS_TABLE_KEY,
544 	  .scope = OPTIONS_TABLE_SESSION,
545 	  .default_num = KEYC_NONE,
546 	  .text = "A second prefix key."
547 	},
548 
549 	{ .name = "renumber-windows",
550 	  .type = OPTIONS_TABLE_FLAG,
551 	  .scope = OPTIONS_TABLE_SESSION,
552 	  .default_num = 0,
553 	  .text = "Whether windows are automatically renumbered rather than "
554 		  "leaving gaps."
555 	},
556 
557 	{ .name = "repeat-time",
558 	  .type = OPTIONS_TABLE_NUMBER,
559 	  .scope = OPTIONS_TABLE_SESSION,
560 	  .minimum = 0,
561 	  .maximum = SHRT_MAX,
562 	  .default_num = 500,
563 	  .unit = "milliseconds",
564 	  .text = "Time to wait for a key binding to repeat, if it is bound "
565 		  "with the '-r' flag."
566 	},
567 
568 	{ .name = "set-titles",
569 	  .type = OPTIONS_TABLE_FLAG,
570 	  .scope = OPTIONS_TABLE_SESSION,
571 	  .default_num = 0,
572 	  .text = "Whether to set the terminal title, if supported."
573 	},
574 
575 	{ .name = "set-titles-string",
576 	  .type = OPTIONS_TABLE_STRING,
577 	  .scope = OPTIONS_TABLE_SESSION,
578 	  .default_str = "#S:#I:#W - \"#T\" #{session_alerts}",
579 	  .text = "Format of the terminal title to set."
580 	},
581 
582 	{ .name = "silence-action",
583 	  .type = OPTIONS_TABLE_CHOICE,
584 	  .scope = OPTIONS_TABLE_SESSION,
585 	  .choices = options_table_bell_action_list,
586 	  .default_num = ALERT_OTHER,
587 	  .text = "Action to take on a silence alert."
588 	},
589 
590 	{ .name = "status",
591 	  .type = OPTIONS_TABLE_CHOICE,
592 	  .scope = OPTIONS_TABLE_SESSION,
593 	  .choices = options_table_status_list,
594 	  .default_num = 1,
595 	  .text = "Number of lines in the status line."
596 	},
597 
598 	{ .name = "status-bg",
599 	  .type = OPTIONS_TABLE_COLOUR,
600 	  .scope = OPTIONS_TABLE_SESSION,
601 	  .default_num = 8,
602 	  .text = "Background colour of the status line. This option is "
603 		  "deprecated, use 'status-style' instead."
604 	},
605 
606 	{ .name = "status-fg",
607 	  .type = OPTIONS_TABLE_COLOUR,
608 	  .scope = OPTIONS_TABLE_SESSION,
609 	  .default_num = 8,
610 	  .text = "Foreground colour of the status line. This option is "
611 		  "deprecated, use 'status-style' instead."
612 	},
613 
614 	{ .name = "status-format",
615 	  .type = OPTIONS_TABLE_STRING,
616 	  .scope = OPTIONS_TABLE_SESSION,
617 	  .flags = OPTIONS_TABLE_IS_ARRAY,
618 	  .default_arr = options_table_status_format_default,
619 	  .text = "Formats for the status lines. "
620 		  "Each array member is the format for one status line. "
621 		  "The default status line is made up of several components "
622 		  "which may be configured individually with other options such "
623 		  "as 'status-left'."
624 	},
625 
626 	{ .name = "status-interval",
627 	  .type = OPTIONS_TABLE_NUMBER,
628 	  .scope = OPTIONS_TABLE_SESSION,
629 	  .minimum = 0,
630 	  .maximum = INT_MAX,
631 	  .default_num = 15,
632 	  .unit = "seconds",
633 	  .text = "Number of seconds between status line updates."
634 	},
635 
636 	{ .name = "status-justify",
637 	  .type = OPTIONS_TABLE_CHOICE,
638 	  .scope = OPTIONS_TABLE_SESSION,
639 	  .choices = options_table_status_justify_list,
640 	  .default_num = 0,
641 	  .text = "Position of the window list in the status line."
642 	},
643 
644 	{ .name = "status-keys",
645 	  .type = OPTIONS_TABLE_CHOICE,
646 	  .scope = OPTIONS_TABLE_SESSION,
647 	  .choices = options_table_status_keys_list,
648 	  .default_num = MODEKEY_EMACS,
649 	  .text = "Key set to use at the command prompt."
650 	},
651 
652 	{ .name = "status-left",
653 	  .type = OPTIONS_TABLE_STRING,
654 	  .scope = OPTIONS_TABLE_SESSION,
655 	  .default_str = "[#{session_name}] ",
656 	  .text = "Contents of the left side of the status line."
657 	},
658 
659 	{ .name = "status-left-length",
660 	  .type = OPTIONS_TABLE_NUMBER,
661 	  .scope = OPTIONS_TABLE_SESSION,
662 	  .minimum = 0,
663 	  .maximum = SHRT_MAX,
664 	  .default_num = 10,
665 	  .text = "Maximum width of the left side of the status line."
666 	},
667 
668 	{ .name = "status-left-style",
669 	  .type = OPTIONS_TABLE_STRING,
670 	  .scope = OPTIONS_TABLE_SESSION,
671 	  .default_str = "default",
672 	  .flags = OPTIONS_TABLE_IS_STYLE,
673 	  .separator = ",",
674 	  .text = "Style of the left side of the status line."
675 	},
676 
677 	{ .name = "status-position",
678 	  .type = OPTIONS_TABLE_CHOICE,
679 	  .scope = OPTIONS_TABLE_SESSION,
680 	  .choices = options_table_status_position_list,
681 	  .default_num = 1,
682 	  .text = "Position of the status line."
683 	},
684 
685 	{ .name = "status-right",
686 	  .type = OPTIONS_TABLE_STRING,
687 	  .scope = OPTIONS_TABLE_SESSION,
688 	  .default_str = "#{?window_bigger,"
689 			 "[#{window_offset_x}#,#{window_offset_y}] ,}"
690 			 "\"#{=21:pane_title}\" %H:%M %d-%b-%y",
691 	  .text = "Contents of the right side of the status line."
692 
693 	},
694 
695 	{ .name = "status-right-length",
696 	  .type = OPTIONS_TABLE_NUMBER,
697 	  .scope = OPTIONS_TABLE_SESSION,
698 	  .minimum = 0,
699 	  .maximum = SHRT_MAX,
700 	  .default_num = 40,
701 	  .text = "Maximum width of the right side of the status line."
702 	},
703 
704 	{ .name = "status-right-style",
705 	  .type = OPTIONS_TABLE_STRING,
706 	  .scope = OPTIONS_TABLE_SESSION,
707 	  .default_str = "default",
708 	  .flags = OPTIONS_TABLE_IS_STYLE,
709 	  .separator = ",",
710 	  .text = "Style of the right side of the status line."
711 	},
712 
713 	{ .name = "status-style",
714 	  .type = OPTIONS_TABLE_STRING,
715 	  .scope = OPTIONS_TABLE_SESSION,
716 	  .default_str = "bg=green,fg=black",
717 	  .flags = OPTIONS_TABLE_IS_STYLE,
718 	  .separator = ",",
719 	  .text = "Style of the status line."
720 	},
721 
722 	{ .name = "update-environment",
723 	  .type = OPTIONS_TABLE_STRING,
724 	  .scope = OPTIONS_TABLE_SESSION,
725 	  .flags = OPTIONS_TABLE_IS_ARRAY,
726 	  .default_str = "DISPLAY KRB5CCNAME SSH_ASKPASS SSH_AUTH_SOCK "
727 			 "SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY",
728 	  .text = "List of environment variables to update in the session "
729 		  "environment when a client is attached."
730 	},
731 
732 	{ .name = "visual-activity",
733 	  .type = OPTIONS_TABLE_CHOICE,
734 	  .scope = OPTIONS_TABLE_SESSION,
735 	  .choices = options_table_visual_bell_list,
736 	  .default_num = VISUAL_OFF,
737 	  .text = "How activity alerts should be shown: a message ('on'), "
738 		  "a message and a bell ('both') or nothing ('off')."
739 	},
740 
741 	{ .name = "visual-bell",
742 	  .type = OPTIONS_TABLE_CHOICE,
743 	  .scope = OPTIONS_TABLE_SESSION,
744 	  .choices = options_table_visual_bell_list,
745 	  .default_num = VISUAL_OFF,
746 	  .text = "How bell alerts should be shown: a message ('on'), "
747 		  "a message and a bell ('both') or nothing ('off')."
748 	},
749 
750 	{ .name = "visual-silence",
751 	  .type = OPTIONS_TABLE_CHOICE,
752 	  .scope = OPTIONS_TABLE_SESSION,
753 	  .choices = options_table_visual_bell_list,
754 	  .default_num = VISUAL_OFF,
755 	  .text = "How silence alerts should be shown: a message ('on'), "
756 		  "a message and a bell ('both') or nothing ('off')."
757 	},
758 
759 	{ .name = "word-separators",
760 	  .type = OPTIONS_TABLE_STRING,
761 	  .scope = OPTIONS_TABLE_SESSION,
762 	  /*
763 	   * The set of non-alphanumeric printable ASCII characters minus the
764 	   * underscore.
765 	   */
766 	  .default_str = "!\"#$%&'()*+,-./:;<=>?@[\\]^`{|}~",
767 	  .text = "Characters considered to separate words."
768 	},
769 
770 	/* Window options. */
771 	{ .name = "aggressive-resize",
772 	  .type = OPTIONS_TABLE_FLAG,
773 	  .scope = OPTIONS_TABLE_WINDOW,
774 	  .default_num = 0,
775 	  .text = "When 'window-size' is 'smallest', whether the maximum size "
776 		  "of a window is the smallest attached session where it is "
777 		  "the current window ('on') or the smallest session it is "
778 		  "linked to ('off')."
779 	},
780 
781 	{ .name = "allow-rename",
782 	  .type = OPTIONS_TABLE_FLAG,
783 	  .scope = OPTIONS_TABLE_WINDOW|OPTIONS_TABLE_PANE,
784 	  .default_num = 0,
785 	  .text = "Whether applications are allowed to use the escape sequence "
786 		  "to rename windows."
787 	},
788 
789 	{ .name = "alternate-screen",
790 	  .type = OPTIONS_TABLE_FLAG,
791 	  .scope = OPTIONS_TABLE_WINDOW|OPTIONS_TABLE_PANE,
792 	  .default_num = 1,
793 	  .text = "Whether applications are allowed to use the alternate "
794 		  "screen."
795 	},
796 
797 	{ .name = "automatic-rename",
798 	  .type = OPTIONS_TABLE_FLAG,
799 	  .scope = OPTIONS_TABLE_WINDOW,
800 	  .default_num = 1,
801 	  .text = "Whether windows are automatically renamed."
802 	},
803 
804 	{ .name = "automatic-rename-format",
805 	  .type = OPTIONS_TABLE_STRING,
806 	  .scope = OPTIONS_TABLE_WINDOW,
807 	  .default_str = "#{?pane_in_mode,[tmux],#{pane_current_command}}"
808 			 "#{?pane_dead,[dead],}",
809 	  .text = "Format used to automatically rename windows."
810 	},
811 
812 	{ .name = "clock-mode-colour",
813 	  .type = OPTIONS_TABLE_COLOUR,
814 	  .scope = OPTIONS_TABLE_WINDOW,
815 	  .default_num = 4,
816 	  .text = "Colour of the clock in clock mode."
817 	},
818 
819 	{ .name = "clock-mode-style",
820 	  .type = OPTIONS_TABLE_CHOICE,
821 	  .scope = OPTIONS_TABLE_WINDOW,
822 	  .choices = options_table_clock_mode_style_list,
823 	  .default_num = 1,
824 	  .text = "Time format of the clock in clock mode."
825 	},
826 
827 	{ .name = "copy-mode-match-style",
828 	  .type = OPTIONS_TABLE_STRING,
829 	  .scope = OPTIONS_TABLE_WINDOW,
830 	  .default_str = "bg=cyan,fg=black",
831 	  .flags = OPTIONS_TABLE_IS_STYLE,
832 	  .separator = ",",
833 	  .text = "Style of search matches in copy mode."
834 	},
835 
836 	{ .name = "copy-mode-current-match-style",
837 	  .type = OPTIONS_TABLE_STRING,
838 	  .scope = OPTIONS_TABLE_WINDOW,
839 	  .default_str = "bg=magenta,fg=black",
840 	  .flags = OPTIONS_TABLE_IS_STYLE,
841 	  .separator = ",",
842 	  .text = "Style of the current search match in copy mode."
843 	},
844 
845 	{ .name = "copy-mode-mark-style",
846 	  .type = OPTIONS_TABLE_STRING,
847 	  .scope = OPTIONS_TABLE_WINDOW,
848 	  .default_str = "bg=red,fg=black",
849 	  .flags = OPTIONS_TABLE_IS_STYLE,
850 	  .separator = ",",
851 	  .text = "Style of the marked line in copy mode."
852 	},
853 
854 	{ .name = "main-pane-height",
855 	  .type = OPTIONS_TABLE_STRING,
856 	  .scope = OPTIONS_TABLE_WINDOW,
857 	  .default_str = "24",
858 	  .text = "Height of the main pane in the 'main-horizontal' layout. "
859 		  "This may be a percentage, for example '10%'."
860 	},
861 
862 	{ .name = "main-pane-width",
863 	  .type = OPTIONS_TABLE_STRING,
864 	  .scope = OPTIONS_TABLE_WINDOW,
865 	  .default_str = "80",
866 	  .text = "Width of the main pane in the 'main-vertical' layout. "
867 		  "This may be a percentage, for example '10%'."
868 	},
869 
870 	{ .name = "mode-keys",
871 	  .type = OPTIONS_TABLE_CHOICE,
872 	  .scope = OPTIONS_TABLE_WINDOW,
873 	  .choices = options_table_mode_keys_list,
874 	  .default_num = MODEKEY_EMACS,
875 	  .text = "Key set used in copy mode."
876 	},
877 
878 	{ .name = "mode-style",
879 	  .type = OPTIONS_TABLE_STRING,
880 	  .scope = OPTIONS_TABLE_WINDOW,
881 	  .default_str = "bg=yellow,fg=black",
882 	  .flags = OPTIONS_TABLE_IS_STYLE,
883 	  .separator = ",",
884 	  .text = "Style of indicators and highlighting in modes."
885 	},
886 
887 	{ .name = "monitor-activity",
888 	  .type = OPTIONS_TABLE_FLAG,
889 	  .scope = OPTIONS_TABLE_WINDOW,
890 	  .default_num = 0,
891 	  .text = "Whether an alert is triggered by activity."
892 	},
893 
894 	{ .name = "monitor-bell",
895 	  .type = OPTIONS_TABLE_FLAG,
896 	  .scope = OPTIONS_TABLE_WINDOW,
897 	  .default_num = 1,
898 	  .text = "Whether an alert is triggered by a bell."
899 	},
900 
901 	{ .name = "monitor-silence",
902 	  .type = OPTIONS_TABLE_NUMBER,
903 	  .scope = OPTIONS_TABLE_WINDOW,
904 	  .minimum = 0,
905 	  .maximum = INT_MAX,
906 	  .default_num = 0,
907 	  .text = "Time after which an alert is triggered by silence. "
908 		  "Zero means no alert."
909 
910 	},
911 
912 	{ .name = "other-pane-height",
913 	  .type = OPTIONS_TABLE_STRING,
914 	  .scope = OPTIONS_TABLE_WINDOW,
915 	  .default_str = "0",
916 	  .text = "Height of the other panes in the 'main-horizontal' layout. "
917 		  "This may be a percentage, for example '10%'."
918 	},
919 
920 	{ .name = "other-pane-width",
921 	  .type = OPTIONS_TABLE_STRING,
922 	  .scope = OPTIONS_TABLE_WINDOW,
923 	  .default_str = "0",
924 	  .text = "Height of the other panes in the 'main-vertical' layout. "
925 		  "This may be a percentage, for example '10%'."
926 	},
927 
928 	{ .name = "pane-active-border-style",
929 	  .type = OPTIONS_TABLE_STRING,
930 	  .scope = OPTIONS_TABLE_WINDOW,
931 	  .default_str = "#{?pane_in_mode,fg=yellow,#{?synchronize-panes,fg=red,fg=green}}",
932 	  .flags = OPTIONS_TABLE_IS_STYLE,
933 	  .separator = ",",
934 	  .text = "Style of the active pane border."
935 	},
936 
937 	{ .name = "pane-base-index",
938 	  .type = OPTIONS_TABLE_NUMBER,
939 	  .scope = OPTIONS_TABLE_WINDOW,
940 	  .minimum = 0,
941 	  .maximum = USHRT_MAX,
942 	  .default_num = 0,
943 	  .text = "Index of the first pane in each window."
944 	},
945 
946 	{ .name = "pane-border-format",
947 	  .type = OPTIONS_TABLE_STRING,
948 	  .scope = OPTIONS_TABLE_WINDOW,
949 	  .default_str = "#{?pane_active,#[reverse],}#{pane_index}#[default] "
950 			 "\"#{pane_title}\"",
951 	  .text = "Format of text in the pane status lines."
952 	},
953 
954 	{ .name = "pane-border-lines",
955 	  .type = OPTIONS_TABLE_CHOICE,
956 	  .scope = OPTIONS_TABLE_WINDOW,
957 	  .choices = options_table_pane_border_lines_list,
958 	  .default_num = PANE_LINES_SINGLE,
959 	  .text = "Type of characters used to draw pane border lines. Some of "
960 	          "these are only supported on terminals with UTF-8 support."
961 	},
962 
963 	{ .name = "pane-border-status",
964 	  .type = OPTIONS_TABLE_CHOICE,
965 	  .scope = OPTIONS_TABLE_WINDOW,
966 	  .choices = options_table_pane_status_list,
967 	  .default_num = PANE_STATUS_OFF,
968 	  .text = "Position of the pane status lines."
969 	},
970 
971 	{ .name = "pane-border-style",
972 	  .type = OPTIONS_TABLE_STRING,
973 	  .scope = OPTIONS_TABLE_WINDOW,
974 	  .default_str = "default",
975 	  .flags = OPTIONS_TABLE_IS_STYLE,
976 	  .separator = ",",
977 	  .text = "Style of the pane status lines."
978 	},
979 
980 	{ .name = "pane-colours",
981 	  .type = OPTIONS_TABLE_COLOUR,
982 	  .scope = OPTIONS_TABLE_WINDOW|OPTIONS_TABLE_PANE,
983 	  .default_str = "",
984 	  .flags = OPTIONS_TABLE_IS_ARRAY,
985 	  .text = "The default colour palette for colours zero to 255."
986 	},
987 
988 	{ .name = "popup-style",
989 	  .type = OPTIONS_TABLE_STRING,
990 	  .scope = OPTIONS_TABLE_WINDOW,
991 	  .default_str = "default",
992 	  .flags = OPTIONS_TABLE_IS_STYLE,
993 	  .separator = ",",
994 	  .text = "Default style of popups."
995 	},
996 
997 	{ .name = "popup-border-style",
998 	  .type = OPTIONS_TABLE_STRING,
999 	  .scope = OPTIONS_TABLE_WINDOW,
1000 	  .default_str = "default",
1001 	  .flags = OPTIONS_TABLE_IS_STYLE,
1002 	  .separator = ",",
1003 	  .text = "Default style of popup borders."
1004 	},
1005 
1006 	{ .name = "popup-border-lines",
1007 	  .type = OPTIONS_TABLE_CHOICE,
1008 	  .scope = OPTIONS_TABLE_WINDOW,
1009 	  .choices = options_table_popup_border_lines_list,
1010 	  .default_num = BOX_LINES_SINGLE,
1011 	  .text = "Type of characters used to draw popup border lines. Some of "
1012 	          "these are only supported on terminals with UTF-8 support."
1013 	},
1014 
1015 	{ .name = "remain-on-exit",
1016 	  .type = OPTIONS_TABLE_CHOICE,
1017 	  .scope = OPTIONS_TABLE_WINDOW|OPTIONS_TABLE_PANE,
1018 	  .choices = options_table_remain_on_exit_list,
1019 	  .default_num = 0,
1020 	  .text = "Whether panes should remain ('on') or be automatically "
1021 		  "killed ('off' or 'failed') when the program inside exits."
1022 	},
1023 
1024 	{ .name = "synchronize-panes",
1025 	  .type = OPTIONS_TABLE_FLAG,
1026 	  .scope = OPTIONS_TABLE_WINDOW|OPTIONS_TABLE_PANE,
1027 	  .default_num = 0,
1028 	  .text = "Whether typing should be sent to all panes simultaneously."
1029 	},
1030 
1031 	{ .name = "window-active-style",
1032 	  .type = OPTIONS_TABLE_STRING,
1033 	  .scope = OPTIONS_TABLE_WINDOW|OPTIONS_TABLE_PANE,
1034 	  .default_str = "default",
1035 	  .flags = OPTIONS_TABLE_IS_STYLE,
1036 	  .separator = ",",
1037 	  .text = "Default style of the active pane."
1038 	},
1039 
1040 	{ .name = "window-size",
1041 	  .type = OPTIONS_TABLE_CHOICE,
1042 	  .scope = OPTIONS_TABLE_WINDOW,
1043 	  .choices = options_table_window_size_list,
1044 	  .default_num = WINDOW_SIZE_LATEST,
1045 	  .text = "How window size is calculated. "
1046 		  "'latest' uses the size of the most recently used client, "
1047 		  "'largest' the largest client, 'smallest' the smallest "
1048 		  "client and 'manual' a size set by the 'resize-window' "
1049 		  "command."
1050 	},
1051 
1052 	{ .name = "window-style",
1053 	  .type = OPTIONS_TABLE_STRING,
1054 	  .scope = OPTIONS_TABLE_WINDOW|OPTIONS_TABLE_PANE,
1055 	  .default_str = "default",
1056 	  .flags = OPTIONS_TABLE_IS_STYLE,
1057 	  .separator = ",",
1058 	  .text = "Default style of panes that are not the active pane."
1059 	},
1060 
1061 	{ .name = "window-status-activity-style",
1062 	  .type = OPTIONS_TABLE_STRING,
1063 	  .scope = OPTIONS_TABLE_WINDOW,
1064 	  .default_str = "reverse",
1065 	  .flags = OPTIONS_TABLE_IS_STYLE,
1066 	  .separator = ",",
1067 	  .text = "Style of windows in the status line with an activity alert."
1068 	},
1069 
1070 	{ .name = "window-status-bell-style",
1071 	  .type = OPTIONS_TABLE_STRING,
1072 	  .scope = OPTIONS_TABLE_WINDOW,
1073 	  .default_str = "reverse",
1074 	  .flags = OPTIONS_TABLE_IS_STYLE,
1075 	  .separator = ",",
1076 	  .text = "Style of windows in the status line with a bell alert."
1077 	},
1078 
1079 	{ .name = "window-status-current-format",
1080 	  .type = OPTIONS_TABLE_STRING,
1081 	  .scope = OPTIONS_TABLE_WINDOW,
1082 	  .default_str = "#I:#W#{?window_flags,#{window_flags}, }",
1083 	  .text = "Format of the current window in the status line."
1084 	},
1085 
1086 	{ .name = "window-status-current-style",
1087 	  .type = OPTIONS_TABLE_STRING,
1088 	  .scope = OPTIONS_TABLE_WINDOW,
1089 	  .default_str = "default",
1090 	  .flags = OPTIONS_TABLE_IS_STYLE,
1091 	  .separator = ",",
1092 	  .text = "Style of the current window in the status line."
1093 	},
1094 
1095 	{ .name = "window-status-format",
1096 	  .type = OPTIONS_TABLE_STRING,
1097 	  .scope = OPTIONS_TABLE_WINDOW,
1098 	  .default_str = "#I:#W#{?window_flags,#{window_flags}, }",
1099 	  .text = "Format of windows in the status line, except the current "
1100 		  "window."
1101 	},
1102 
1103 	{ .name = "window-status-last-style",
1104 	  .type = OPTIONS_TABLE_STRING,
1105 	  .scope = OPTIONS_TABLE_WINDOW,
1106 	  .default_str = "default",
1107 	  .flags = OPTIONS_TABLE_IS_STYLE,
1108 	  .separator = ",",
1109 	  .text = "Style of the last window in the status line."
1110 	},
1111 
1112 	{ .name = "window-status-separator",
1113 	  .type = OPTIONS_TABLE_STRING,
1114 	  .scope = OPTIONS_TABLE_WINDOW,
1115 	  .default_str = " ",
1116 	  .text = "Separator between windows in the status line."
1117 	},
1118 
1119 	{ .name = "window-status-style",
1120 	  .type = OPTIONS_TABLE_STRING,
1121 	  .scope = OPTIONS_TABLE_WINDOW,
1122 	  .default_str = "default",
1123 	  .flags = OPTIONS_TABLE_IS_STYLE,
1124 	  .separator = ",",
1125 	  .text = "Style of windows in the status line, except the current and "
1126 		  "last windows."
1127 	},
1128 
1129 	{ .name = "wrap-search",
1130 	  .type = OPTIONS_TABLE_FLAG,
1131 	  .scope = OPTIONS_TABLE_WINDOW,
1132 	  .default_num = 1,
1133 	  .text = "Whether searching in copy mode should wrap at the top or "
1134 		  "bottom."
1135 	},
1136 
1137 	{ .name = "xterm-keys", /* no longer used */
1138 	  .type = OPTIONS_TABLE_FLAG,
1139 	  .scope = OPTIONS_TABLE_WINDOW,
1140 	  .default_num = 1,
1141 	  .text = "Whether xterm-style function key sequences should be sent. "
1142 	          "This option is no longer used."
1143 	},
1144 
1145 	/* Hook options. */
1146 	OPTIONS_TABLE_HOOK("after-bind-key", ""),
1147 	OPTIONS_TABLE_HOOK("after-capture-pane", ""),
1148 	OPTIONS_TABLE_HOOK("after-copy-mode", ""),
1149 	OPTIONS_TABLE_HOOK("after-display-message", ""),
1150 	OPTIONS_TABLE_HOOK("after-display-panes", ""),
1151 	OPTIONS_TABLE_HOOK("after-kill-pane", ""),
1152 	OPTIONS_TABLE_HOOK("after-list-buffers", ""),
1153 	OPTIONS_TABLE_HOOK("after-list-clients", ""),
1154 	OPTIONS_TABLE_HOOK("after-list-keys", ""),
1155 	OPTIONS_TABLE_HOOK("after-list-panes", ""),
1156 	OPTIONS_TABLE_HOOK("after-list-sessions", ""),
1157 	OPTIONS_TABLE_HOOK("after-list-windows", ""),
1158 	OPTIONS_TABLE_HOOK("after-load-buffer", ""),
1159 	OPTIONS_TABLE_HOOK("after-lock-server", ""),
1160 	OPTIONS_TABLE_HOOK("after-new-session", ""),
1161 	OPTIONS_TABLE_HOOK("after-new-window", ""),
1162 	OPTIONS_TABLE_HOOK("after-paste-buffer", ""),
1163 	OPTIONS_TABLE_HOOK("after-pipe-pane", ""),
1164 	OPTIONS_TABLE_HOOK("after-queue", ""),
1165 	OPTIONS_TABLE_HOOK("after-refresh-client", ""),
1166 	OPTIONS_TABLE_HOOK("after-rename-session", ""),
1167 	OPTIONS_TABLE_HOOK("after-rename-window", ""),
1168 	OPTIONS_TABLE_HOOK("after-resize-pane", ""),
1169 	OPTIONS_TABLE_HOOK("after-resize-window", ""),
1170 	OPTIONS_TABLE_HOOK("after-save-buffer", ""),
1171 	OPTIONS_TABLE_HOOK("after-select-layout", ""),
1172 	OPTIONS_TABLE_HOOK("after-select-pane", ""),
1173 	OPTIONS_TABLE_HOOK("after-select-window", ""),
1174 	OPTIONS_TABLE_HOOK("after-send-keys", ""),
1175 	OPTIONS_TABLE_HOOK("after-set-buffer", ""),
1176 	OPTIONS_TABLE_HOOK("after-set-environment", ""),
1177 	OPTIONS_TABLE_HOOK("after-set-hook", ""),
1178 	OPTIONS_TABLE_HOOK("after-set-option", ""),
1179 	OPTIONS_TABLE_HOOK("after-show-environment", ""),
1180 	OPTIONS_TABLE_HOOK("after-show-messages", ""),
1181 	OPTIONS_TABLE_HOOK("after-show-options", ""),
1182 	OPTIONS_TABLE_HOOK("after-split-window", ""),
1183 	OPTIONS_TABLE_HOOK("after-unbind-key", ""),
1184 	OPTIONS_TABLE_HOOK("alert-activity", ""),
1185 	OPTIONS_TABLE_HOOK("alert-bell", ""),
1186 	OPTIONS_TABLE_HOOK("alert-silence", ""),
1187 	OPTIONS_TABLE_HOOK("client-active", ""),
1188 	OPTIONS_TABLE_HOOK("client-attached", ""),
1189 	OPTIONS_TABLE_HOOK("client-detached", ""),
1190  	OPTIONS_TABLE_HOOK("client-focus-in", ""),
1191  	OPTIONS_TABLE_HOOK("client-focus-out", ""),
1192 	OPTIONS_TABLE_HOOK("client-resized", ""),
1193 	OPTIONS_TABLE_HOOK("client-session-changed", ""),
1194 	OPTIONS_TABLE_PANE_HOOK("pane-died", ""),
1195 	OPTIONS_TABLE_PANE_HOOK("pane-exited", ""),
1196 	OPTIONS_TABLE_PANE_HOOK("pane-focus-in", ""),
1197 	OPTIONS_TABLE_PANE_HOOK("pane-focus-out", ""),
1198 	OPTIONS_TABLE_PANE_HOOK("pane-mode-changed", ""),
1199 	OPTIONS_TABLE_PANE_HOOK("pane-set-clipboard", ""),
1200 	OPTIONS_TABLE_PANE_HOOK("pane-title-changed", ""),
1201 	OPTIONS_TABLE_HOOK("session-closed", ""),
1202 	OPTIONS_TABLE_HOOK("session-created", ""),
1203 	OPTIONS_TABLE_HOOK("session-renamed", ""),
1204 	OPTIONS_TABLE_HOOK("session-window-changed", ""),
1205 	OPTIONS_TABLE_WINDOW_HOOK("window-layout-changed", ""),
1206 	OPTIONS_TABLE_HOOK("window-linked", ""),
1207 	OPTIONS_TABLE_WINDOW_HOOK("window-pane-changed", ""),
1208 	OPTIONS_TABLE_WINDOW_HOOK("window-renamed", ""),
1209 	OPTIONS_TABLE_HOOK("window-unlinked", ""),
1210 
1211 	{ .name = NULL }
1212 };
1213