Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Drawable ¶ added in v0.1.6
type Drawable interface {
// DrawCell draws a cell.
//
// Parameters:
// - x: The x position of the cell.
// - y: The y position of the cell.
// - char: The character of the cell.
// - style: The style of the cell.
DrawCell(x, y int, char rune, style tcell.Style)
// BgStyle returns the background style.
//
// Returns:
// - tcell.Style: The background style.
BgStyle() tcell.Style
}
Drawable is an interface that can be drawn.
type Drawer ¶
type Drawer interface {
// DrawTable draws the table.
//
// Parameters:
// - bg_style: The background style of the table.
//
// Returns:
// - *DtTable: The table that was drawn.
// - error: An error if the table could not be drawn.
DrawTable(bg_style tcell.Style) (*dtb.Table, error)
}
Drawer is a table drawer.
type Screen ¶
type Screen struct {
// contains filtered or unexported fields
}
Screen is a screen.
func NewScreen ¶
NewScreen creates a new screen.
Parameters:
- bg_style: The background style of the screen.
Returns:
- *Screen: The new screen.
- error: The error if any.
func (*Screen) Height ¶ added in v0.1.6
Height returns the height of the screen.
Returns:
- int: The height of the screen.
func (*Screen) ListenForKey ¶ added in v0.1.6
ListenForKey listens for a key press event on the screen.
Parameters:
- None.
Returns:
- *tcell.EventKey: The key press event.
- bool: Whether the channel is still open.
func (*Screen) SetCell ¶ added in v0.1.6
SetCell is a helper function that sets a cell.
Parameters:
- x: The x position of the cell.
- y: The y position of the cell.
- c: The character of the cell.
- style: The style of the cell.
type TextBox ¶ added in v0.1.6
type TextBox struct {
// contains filtered or unexported fields
}
func NewTextBox ¶ added in v0.1.6
func NewTextBox() *TextBox
func (*TextBox) ChangeStyle ¶ added in v0.1.6
func (*TextBox) ChangeText ¶ added in v0.1.6
Click to show internal directories.
Click to hide internal directories.