diff --git a/color.go b/color.go index f715d62..690739e 100644 --- a/color.go +++ b/color.go @@ -53,6 +53,18 @@ const ( FgWhite ) +// Foreground Hi-Intensity text colors +const ( + FgHiBlack Attribute = iota + 90 + FgHiRed + FgHiGreen + FgHiYellow + FgHiBlue + FgHiMagenta + FgHiCyan + FgHiWhite +) + // Background text colors const ( BgBlack Attribute = iota + 40 @@ -65,6 +77,18 @@ const ( BgWhite ) +// Background Hi-Intensity text colors +const ( + BgHiBlack Attribute = iota + 100 + BgHiRed + BgHiGreen + BgHiYellow + BgHiBlue + BgHiMagenta + BgHiCyan + BgHiWhite +) + // New returns a newly created color object. func New(value ...Attribute) *Color { c := &Color{params: make([]Attribute, 0)} diff --git a/color_test.go b/color_test.go index 053b561..4289f88 100644 --- a/color_test.go +++ b/color_test.go @@ -30,6 +30,14 @@ func TestColor(t *testing.T) { {text: "magent", code: FgMagenta}, {text: "cyan", code: FgCyan}, {text: "white", code: FgWhite}, + {text: "hblack", code: FgHiBlack}, + {text: "hred", code: FgHiRed}, + {text: "hgreen", code: FgHiGreen}, + {text: "hyellow", code: FgHiYellow}, + {text: "hblue", code: FgHiBlue}, + {text: "hmagent", code: FgHiMagenta}, + {text: "hcyan", code: FgHiCyan}, + {text: "hwhite", code: FgHiWhite}, } for _, c := range testColors { @@ -98,6 +106,14 @@ func TestNoColor(t *testing.T) { {text: "magent", code: FgMagenta}, {text: "cyan", code: FgCyan}, {text: "white", code: FgWhite}, + {text: "hblack", code: FgHiBlack}, + {text: "hred", code: FgHiRed}, + {text: "hgreen", code: FgHiGreen}, + {text: "hyellow", code: FgHiYellow}, + {text: "hblue", code: FgHiBlue}, + {text: "hmagent", code: FgHiMagenta}, + {text: "hcyan", code: FgHiCyan}, + {text: "hwhite", code: FgHiWhite}, } for _, c := range testColors {