widgets

package
v0.0.0-...-300ae7d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 6, 2017 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Left  = Side(true)
	Right = Side(false)
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Message

type Message struct {
	Content string
	Ticks   int
	// contains filtered or unexported fields
}

type MessageBox

type MessageBox struct {
	*termui.Par
	// contains filtered or unexported fields
}

func NewMessageBox

func NewMessageBox() *MessageBox

func (*MessageBox) AddMessage

func (m *MessageBox) AddMessage(msg *Message, side Side)

func (*MessageBox) Buffer

func (m *MessageBox) Buffer() termui.Buffer

func (*MessageBox) Tick

func (m *MessageBox) Tick() bool

type ScrollableList

type ScrollableList struct {
	*termui.List

	SourceItems    []string
	CurrentItem    int
	HighlightColor string
	// contains filtered or unexported fields
}

func NewScrollableList

func NewScrollableList() *ScrollableList

func (*ScrollableList) Select

func (sl *ScrollableList) Select(item int)

func (*ScrollableList) SelectNext

func (sl *ScrollableList) SelectNext()

func (*ScrollableList) SelectPrevious

func (sl *ScrollableList) SelectPrevious()

func (*ScrollableList) SetItems

func (sl *ScrollableList) SetItems(items []string)

type Side

type Side bool

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL