aerc

Working clone of aerc-mail.org
git clone git://git.danielmoch.com/aerc.git
Log | Files | Refs | README | LICENSE

commit 2958579ee75359dacfabb6d1b36664468011113c
parent 84965d680cff655c7734070ef93fd3c1e2177748
Author: Drew DeVault <sir@cmpwn.com>
Date:   Sat, 30 Mar 2019 13:05:00 -0400

Correct color of error messages

Diffstat:
Mcommands/account/pipe.go | 8++++----
Mcommands/term.go | 2+-
Mwidgets/account.go | 2+-
Mwidgets/aerc.go | 2+-
4 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/commands/account/pipe.go b/commands/account/pipe.go @@ -32,13 +32,13 @@ func Pipe(aerc *widgets.Aerc, args []string) error { pipe, err := cmd.StdinPipe() if err != nil { aerc.PushStatus(" "+err.Error(), 10*time.Second). - Color(tcell.ColorRed, tcell.ColorWhite) + Color(tcell.ColorDefault, tcell.ColorRed) return } term, err := widgets.NewTerminal(cmd) if err != nil { aerc.PushStatus(" "+err.Error(), 10*time.Second). - Color(tcell.ColorRed, tcell.ColorWhite) + Color(tcell.ColorDefault, tcell.ColorRed) return } host := widgets.NewTermHost(term, aerc.Config()) @@ -50,7 +50,7 @@ func Pipe(aerc *widgets.Aerc, args []string) error { term.OnClose = func(err error) { if err != nil { aerc.PushStatus(" "+err.Error(), 10*time.Second). - Color(tcell.ColorRed, tcell.ColorWhite) + Color(tcell.ColorDefault, tcell.ColorRed) } else { // TODO: Tab-specific status stacks aerc.PushStatus("Process complete, press any key to close.", @@ -63,7 +63,7 @@ func Pipe(aerc *widgets.Aerc, args []string) error { _, err := io.Copy(pipe, reader) if err != nil { aerc.PushStatus(" "+err.Error(), 10*time.Second). - Color(tcell.ColorRed, tcell.ColorWhite) + Color(tcell.ColorDefault, tcell.ColorRed) } pipe.Close() }() diff --git a/commands/term.go b/commands/term.go @@ -39,7 +39,7 @@ func Term(aerc *widgets.Aerc, args []string) error { aerc.RemoveTab(host) if err != nil { aerc.PushStatus(" "+err.Error(), 10*time.Second). - Color(tcell.ColorRed, tcell.ColorWhite) + Color(tcell.ColorDefault, tcell.ColorRed) } } return nil diff --git a/widgets/account.go b/widgets/account.go @@ -185,6 +185,6 @@ func (acct *AccountView) onMessage(msg types.WorkerMessage) { case *types.Error: acct.logger.Printf("%v", msg.Error) acct.host.SetStatus(fmt.Sprintf("%v", msg.Error)). - Color(tcell.ColorRed, tcell.ColorDefault) + Color(tcell.ColorDefault, tcell.ColorRed) } } diff --git a/widgets/aerc.go b/widgets/aerc.go @@ -251,7 +251,7 @@ func (aerc *Aerc) BeginExCommand() { err := aerc.cmd(cmd) if err != nil { aerc.PushStatus(" "+err.Error(), 10*time.Second). - Color(tcell.ColorRed, tcell.ColorWhite) + Color(tcell.ColorDefault, tcell.ColorRed) } aerc.statusbar.Pop() aerc.focus(previous)