add colors and formatting variable for ansi escape codes
This commit is contained in:
parent
897ced93e2
commit
bae1313e9b
1 changed files with 30 additions and 0 deletions
30
ansi.go
Normal file
30
ansi.go
Normal file
|
@ -0,0 +1,30 @@
|
|||
package tui
|
||||
|
||||
// Formatting
|
||||
const (
|
||||
FmtReset = "\033[0m"
|
||||
FmtBold = "\033[1m"
|
||||
FmtBoldReset = "\033[22m"
|
||||
FmtDim = "\033[2m"
|
||||
FmtDimReset = FmtBoldReset
|
||||
FmtItalic = "\033[3m"
|
||||
FmtItalicReset = "\033[23m"
|
||||
FmtUnderline = "\033[4m"
|
||||
FmtUnderlineReset = "\033[24m"
|
||||
FmtBlink = "\033[5m"
|
||||
FmtBlinkReset = "\033[25m"
|
||||
FmtReverse = "\033[7m"
|
||||
FmtReverseReset = "\033[27m"
|
||||
FmtHidden = "\033[8m"
|
||||
FmtHiddenReset = "\033[28m"
|
||||
FmtStrikethrough = "\033[9m"
|
||||
FmtStrikethroughReset = "\033[29m"
|
||||
)
|
||||
|
||||
// Foreground Colors
|
||||
const (
|
||||
FgColorGrey = "\033[38;5;247m"
|
||||
FgColorGold = "\033[28;5;214m"
|
||||
FgColorGreen = "\033[38;5;34m"
|
||||
FgColorRed = "\033[38;5;167m"
|
||||
)
|
Loading…
Reference in a new issue