func (command *Command) FlashError(message string) { command.clear() command.ColorOn(command.error_color) command.Print(message) command.ColorOff(command.error_color) command.Refresh() goncurses.NapMilliseconds(1000) command.clear() }
func (list *List) FlashError(message string) { bottom, _ := list.Maxyx() list.refresh() list.ColorOn(list.error_color) list.MovePrint(bottom-2, 2, message) list.ColorOff(list.error_color) list.Refresh() goncurses.NapMilliseconds(1000) list.refresh() }