make color of separators used in alternative user interface customizable
This commit is contained in:
@@ -304,6 +304,8 @@
|
||||
#
|
||||
#statusbar_color = "default"
|
||||
#
|
||||
#alternative_ui_separator_color = "black"
|
||||
#
|
||||
#active_column_color = "red"
|
||||
#
|
||||
#window_border_color = "green"
|
||||
|
||||
@@ -274,6 +274,9 @@ Color of progressbar.
|
||||
.B statusbar_color = COLOR
|
||||
Color of statusbar.
|
||||
.TP
|
||||
.B alternative_ui_separator_color = COLOR
|
||||
Color of separators used in alternative user interface.
|
||||
.TP
|
||||
.B active_column_color = COLOR
|
||||
Color of active column's highlight.
|
||||
.TP
|
||||
|
||||
@@ -237,7 +237,7 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
std::basic_string<my_char_t> title = myScreen->Title();
|
||||
*wHeader << XY(0, 3) << wclrtoeol;
|
||||
*wHeader << fmtBold << clBlack;
|
||||
*wHeader << fmtBold << Config.alternative_ui_separator_color;
|
||||
mvwhline(wHeader->Raw(), 2, 0, 0, COLS);
|
||||
mvwhline(wHeader->Raw(), 4, 0, 0, COLS);
|
||||
*wHeader << XY((COLS-Window::Length(title))/2, 3);
|
||||
@@ -267,7 +267,7 @@ int main(int argc, char *argv[])
|
||||
# endif // ENABLE_CLOCK
|
||||
if (Config.new_design)
|
||||
{
|
||||
*wHeader << fmtBold << clBlack;
|
||||
*wHeader << fmtBold << Config.alternative_ui_separator_color;
|
||||
mvwhline(wHeader->Raw(), 2, 0, 0, COLS);
|
||||
mvwhline(wHeader->Raw(), 4, 0, 0, COLS);
|
||||
*wHeader << clEnd << fmtBoldEnd;
|
||||
|
||||
@@ -269,6 +269,7 @@ void DefaultConfiguration(ncmpcpp_config &conf)
|
||||
conf.main_highlight_color = conf.main_color;
|
||||
conf.progressbar_color = clDefault;
|
||||
conf.statusbar_color = clDefault;
|
||||
conf.alternative_ui_separator_color = clBlack;
|
||||
conf.active_column_color = clRed;
|
||||
conf.window_border = brGreen;
|
||||
conf.active_window_border = brRed;
|
||||
@@ -884,6 +885,11 @@ void ReadConfiguration(ncmpcpp_config &conf)
|
||||
if (!v.empty())
|
||||
conf.statusbar_color = IntoColor(v);
|
||||
}
|
||||
else if (cl.find("alternative_ui_separator_color") != std::string::npos)
|
||||
{
|
||||
if (!v.empty())
|
||||
conf.alternative_ui_separator_color = IntoColor(v);
|
||||
}
|
||||
else if (cl.find("active_column_color") != std::string::npos)
|
||||
{
|
||||
if (!v.empty())
|
||||
|
||||
@@ -162,6 +162,7 @@ struct ncmpcpp_config
|
||||
Color main_highlight_color;
|
||||
Color progressbar_color;
|
||||
Color statusbar_color;
|
||||
Color alternative_ui_separator_color;
|
||||
Color active_column_color;
|
||||
|
||||
Border window_border;
|
||||
|
||||
Reference in New Issue
Block a user