color

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2022 License: MIT Imports: 1 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BackgroundFunc

func BackgroundFunc(color Color, backgroundColor Color) func(text string) string

func BackgroundWrap

func BackgroundWrap(color Color, backgroundColor Color, text string) string

BackgroundWrap 背景颜色

func TextWrap

func TextWrap(color Color, text string) string

TextWrap 文字颜色

Types

type Color

type Color int

Color is a console color

const (
	Black Color = iota + 30
	Red
	Green
	Yellow
	Blue
	Magenta
	Cyan
	White
)
const (
	LightGrey Color = iota + 90
	LightRed
	LightGreen
	LightYellow
	LightBlue
	LightMagenta
	LightCyan
	LightWhite
)

Jump to

Keyboard shortcuts

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