[BACK]Return to options-table.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / tmux

Annotation of src/usr.bin/tmux/options-table.c, Revision 1.94

1.94    ! nicm        1: /* $OpenBSD: options-table.c,v 1.93 2017/08/17 08:37:38 nicm Exp $ */
1.1       nicm        2:
                      3: /*
1.71      nicm        4:  * Copyright (c) 2011 Nicholas Marriott <nicholas.marriott@gmail.com>
1.1       nicm        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
1.49      nicm       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.
1.1       nicm       33:  */
                     34:
                     35: /* Choice option type lists. */
1.74      nicm       36: static const char *options_table_mode_keys_list[] = {
1.1       nicm       37:        "emacs", "vi", NULL
                     38: };
1.74      nicm       39: static const char *options_table_clock_mode_style_list[] = {
1.1       nicm       40:        "12", "24", NULL
                     41: };
1.74      nicm       42: static const char *options_table_status_keys_list[] = {
1.1       nicm       43:        "emacs", "vi", NULL
                     44: };
1.74      nicm       45: static const char *options_table_status_justify_list[] = {
1.1       nicm       46:        "left", "centre", "right", NULL
                     47: };
1.74      nicm       48: static const char *options_table_status_position_list[] = {
1.20      nicm       49:        "top", "bottom", NULL
                     50: };
1.74      nicm       51: static const char *options_table_bell_action_list[] = {
1.59      nicm       52:        "none", "any", "current", "other", NULL
1.1       nicm       53: };
1.91      nicm       54: static const char *options_table_visual_bell_list[] = {
                     55:        "off", "on", "both", NULL
                     56: };
1.74      nicm       57: static const char *options_table_pane_status_list[] = {
1.72      nicm       58:        "off", "top", "bottom", NULL
                     59: };
1.89      nicm       60: static const char *options_table_set_clipboard_list[] = {
                     61:        "off", "external", "on", NULL
                     62: };
