ui

package
v0.0.0-...-7f3c8ac Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BaseFrame

func BaseFrame() tview.Primitive

func Player

func Player(p components.Player) tview.Primitive

func TextMeter

func TextMeter(a, b, n int) string

Types

type ActivityLog

type ActivityLog struct {
	tview.TableContentReadOnly
	Records []Record
}

func NewActivityLog

func NewActivityLog() *ActivityLog

func (*ActivityLog) Clear

func (al *ActivityLog) Clear()

Remove all table data.

func (*ActivityLog) GetCell

func (al *ActivityLog) GetCell(row, column int) *tview.TableCell

Return the cell at the given position or nil if there is no cell. The row and column arguments start at 0 and end at what GetRowCount() and GetColumnCount() return, minus 1.

func (*ActivityLog) GetColumnCount

func (al *ActivityLog) GetColumnCount() int

Return the total number of columns in the table.

func (*ActivityLog) GetRowCount

func (al *ActivityLog) GetRowCount() int

Return the total number of rows in the table.

type Base

type Base struct {
	HP          *tview.TextView
	Mana        *tview.TextView
	Weapon      *tview.TextView
	Progression *tview.TextView
	Armor       *tview.TextView
	Trinket     *tview.TextView
	Log         tview.TableContent
	Monsters    tview.TableContent
}

func NewBase

func NewBase() *Base

type Record

type Record struct {
	Icon         rune
	IconColor    tcell.Color
	Message      string
	MessageColor tcell.Color
}

Jump to

Keyboard shortcuts

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