mirror of
https://github.com/profanity-im/profanity.git
synced 2024-11-03 19:37:16 -05:00
Formatting of /theme properties command output
This commit is contained in:
parent
6ec3f71a54
commit
2df622f9fd
@ -1735,10 +1735,10 @@ static struct cmd_t command_defs[] =
|
||||
CMD_DESC(
|
||||
"Load a theme, includes colours and UI options.")
|
||||
CMD_ARGS(
|
||||
{ "list", "List all available themes." },
|
||||
{ "load <theme>", "Load the specified theme. 'default' will reset to the default theme." },
|
||||
{ "colours", "Show the colour values as rendered by the terminal." },
|
||||
{ "properties", "Show each themed property." })
|
||||
{ "list", "List all available themes." },
|
||||
{ "load <theme>", "Load the specified theme. 'default' will reset to the default theme." },
|
||||
{ "colours", "Show colour values as rendered by the terminal." },
|
||||
{ "properties", "Show colour settings for current theme." })
|
||||
CMD_EXAMPLES(
|
||||
"/theme list",
|
||||
"/theme load forest")
|
||||
|
@ -2010,25 +2010,44 @@ void
|
||||
_cons_theme_bar_prop(theme_item_t theme, char *prop)
|
||||
{
|
||||
ProfWin *console = wins_get_console();
|
||||
GString *str = g_string_new(" ");
|
||||
|
||||
GString *propstr = g_string_new(" ");
|
||||
g_string_append_printf(propstr, "%-24s", prop);
|
||||
win_print(console, '-', 0, NULL, NO_EOL, THEME_TEXT, "", propstr->str);
|
||||
g_string_free(propstr, TRUE);
|
||||
|
||||
GString *valstr = g_string_new(" ");
|
||||
char *setting = theme_get_string(prop);
|
||||
g_string_append_printf(str, "%-24s%s ", prop, setting);
|
||||
g_string_append_printf(valstr, "%s ", setting);
|
||||
theme_free_string(setting);
|
||||
win_print(console, '-', 0, NULL, NO_EOL, theme, "", str->str);
|
||||
win_print(console, '-', 0, NULL, NO_DATE | NO_EOL, theme, "", valstr->str);
|
||||
win_print(console, '-', 0, NULL, NO_DATE, THEME_TEXT, "", "");
|
||||
g_string_free(str, TRUE);
|
||||
g_string_free(valstr, TRUE);
|
||||
}
|
||||
|
||||
void
|
||||
_cons_theme_prop(theme_item_t theme, char *prop)
|
||||
{
|
||||
ProfWin *console = wins_get_console();
|
||||
GString *str = g_string_new(" ");
|
||||
|
||||
GString *propstr = g_string_new(" ");
|
||||
g_string_append_printf(propstr, "%-24s", prop);
|
||||
win_print(console, '-', 0, NULL, NO_EOL, THEME_TEXT, "", propstr->str);
|
||||
g_string_free(propstr, TRUE);
|
||||
|
||||
GString *valstr = g_string_new("");
|
||||
char *setting = theme_get_string(prop);
|
||||
g_string_append_printf(str, "%-24s%s", prop, setting);
|
||||
g_string_append_printf(valstr, "%s", setting);
|
||||
theme_free_string(setting);
|
||||
win_print(console, '-', 0, NULL, 0, theme, "", str->str);
|
||||
g_string_free(str, TRUE);
|
||||
win_print(console, '-', 0, NULL, NO_DATE, theme, "", valstr->str);
|
||||
g_string_free(valstr, TRUE);
|
||||
|
||||
// GString *str = g_string_new(" ");
|
||||
// char *setting = theme_get_string(prop);
|
||||
// g_string_append_printf(str, "%-24s%s", prop, setting);
|
||||
// theme_free_string(setting);
|
||||
// win_print(console, '-', 0, NULL, 0, theme, "", str->str);
|
||||
// g_string_free(str, TRUE);
|
||||
}
|
||||
|
||||
void
|
||||
|
66
themes/bios
66
themes/bios
@ -18,56 +18,56 @@ statusbar.text=black
|
||||
statusbar.brackets=black
|
||||
statusbar.active=black
|
||||
statusbar.new=black
|
||||
main.text=white
|
||||
main.text.me=cyan
|
||||
main.text=bold_white
|
||||
main.text.me=bold_white
|
||||
main.text.them=bold_white
|
||||
main.splash=bold_green
|
||||
main.time=black
|
||||
main.time=bold_green
|
||||
input.text=bold_white
|
||||
subscribed=bold_green
|
||||
unsubscribed=red
|
||||
otr.started.trusted=green
|
||||
otr.started.untrusted=yellow
|
||||
otr.ended=red
|
||||
otr.trusted=green
|
||||
otr.untrusted=yellow
|
||||
unsubscribed=bold_red
|
||||
otr.started.trusted=bold_green
|
||||
otr.started.untrusted=bold_yellow
|
||||
otr.ended=bold_red
|
||||
otr.trusted=bold_green
|
||||
otr.untrusted=bold_yellow
|
||||
online=bold_green
|
||||
away=bold_cyan
|
||||
chat=bold_white
|
||||
dnd=magenta
|
||||
xa=bold_blue
|
||||
offline=red
|
||||
dnd=bold_red
|
||||
xa=bold_cyan
|
||||
offline=bold_blue
|
||||
incoming=bold_yellow
|
||||
typing=yellow
|
||||
gone=red
|
||||
error=red
|
||||
roominfo=yellow
|
||||
roommention=bold_red
|
||||
me=blue
|
||||
them=bold_green
|
||||
roster.header=bold_yellow
|
||||
typing=bold_yellow
|
||||
gone=bold_red
|
||||
error=bold_red
|
||||
roominfo=bold_yellow
|
||||
roommention=bold_green
|
||||
me=bold_cyan
|
||||
them=bold_magenta
|
||||
roster.header=bold_magenta
|
||||
roster.chat=white
|
||||
roster.online=green
|
||||
roster.away=cyan
|
||||
roster.xa=blue
|
||||
roster.dnd=magenta
|
||||
roster.offline=red
|
||||
roster.xa=cyan
|
||||
roster.dnd=red
|
||||
roster.offline=bold_blue
|
||||
roster.chat.active=white
|
||||
roster.online.active=green
|
||||
roster.away.active=cyan
|
||||
roster.xa.active=blue
|
||||
roster.dnd.active=magenta
|
||||
roster.offline.active=red
|
||||
roster.xa.active=cyan
|
||||
roster.dnd.active=red
|
||||
roster.offline.active=bold_blue
|
||||
roster.chat.unread=bold_white
|
||||
roster.online.unread=bold_green
|
||||
roster.away.unread=bold_cyan
|
||||
roster.xa.unread=bold_blue
|
||||
roster.dnd.unread=bold_magenta
|
||||
roster.offline.unread=bold_red
|
||||
roster.room=green
|
||||
roster.room.unread=bold_green
|
||||
occupants.header=bold_yellow
|
||||
receipt.sent=bold_black
|
||||
roster.xa.unread=bold_cyan
|
||||
roster.dnd.unread=bold_red
|
||||
roster.offline.unread=bold_blue
|
||||
roster.room=bold_red
|
||||
roster.room.unread=bold_magenta
|
||||
occupants.header=bold_magenta
|
||||
receipt.sent=bold_blue
|
||||
|
||||
[ui]
|
||||
beep=false
|
||||
|
Loading…
Reference in New Issue
Block a user