1.1       nicm       63:
1.80      nicm       64: /* Top-level options. */
1.67      nicm       65: const struct options_table_entry options_table[] = {
1.1       nicm       66:        { .name = "buffer-limit",
                     67:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm       68:          .scope = OPTIONS_TABLE_SERVER,
1.1       nicm       69:          .minimum = 1,
                     70:          .maximum = INT_MAX,
1.88      nicm       71:          .default_num = 50
1.83      nicm       72:        },
                     73:
                     74:        { .name = "command-alias",
                     75:          .type = OPTIONS_TABLE_ARRAY,
                     76:          .scope = OPTIONS_TABLE_SERVER,
                     77:          .default_str = "split-pane=split-window,"
1.84      nicm       78:                         "splitp=split-window,"
                     79:                         "server-info=show-messages -JT,"
1.88      nicm       80:                         "info=show-messages -JT,"
                     81:                         "choose-window=choose-tree -w,"
                     82:                         "choose-session=choose-tree -s",
1.84      nicm       83:          .separator = ","
1.81      nicm       84:        },
                     85:
1.56      nicm       86:        { .name = "default-terminal",
                     87:          .type = OPTIONS_TABLE_STRING,
1.67      nicm       88:          .scope = OPTIONS_TABLE_SERVER,
1.56      nicm       89:          .default_str = "screen"
                     90:        },
                     91:
1.1       nicm       92:        { .name = "escape-time",
                     93:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm       94:          .scope = OPTIONS_TABLE_SERVER,
1.1       nicm       95:          .minimum = 0,
                     96:          .maximum = INT_MAX,
                     97:          .default_num = 500
                     98:        },
                     99:
                    100:        { .name = "exit-unattached",
1.38      nicm      101:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      102:          .scope = OPTIONS_TABLE_SERVER,
1.38      nicm      103:          .default_num = 0
                    104:        },
                    105:
                    106:        { .name = "focus-events",
1.1       nicm      107:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      108:          .scope = OPTIONS_TABLE_SERVER,
1.1       nicm      109:          .default_num = 0
1.61      nicm      110:        },
                    111:
                    112:        { .name = "history-file",
                    113:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      114:          .scope = OPTIONS_TABLE_SERVER,
1.65      nicm      115:          .default_str = ""
1.1       nicm      116:        },
                    117:
1.46      nicm      118:        { .name = "message-limit",
                    119:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      120:          .scope = OPTIONS_TABLE_SERVER,
1.46      nicm      121:          .minimum = 0,
                    122:          .maximum = INT_MAX,
                    123:          .default_num = 100
1.1       nicm      124:        },
                    125:
1.8       nicm      126:        { .name = "set-clipboard",
1.89      nicm      127:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      128:          .scope = OPTIONS_TABLE_SERVER,
1.89      nicm      129:          .choices = options_table_set_clipboard_list,
1.8       nicm      130:          .default_num = 1
                    131:        },
                    132:
1.45      nicm      133:        { .name = "terminal-overrides",
1.85      nicm      134:          .type = OPTIONS_TABLE_ARRAY,
1.67      nicm      135:          .scope = OPTIONS_TABLE_SERVER,
1.63      nicm      136:          .default_str = "xterm*:XT:Ms=\\E]52;%p1%s;%p2%s\\007"
1.87      nicm      137:                         ":Cs=\\E]12;%p1%s\\007:Cr=\\E]112\\007"
1.85      nicm      138:                         ":Ss=\\E[%p1%d q:Se=\\E[2 q,screen*:XT",
1.90      nicm      139:          .separator = ","
                    140:        },
                    141:
                    142:        { .name = "user-keys",
                    143:          .type = OPTIONS_TABLE_ARRAY,
                    144:          .scope = OPTIONS_TABLE_SERVER,
                    145:          .default_str = "",
1.85      nicm      146:          .separator = ","
1.45      nicm      147:        },
                    148:
1.91      nicm      149:        { .name = "activity-action",
                    150:          .type = OPTIONS_TABLE_CHOICE,
                    151:          .scope = OPTIONS_TABLE_SESSION,
                    152:          .choices = options_table_bell_action_list,
1.92      nicm      153:          .default_num = ALERT_OTHER
1.91      nicm      154:        },
                    155:
1.31      nicm      156:        { .name = "assume-paste-time",
                    157:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      158:          .scope = OPTIONS_TABLE_SESSION,
1.31      nicm      159:          .minimum = 0,
                    160:          .maximum = INT_MAX,
                    161:          .default_num = 1,
                    162:        },
                    163:
1.1       nicm      164:        { .name = "base-index",
                    165:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      166:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      167:          .minimum = 0,
                    168:          .maximum = INT_MAX,
                    169:          .default_num = 0
                    170:        },
                    171:
                    172:        { .name = "bell-action",
                    173:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      174:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      175:          .choices = options_table_bell_action_list,
1.92      nicm      176:          .default_num = ALERT_ANY
1.11      nicm      177:        },
                    178:
1.1       nicm      179:        { .name = "default-command",
                    180:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      181:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      182:          .default_str = ""
                    183:        },
                    184:
                    185:        { .name = "default-shell",
                    186:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      187:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      188:          .default_str = _PATH_BSHELL
                    189:        },
                    190:
                    191:        { .name = "destroy-unattached",
                    192:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      193:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      194:          .default_num = 0
                    195:        },
                    196:
                    197:        { .name = "detach-on-destroy",
                    198:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      199:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      200:          .default_num = 1
                    201:        },
                    202:
                    203:        { .name = "display-panes-active-colour",
                    204:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      205:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      206:          .default_num = 1
                    207:        },
                    208:
                    209:        { .name = "display-panes-colour",
                    210:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      211:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      212:          .default_num = 4
                    213:        },
                    214:
                    215:        { .name = "display-panes-time",
                    216:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      217:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      218:          .minimum = 1,
                    219:          .maximum = INT_MAX,
                    220:          .default_num = 1000
                    221:        },
                    222:
                    223:        { .name = "display-time",
                    224:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      225:          .scope = OPTIONS_TABLE_SESSION,
1.68      tim       226:          .minimum = 0,
1.1       nicm      227:          .maximum = INT_MAX,
                    228:          .default_num = 750
                    229:        },
                    230:
                    231:        { .name = "history-limit",
                    232:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      233:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      234:          .minimum = 0,
1.3       nicm      235:          .maximum = INT_MAX,
1.1       nicm      236:          .default_num = 2000
1.70      nicm      237:        },
                    238:
                    239:        { .name = "key-table",
                    240:          .type = OPTIONS_TABLE_STRING,
                    241:          .scope = OPTIONS_TABLE_SESSION,
                    242:          .default_str = "root"
1.1       nicm      243:        },
                    244:
                    245:        { .name = "lock-after-time",
                    246:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      247:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      248:          .minimum = 0,
                    249:          .maximum = INT_MAX,
                    250:          .default_num = 0
                    251:        },
                    252:
                    253:        { .name = "lock-command",
                    254:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      255:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      256:          .default_str = "lock -np"
                    257:        },
                    258:
                    259:        { .name = "message-attr",
                    260:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      261:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      262:          .default_num = 0,
                    263:          .style = "message-style"
1.1       nicm      264:        },
                    265:
                    266:        { .name = "message-bg",
1.15      nicm      267:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      268:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      269:          .default_num = 3,
                    270:          .style = "message-style"
1.15      nicm      271:        },
                    272:
                    273:        { .name = "message-command-attr",
                    274:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      275:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      276:          .default_num = 0,
                    277:          .style = "message-command-style"
1.15      nicm      278:        },
                    279:
                    280:        { .name = "message-command-bg",
                    281:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      282:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      283:          .default_num = 0,
                    284:          .style = "message-command-style"
1.15      nicm      285:        },
                    286:
                    287:        { .name = "message-command-fg",
1.1       nicm      288:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      289:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      290:          .default_num = 3,
                    291:          .style = "message-command-style"
                    292:        },
                    293:
                    294:        { .name = "message-command-style",
                    295:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      296:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      297:          .default_str = "bg=black,fg=yellow"
1.1       nicm      298:        },
                    299:
                    300:        { .name = "message-fg",
                    301:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      302:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      303:          .default_num = 0,
                    304:          .style = "message-style"
1.7       nicm      305:        },
                    306:
1.43      nicm      307:        { .name = "message-style",
                    308:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      309:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      310:          .default_str = "bg=yellow,fg=black"
                    311:        },
                    312:
1.55      nicm      313:        { .name = "mouse",
1.1       nicm      314:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      315:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      316:          .default_num = 0
                    317:        },
                    318:
                    319:        { .name = "prefix",
1.19      nicm      320:          .type = OPTIONS_TABLE_KEY,
1.67      nicm      321:          .scope = OPTIONS_TABLE_SESSION,
1.19      nicm      322:          .default_num = '\002',
                    323:        },
                    324:
                    325:        { .name = "prefix2",
                    326:          .type = OPTIONS_TABLE_KEY,
1.67      nicm      327:          .scope = OPTIONS_TABLE_SESSION,
1.19      nicm      328:          .default_num = KEYC_NONE,
1.29      nicm      329:        },
                    330:
                    331:        { .name = "renumber-windows",
                    332:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      333:          .scope = OPTIONS_TABLE_SESSION,
1.29      nicm      334:          .default_num = 0
1.1       nicm      335:        },
                    336:
                    337:        { .name = "repeat-time",
                    338:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      339:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      340:          .minimum = 0,
                    341:          .maximum = SHRT_MAX,
                    342:          .default_num = 500
                    343:        },
                    344:
                    345:        { .name = "set-titles",
                    346:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      347:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      348:          .default_num = 0
                    349:        },
                    350:
                    351:        { .name = "set-titles-string",
                    352:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      353:          .scope = OPTIONS_TABLE_SESSION,
1.60      nicm      354:          .default_str = "#S:#I:#W - \"#T\" #{session_alerts}"
1.1       nicm      355:        },
                    356:
1.91      nicm      357:        { .name = "silence-action",
                    358:          .type = OPTIONS_TABLE_CHOICE,
                    359:          .scope = OPTIONS_TABLE_SESSION,
                    360:          .choices = options_table_bell_action_list,
1.92      nicm      361:          .default_num = ALERT_OTHER
1.91      nicm      362:        },
                    363:
1.1       nicm      364:        { .name = "status",
                    365:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      366:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      367:          .default_num = 1
                    368:        },
                    369:
                    370:        { .name = "status-attr",
                    371:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      372:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      373:          .default_num = 0,
                    374:          .style = "status-style"
1.1       nicm      375:        },
                    376:
                    377:        { .name = "status-bg",
                    378:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      379:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      380:          .default_num = 2,
                    381:          .style = "status-style"
1.1       nicm      382:        },
                    383:
                    384:        { .name = "status-fg",
                    385:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      386:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      387:          .default_num = 0,
                    388:          .style = "status-style"
1.1       nicm      389:        },
                    390:
                    391:        { .name = "status-interval",
                    392:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      393:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      394:          .minimum = 0,
                    395:          .maximum = INT_MAX,
                    396:          .default_num = 15
                    397:        },
                    398:
                    399:        { .name = "status-justify",
                    400:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      401:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      402:          .choices = options_table_status_justify_list,
                    403:          .default_num = 0
                    404:        },
                    405:
                    406:        { .name = "status-keys",
                    407:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      408:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      409:          .choices = options_table_status_keys_list,
                    410:          .default_num = MODEKEY_EMACS
                    411:        },
                    412:
                    413:        { .name = "status-left",
                    414:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      415:          .scope = OPTIONS_TABLE_SESSION,
1.51      nicm      416:          .default_str = "[#S] "
1.1       nicm      417:        },
                    418:
                    419:        { .name = "status-left-attr",
                    420:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      421:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      422:          .default_num = 0,
                    423:          .style = "status-left-style"
1.1       nicm      424:        },
                    425:
                    426:        { .name = "status-left-bg",
                    427:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      428:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      429:          .default_num = 8,
                    430:          .style = "status-left-style"
1.1       nicm      431:        },
                    432:
                    433:        { .name = "status-left-fg",
                    434:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      435:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      436:          .default_num = 8,
                    437:          .style = "status-left-style"
1.1       nicm      438:        },
                    439:
                    440:        { .name = "status-left-length",
                    441:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      442:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      443:          .minimum = 0,
                    444:          .maximum = SHRT_MAX,
                    445:          .default_num = 10
1.20      nicm      446:        },
                    447:
1.43      nicm      448:        { .name = "status-left-style",
                    449:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      450:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      451:          .default_str = "default"
                    452:        },
                    453:
1.20      nicm      454:        { .name = "status-position",
                    455:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      456:          .scope = OPTIONS_TABLE_SESSION,
1.20      nicm      457:          .choices = options_table_status_position_list,
                    458:          .default_num = 1
1.1       nicm      459:        },
                    460:
                    461:        { .name = "status-right",
                    462:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      463:          .scope = OPTIONS_TABLE_SESSION,
1.52      sthen     464:          .default_str = " \"#{=21:pane_title}\" %H:%M %d-%b-%y"
1.1       nicm      465:        },
                    466:
                    467:        { .name = "status-right-attr",
                    468:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      469:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      470:          .default_num = 0,
                    471:          .style = "status-right-style"
1.1       nicm      472:        },
                    473:
                    474:        { .name = "status-right-bg",
                    475:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      476:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      477:          .default_num = 8,
                    478:          .style = "status-right-style"
1.1       nicm      479:        },
                    480:
                    481:        { .name = "status-right-fg",
                    482:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      483:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      484:          .default_num = 8,
                    485:          .style = "status-right-style"
1.1       nicm      486:        },
                    487:
                    488:        { .name = "status-right-length",
                    489:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      490:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      491:          .minimum = 0,
                    492:          .maximum = SHRT_MAX,
                    493:          .default_num = 40
                    494:        },
                    495:
1.43      nicm      496:        { .name = "status-right-style",
                    497:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      498:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      499:          .default_str = "default"
                    500:        },
                    501:
                    502:        { .name = "status-style",
                    503:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      504:          .scope = OPTIONS_TABLE_SESSION,
1.43      nicm      505:          .default_str = "bg=green,fg=black"
                    506:        },
                    507:
1.1       nicm      508:        { .name = "update-environment",
1.86      nicm      509:          .type = OPTIONS_TABLE_ARRAY,
1.67      nicm      510:          .scope = OPTIONS_TABLE_SESSION,
1.1       nicm      511:          .default_str = "DISPLAY SSH_ASKPASS SSH_AUTH_SOCK SSH_AGENT_PID "
1.87      nicm      512:                         "SSH_CONNECTION WINDOWID XAUTHORITY"
1.1       nicm      513:        },
                    514:
                    515:        { .name = "visual-activity",
1.91      nicm      516:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      517:          .scope = OPTIONS_TABLE_SESSION,
1.91      nicm      518:          .choices = options_table_visual_bell_list,
                    519:          .default_num = VISUAL_OFF
1.1       nicm      520:        },
                    521:
                    522:        { .name = "visual-bell",
1.91      nicm      523:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      524:          .scope = OPTIONS_TABLE_SESSION,
1.91      nicm      525:          .choices = options_table_visual_bell_list,
                    526:          .default_num = VISUAL_OFF
1.1       nicm      527:        },
                    528:
                    529:        { .name = "visual-silence",
1.91      nicm      530:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      531:          .scope = OPTIONS_TABLE_SESSION,
1.91      nicm      532:          .choices = options_table_visual_bell_list,
                    533:          .default_num = VISUAL_OFF
1.1       nicm      534:        },
                    535:
1.16      nicm      536:        { .name = "word-separators",
                    537:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      538:          .scope = OPTIONS_TABLE_SESSION,
1.16      nicm      539:          .default_str = " -_@"
                    540:        },
                    541:
1.1       nicm      542:        { .name = "aggressive-resize",
                    543:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      544:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      545:          .default_num = 0
1.17      nicm      546:        },
                    547:
                    548:        { .name = "allow-rename",
                    549:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      550:          .scope = OPTIONS_TABLE_WINDOW,
1.94    ! nicm      551:          .default_num = 0
1.1       nicm      552:        },
                    553:
                    554:        { .name = "alternate-screen",
                    555:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      556:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      557:          .default_num = 1
                    558:        },
                    559:
                    560:        { .name = "automatic-rename",
                    561:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      562:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      563:          .default_num = 1
1.41      nicm      564:        },
                    565:
                    566:        { .name = "automatic-rename-format",
                    567:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      568:          .scope = OPTIONS_TABLE_WINDOW,
1.50      nicm      569:          .default_str = "#{?pane_in_mode,[tmux],#{pane_current_command}}"
1.87      nicm      570:                         "#{?pane_dead,[dead],}"
1.1       nicm      571:        },
                    572:
                    573:        { .name = "clock-mode-colour",
                    574:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      575:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      576:          .default_num = 4
                    577:        },
                    578:
                    579:        { .name = "clock-mode-style",
                    580:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      581:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      582:          .choices = options_table_clock_mode_style_list,
                    583:          .default_num = 1
                    584:        },
                    585:
                    586:        { .name = "force-height",
                    587:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      588:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      589:          .minimum = 0,
                    590:          .maximum = INT_MAX,
                    591:          .default_num = 0
                    592:        },
                    593:
                    594:        { .name = "force-width",
                    595:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      596:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      597:          .minimum = 0,
                    598:          .maximum = INT_MAX,
                    599:          .default_num = 0
                    600:        },
                    601:
                    602:        { .name = "main-pane-height",
                    603:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      604:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      605:          .minimum = 1,
                    606:          .maximum = INT_MAX,
                    607:          .default_num = 24
                    608:        },
                    609:
                    610:        { .name = "main-pane-width",
                    611:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      612:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      613:          .minimum = 1,
                    614:          .maximum = INT_MAX,
                    615:          .default_num = 80
                    616:        },
                    617:
                    618:        { .name = "mode-attr",
                    619:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      620:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      621:          .default_num = 0,
                    622:          .style = "mode-style"
1.1       nicm      623:        },
                    624:
                    625:        { .name = "mode-bg",
                    626:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      627:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      628:          .default_num = 3,
                    629:          .style = "mode-style"
1.1       nicm      630:        },
                    631:
                    632:        { .name = "mode-fg",
                    633:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      634:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      635:          .default_num = 0,
                    636:          .style = "mode-style"
1.1       nicm      637:        },
                    638:
                    639:        { .name = "mode-keys",
                    640:          .type = OPTIONS_TABLE_CHOICE,
1.67      nicm      641:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      642:          .choices = options_table_mode_keys_list,
                    643:          .default_num = MODEKEY_EMACS
                    644:        },
                    645:
1.43      nicm      646:        { .name = "mode-style",
                    647:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      648:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      649:          .default_str = "bg=yellow,fg=black"
                    650:        },
                    651:
1.1       nicm      652:        { .name = "monitor-activity",
                    653:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      654:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      655:          .default_num = 0
1.93      nicm      656:        },
                    657:
                    658:        { .name = "monitor-bell",
                    659:          .type = OPTIONS_TABLE_FLAG,
                    660:          .scope = OPTIONS_TABLE_WINDOW,
                    661:          .default_num = 1
1.1       nicm      662:        },
                    663:
                    664:        { .name = "monitor-silence",
                    665:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      666:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      667:          .minimum = 0,
                    668:          .maximum = INT_MAX,
                    669:          .default_num = 0
                    670:        },
                    671:
                    672:        { .name = "other-pane-height",
                    673:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      674:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      675:          .minimum = 0,
                    676:          .maximum = INT_MAX,
                    677:          .default_num = 0
                    678:        },
                    679:
                    680:        { .name = "other-pane-width",
                    681:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      682:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      683:          .minimum = 0,
                    684:          .maximum = INT_MAX,
1.13      nicm      685:          .default_num = 0
                    686:        },
                    687:
1.53      nicm      688:        { .name = "pane-active-border-bg",
                    689:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      690:          .scope = OPTIONS_TABLE_WINDOW,
1.53      nicm      691:          .default_num = 8,
                    692:          .style = "pane-active-border-style"
                    693:        },
                    694:
                    695:        { .name = "pane-active-border-fg",
                    696:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      697:          .scope = OPTIONS_TABLE_WINDOW,
1.53      nicm      698:          .default_num = 2,
                    699:          .style = "pane-active-border-style"
                    700:        },
                    701:
                    702:        { .name = "pane-active-border-style",
                    703:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      704:          .scope = OPTIONS_TABLE_WINDOW,
1.53      nicm      705:          .default_str = "fg=green"
                    706:        },
                    707:
1.13      nicm      708:        { .name = "pane-base-index",
                    709:          .type = OPTIONS_TABLE_NUMBER,
1.67      nicm      710:          .scope = OPTIONS_TABLE_WINDOW,
1.13      nicm      711:          .minimum = 0,
                    712:          .maximum = USHRT_MAX,
1.22      nicm      713:          .default_num = 0
1.53      nicm      714:        },
                    715:
                    716:        { .name = "pane-border-bg",
                    717:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      718:          .scope = OPTIONS_TABLE_WINDOW,
1.53      nicm      719:          .default_num = 8,
                    720:          .style = "pane-border-style"
                    721:        },
                    722:
                    723:        { .name = "pane-border-fg",
                    724:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      725:          .scope = OPTIONS_TABLE_WINDOW,
1.53      nicm      726:          .default_num = 8,
                    727:          .style = "pane-border-style"
1.72      nicm      728:        },
                    729:
                    730:        { .name = "pane-border-format",
                    731:          .type = OPTIONS_TABLE_STRING,
                    732:          .scope = OPTIONS_TABLE_WINDOW,
1.73      nicm      733:          .default_str = "#{?pane_active,#[reverse],}#{pane_index}#[default] "
1.87      nicm      734:                         "\"#{pane_title}\""
1.72      nicm      735:        },
                    736:
                    737:        { .name = "pane-border-status",
                    738:          .type = OPTIONS_TABLE_CHOICE,
                    739:          .scope = OPTIONS_TABLE_WINDOW,
                    740:          .choices = options_table_pane_status_list,
                    741:          .default_num = 0
1.53      nicm      742:        },
                    743:
                    744:        { .name = "pane-border-style",
                    745:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      746:          .scope = OPTIONS_TABLE_WINDOW,
1.53      nicm      747:          .default_str = "default"
1.22      nicm      748:        },
                    749:
1.1       nicm      750:        { .name = "remain-on-exit",
                    751:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      752:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      753:          .default_num = 0
                    754:        },
                    755:
                    756:        { .name = "synchronize-panes",
                    757:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      758:          .scope = OPTIONS_TABLE_WINDOW,
1.1       nicm      759:          .default_num = 0
1.54      nicm      760:        },
                    761:
                    762:        { .name = "window-active-style",
                    763:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      764:          .scope = OPTIONS_TABLE_WINDOW,
1.54      nicm      765:          .default_str = "default"
                    766:        },
                    767:
                    768:        { .name = "window-style",
                    769:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      770:          .scope = OPTIONS_TABLE_WINDOW,
1.54      nicm      771:          .default_str = "default"
1.1       nicm      772:        },
                    773:
1.21      nicm      774:        { .name = "window-status-activity-attr",
1.1       nicm      775:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      776:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      777:          .default_num = GRID_ATTR_REVERSE,
                    778:          .style = "window-status-activity-style"
1.1       nicm      779:        },
                    780:
1.21      nicm      781:        { .name = "window-status-activity-bg",
1.1       nicm      782:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      783:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      784:          .default_num = 8,
                    785:          .style = "window-status-activity-style"
1.1       nicm      786:        },
                    787:
1.21      nicm      788:        { .name = "window-status-activity-fg",
1.18      nicm      789:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      790:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      791:          .default_num = 8,
                    792:          .style = "window-status-activity-style"
                    793:        },
                    794:
                    795:        { .name = "window-status-activity-style",
                    796:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      797:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      798:          .default_str = "reverse"
                    799:        },
                    800:
                    801:        { .name = "window-status-attr",
                    802:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      803:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      804:          .default_num = 0,
                    805:          .style = "window-status-style"
1.18      nicm      806:        },
                    807:
1.21      nicm      808:        { .name = "window-status-bell-attr",
1.18      nicm      809:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      810:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      811:          .default_num = GRID_ATTR_REVERSE,
                    812:          .style = "window-status-bell-style"
1.18      nicm      813:        },
                    814:
1.21      nicm      815:        { .name = "window-status-bell-bg",
1.18      nicm      816:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      817:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      818:          .default_num = 8,
                    819:          .style = "window-status-bell-style"
1.18      nicm      820:        },
                    821:
1.21      nicm      822:        { .name = "window-status-bell-fg",
1.18      nicm      823:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      824:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      825:          .default_num = 8,
                    826:          .style = "window-status-bell-style"
                    827:        },
                    828:
                    829:        { .name = "window-status-bell-style",
                    830:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      831:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      832:          .default_str = "reverse"
                    833:        },
                    834:
                    835:        { .name = "window-status-bg",
                    836:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      837:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      838:          .default_num = 8,
                    839:          .style = "window-status-style"
1.1       nicm      840:        },
                    841:
                    842:        { .name = "window-status-current-attr",
                    843:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      844:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      845:          .default_num = 0,
                    846:          .style = "window-status-current-style"
1.1       nicm      847:        },
                    848:
                    849:        { .name = "window-status-current-bg",
                    850:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      851:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      852:          .default_num = 8,
                    853:          .style = "window-status-current-style"
1.1       nicm      854:        },
                    855:
                    856:        { .name = "window-status-current-fg",
                    857:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      858:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      859:          .default_num = 8,
                    860:          .style = "window-status-current-style"
1.1       nicm      861:        },
                    862:
                    863:        { .name = "window-status-current-format",
                    864:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      865:          .scope = OPTIONS_TABLE_WINDOW,
1.57      nicm      866:          .default_str = "#I:#W#{?window_flags,#{window_flags}, }"
1.30      nicm      867:        },
                    868:
1.43      nicm      869:        { .name = "window-status-current-style",
                    870:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      871:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      872:          .default_str = "default"
                    873:        },
                    874:
                    875:        { .name = "window-status-fg",
                    876:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      877:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      878:          .default_num = 8,
                    879:          .style = "window-status-style"
                    880:        },
                    881:
                    882:        { .name = "window-status-format",
                    883:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      884:          .scope = OPTIONS_TABLE_WINDOW,
1.57      nicm      885:          .default_str = "#I:#W#{?window_flags,#{window_flags}, }"
1.43      nicm      886:        },
                    887:
1.30      nicm      888:        { .name = "window-status-last-attr",
                    889:          .type = OPTIONS_TABLE_ATTRIBUTES,
1.67      nicm      890:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      891:          .default_num = 0,
                    892:          .style = "window-status-last-style"
1.30      nicm      893:        },
                    894:
                    895:        { .name = "window-status-last-bg",
                    896:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      897:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      898:          .default_num = 8,
                    899:          .style = "window-status-last-style"
1.30      nicm      900:        },
                    901:
                    902:        { .name = "window-status-last-fg",
                    903:          .type = OPTIONS_TABLE_COLOUR,
1.67      nicm      904:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      905:          .default_num = 8,
                    906:          .style = "window-status-last-style"
1.1       nicm      907:        },
                    908:
1.43      nicm      909:        { .name = "window-status-last-style",
                    910:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      911:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      912:          .default_str = "default"
1.1       nicm      913:        },
                    914:
1.43      nicm      915:        { .name = "window-status-separator",
1.1       nicm      916:          .type = OPTIONS_TABLE_STRING,
1.67      nicm      917:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      918:          .default_str = " "
1.28      nicm      919:        },
                    920:
1.43      nicm      921:        { .name = "window-status-style",
                    922:          .type = OPTIONS_TABLE_STYLE,
1.67      nicm      923:          .scope = OPTIONS_TABLE_WINDOW,
1.43      nicm      924:          .default_str = "default"
1.24      nicm      925:        },
                    926:
                    927:        { .name = "wrap-search",
                    928:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      929:          .scope = OPTIONS_TABLE_WINDOW,
1.24      nicm      930:          .default_num = 1
1.1       nicm      931:        },
                    932:
                    933:        { .name = "xterm-keys",
                    934:          .type = OPTIONS_TABLE_FLAG,
1.67      nicm      935:          .scope = OPTIONS_TABLE_WINDOW,
1.76      nicm      936:          .default_num = 1
1.1       nicm      937:        },
                    938:
                    939:        { .name = NULL }
                    940: };