termfmt

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2023 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Bell

func Bell()

func HexString

func HexString(s string, fg string, bg string) string

func IsTerminal

func IsTerminal() bool

func RGBString

func RGBString(s string, fg, bg RGB) string

func ReplaceLine

func ReplaceLine() string

Types

type RGB

type RGB struct {
	Red, Green, Blue uint8
}

func HexToRGB

func HexToRGB(hex string) RGB

type Style

type Style string
const (
	Bold Style = "bold"
	Dim  Style = "dim"

	Red    Style = "red"
	Green  Style = "green"
	Yellow Style = "yellow"
	Blue   Style = "blue"

	DarkYellow Style = "dark-yellow"
)

func (Style) Sprint

func (style Style) Sprint(args ...interface{}) string

func (Style) Sprintf

func (style Style) Sprintf(format string, args ...interface{}) string

func (Style) String

func (style Style) String(s string) string

Jump to

Keyboard shortcuts

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