Merge branch 'obsd-master'

This commit is contained in:
Thomas Adam
2025-03-04 10:01:15 +00:00
17 changed files with 382 additions and 107 deletions

View File

@ -1544,6 +1544,23 @@ format_cb_client_written(struct format_tree *ft)
return (NULL);
}
/* Callback for client_theme. */
static void *
format_cb_client_theme(struct format_tree *ft)
{
if (ft->c != NULL) {
switch (ft->c->theme) {
case THEME_DARK:
return (xstrdup("dark"));
case THEME_LIGHT:
return (xstrdup("light"));
case THEME_UNKNOWN:
return (NULL);
}
}
return (NULL);
}
/* Callback for config_files. */
static void *
format_cb_config_files(__unused struct format_tree *ft)
@ -2881,6 +2898,9 @@ static const struct format_table_entry format_table[] = {
{ "client_termtype", FORMAT_TABLE_STRING,
format_cb_client_termtype
},
{ "client_theme", FORMAT_TABLE_STRING,
format_cb_client_theme
},
{ "client_tty", FORMAT_TABLE_STRING,
format_cb_client_tty
},