term

package
v0.4.4 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2023 License: Apache-2.0 Imports: 16 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EventBell

type EventBell struct{}

EventBell is emitted when BEL is received

type EventClosed

type EventClosed struct {
	Term  *Model
	Error error
}

type EventPanic

type EventPanic error

type EventTitle added in v0.1.2

type EventTitle string

type Model

type Model struct {
	// If true, OSC8 enables the output of OSC8 strings. Otherwise, any OSC8
	// sequences will be stripped
	OSC8 bool
	// Set the TERM environment variable to be passed to the command's
	// environment. If not set, xterm-256color will be used
	TERM string
	// contains filtered or unexported fields
}

Model models a virtual terminal

func New

func New() *Model

func (*Model) Attach added in v0.1.2

func (vt *Model) Attach(fn func(ev vaxis.Event))

func (*Model) Blur added in v0.1.2

func (vt *Model) Blur()

func (*Model) Close

func (vt *Model) Close()

func (*Model) Detach added in v0.1.2

func (vt *Model) Detach()

func (*Model) Draw

func (vt *Model) Draw(win vaxis.Window)

func (*Model) Focus added in v0.1.2

func (vt *Model) Focus()

func (*Model) Resize

func (vt *Model) Resize(w int, h int)

func (*Model) Start

func (vt *Model) Start(cmd *exec.Cmd) error

Start starts the terminal with the specified command. Start returns when the command has been successfully started.

func (*Model) String

func (vt *Model) String() string

func (*Model) Update

func (vt *Model) Update(msg vaxis.Event)

Jump to

Keyboard shortcuts

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