tui

package module
v0.0.0-...-43eea5b Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2015 License: MIT Imports: 6 Imported by: 0

README

tui

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Controlable

type Controlable interface {
	HandleInput(k termbox.Key, r rune)
}

type DisplayList

type DisplayList struct {
	// contains filtered or unexported fields
}

func (*DisplayList) AddElement

func (dl *DisplayList) AddElement(elem Drawable)

func (*DisplayList) Draw

func (dl *DisplayList) Draw()

func (*DisplayList) HandleInput

func (dl *DisplayList) HandleInput(k termbox.Key, r rune)

func (*DisplayList) NextFocus

func (dl *DisplayList) NextFocus()

func (*DisplayList) PrevFocus

func (dl *DisplayList) PrevFocus()

type Drawable

type Drawable interface {
	Draw()
}

type Focusable

type Focusable interface {
	GiveFocus()
}

type InputHandler

type InputHandler func(inp string)

type ScrollingTextOutput

type ScrollingTextOutput struct {
	TUIElement
	// contains filtered or unexported fields
}

func MakeScrollingTextOutput

func MakeScrollingTextOutput(pos rect.Rectangle) *ScrollingTextOutput

func (*ScrollingTextOutput) Draw

func (t *ScrollingTextOutput) Draw()

func (*ScrollingTextOutput) Write

func (t *ScrollingTextOutput) Write(p []byte) (n int, err error)

func (*ScrollingTextOutput) WriteLine

func (t *ScrollingTextOutput) WriteLine(l string)

type StaticText

type StaticText struct {
	TUIElement
	Text string
}

func MakeStaticText

func MakeStaticText(pos rect.Rectangle, text string) *StaticText

func (*StaticText) Draw

func (t *StaticText) Draw()

func (*StaticText) GiveFocus

func (t *StaticText) GiveFocus() bool

func (*StaticText) HandleInput

func (t *StaticText) HandleInput(k termbox.Key, r rune)

type TUIElement

type TUIElement struct {
	rect.Rectangle
}

type TextInputField

type TextInputField struct {
	// contains filtered or unexported fields
}

func MakeTextInputField

func MakeTextInputField(x, y int, inpHandler InputHandler) *TextInputField

func (*TextInputField) Draw

func (t *TextInputField) Draw()

func (*TextInputField) GiveFocus

func (t *TextInputField) GiveFocus() bool

func (*TextInputField) HandleInput

func (t *TextInputField) HandleInput(k termbox.Key, r rune)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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