package vttest

import "github.com/tonistiigi/vt100/vttest"

Index

Functions

func FromLines

func FromLines(s string) *vt100.VT100

FromLines generates a VT100 from content text. Each line must have the same number of runes.

func FromLinesAndFormats

func FromLinesAndFormats(s string, a [][]vt100.Format) *vt100.VT100

FromLinesAndFormats generates a *VT100 whose state is set according to s (for content) and a (for attributes).

Dimensions are set to the width of s' first line and the height of the number of lines in s.

If a is nil, the default attributes are used.

Source Files

generate.go

Version
v0.0.0-20240514184818-90bafcd6abab (latest)
Published
May 14, 2024
Platform
linux/amd64
Imports
3 packages
Last checked
1 year ago

Tools for package owners.