Change theme handling

So far when loading a theme it also overwrote the preferences the user
set.

Lengthy discussion can be found at
https://github.com/profanity-im/profanity/issues/1077

Now we use `/theme load themename` to load the [colours] part of a
themem only.

`/theme full-load themename` will load the complete theme including
preferences set in there.

Regards https://github.com/profanity-im/profanity/issues/1077
This commit is contained in:
Michael Vetter
2020-01-29 12:33:55 +01:00
parent 5c41c5b380
commit cd80b6cbf2
6 changed files with 51 additions and 17 deletions

View File

@@ -2136,15 +2136,17 @@ static struct cmd_t command_defs[] =
CMD_SYN(
"/theme list",
"/theme load <theme>",
"/theme full-load <theme>",
"/theme colours",
"/theme properties")
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 colour values as rendered by the terminal." },
{ "properties", "Show colour settings for current theme." })
{ "list", "List all available themes." },
{ "load <theme>", "Load colours from specified theme. 'default' will reset to the default theme." },
{ "full-load <theme>", "Same as 'load' but will also load preferences set in the theme, not just colours." },
{ "colours", "Show colour values as rendered by the terminal." },
{ "properties", "Show colour settings for current theme." })
CMD_EXAMPLES(
"/theme list",
"/theme load forest")