From fcdcd32de7118e1de1f8d94c380a0e80a64265ec Mon Sep 17 00:00:00 2001 From: Drew DeVault Date: Fri, 17 May 2019 11:52:38 -0400 Subject: [PATCH] Remove unimplemented color configuration Will probably end up doing this differently anyway --- config/aerc.conf | 42 ------------------------------------------ widgets/account.go | 2 +- widgets/msglist.go | 4 ++-- 3 files changed, 3 insertions(+), 45 deletions(-) diff --git a/config/aerc.conf b/config/aerc.conf index 5db4cf0..530e92b 100644 --- a/config/aerc.conf +++ b/config/aerc.conf @@ -65,45 +65,3 @@ editor= subject,~^\[PATCH=contrib/hldiff.py text/html=contrib/html text/*=contrib/plaintext.py - -[colors] -# -# Colors are configured in one of two ways: -# -# "foreground" or "background:foreground" -# -# You can specify colors according to the base 8 names: -# default, black, red, green, yellow, blue, magenta, cyan, white -# -# or you can use numbers for the 256 color palette, -# e.g. "127:118" (a particularly ugly combination FYI) -# -# Add one or more of the following characters to the beginning -# of the foreground color to add modifiers: -# -# * bold -# _ underline -# ^ reverse -# -# e.g. "default:_*^default" would reverse the default colors and -# with bold and underlined modifiers -borders=default:^default -loading-indicator=default:default - -account-unselected=white:black -account-selected=default:default -account-error=red:black - -folder-unselected=default:default -folder-selected=white:black - -status-line=white:black -status-line-error=red:black - -ex-line=default:default - -message-list-selected=white:black -message-list-selected-unread=white:_black -message-list-unselected=default:default -message-list-unselected-unread=default:*default -message-list-empty=default:default diff --git a/widgets/account.go b/widgets/account.go index ab32f5d..fa8c524 100644 --- a/widgets/account.go +++ b/widgets/account.go @@ -49,7 +49,7 @@ func NewAccountView(conf *config.AercConfig, acct *config.AccountConfig, dirlist := NewDirectoryList(acct, logger, worker) grid.AddChild(ui.NewBordered(dirlist, ui.BORDER_RIGHT)) - msglist := NewMessageList(logger) + msglist := NewMessageList(conf, logger) grid.AddChild(msglist).At(0, 1) view := &AccountView{ diff --git a/widgets/msglist.go b/widgets/msglist.go index 944bad8..6cf9b97 100644 --- a/widgets/msglist.go +++ b/widgets/msglist.go @@ -23,9 +23,9 @@ type MessageList struct { store atomic.Value // *lib.MessageStore } -// TODO: fish in config -func NewMessageList(logger *log.Logger) *MessageList { +func NewMessageList(conf *config.AercConfig, logger *log.Logger) *MessageList { ml := &MessageList{ + conf: conf, logger: logger, selected: 0, spinner: NewSpinner(),