func (c Color) ToBg() Color {
	val := uint8(c)
	if val < 10 {
		return c
	}
	return Color(Fg2Bg(val))
}
ToBg always convert bg
package color
import (
	"fmt"
	"strconv"
)
type Color uint8
type Basic = Color  
type Opts []Color
func (o *Opts) Add(ops ...Color) {
	for _, op := range ops {
		if uint8(op) < 10 {
			*o = append(*o, op)
		}
	}
}
func (o Opts) IsValid() bool {
	return len(o) > 0
}
func (o Opts) IsEmpty() bool {
	return len(o) == 0
}
func (o Opts) String() string {
	return Colors2code(o...)
}
const (
	FgBase uint8 = 30
	BgBase uint8 = 40
	HiFgBase uint8 = 90
	HiBgBase uint8 = 100
)
const (
	FgBlack Color = iota + 30
	FgRed
	FgGreen
	FgYellow
	FgBlue
	FgMagenta  
	FgCyan     
	FgWhite
	FgDefault Color = 39
)
const (
	FgDarkGray Color = iota + 90  
	FgLightRed
	FgLightGreen
	FgLightYellow
	FgLightBlue
	FgLightMagenta
	FgLightCyan
	FgLightWhite
	FgGray Color = 90  
)
const (
	BgBlack Color = iota + 40
	BgRed
	BgGreen
	BgYellow  
	BgBlue
	BgMagenta
	BgCyan
	BgWhite
	BgDefault Color = 49
)
const (
	BgDarkGray Color = iota + 100
	BgLightRed
	BgLightGreen
	BgLightYellow
	BgLightBlue
	BgLightMagenta
	BgLightCyan
	BgLightWhite
	BgGray Color = 100
)
const (
	OpReset         Color = iota  
	OpBold                        
	OpFuzzy                       
	OpItalic                      
	OpUnderscore                  
	OpBlink                       
	OpFastBlink                   
	OpReverse                     
	OpConcealed                   
	OpStrikethrough               
)
const (
	Red     = FgRed
	Cyan    = FgCyan
	Gray    = FgDarkGray  
	Blue    = FgBlue
	Black   = FgBlack
	Green   = FgGreen
	White   = FgWhite
	Yellow  = FgYellow
	Magenta = FgMagenta
	Bold   = OpBold
	Normal = FgDefault
	LightRed     = FgLightRed
	LightCyan    = FgLightCyan
	LightBlue    = FgLightBlue
	LightGreen   = FgLightGreen
	LightWhite   = FgLightWhite
	LightYellow  = FgLightYellow
	LightMagenta = FgLightMagenta
	HiRed     = FgLightRed
	HiCyan    = FgLightCyan
	HiBlue    = FgLightBlue
	HiGreen   = FgLightGreen
	HiWhite   = FgLightWhite
	HiYellow  = FgLightYellow
	HiMagenta = FgLightMagenta
	BgHiRed     = BgLightRed
	BgHiCyan    = BgLightCyan
	BgHiBlue    = BgLightBlue
	BgHiGreen   = BgLightGreen
	BgHiWhite   = BgLightWhite
	BgHiYellow  = BgLightYellow
	BgHiMagenta = BgLightMagenta
)
func Bit4(code uint8) Color {
	return Color(code)
}
func (c Color) Name() string {
	name, ok := basic2nameMap[uint8(c)]
	if ok {
		return name
	}
	return "unknown"
}
func (c Color) Text(message string) string {
	return RenderString(c.String(), message)
}
func (c Color) Render(a ...interface{}) string {
	return RenderCode(c.String(), a...)
}
func (c Color) Renderln(a ...interface{}) string {
	return RenderWithSpaces(c.String(), a...)
}
func (c Color) Sprint(a ...interface{}) string {
	return RenderCode(c.String(), a...)
}
func (c Color) Sprintf(format string, args ...interface{}) string {
	return RenderString(c.String(), fmt.Sprintf(format, args...))
}
func (c Color) Print(args ...interface{}) {
	doPrintV2(c.Code(), fmt.Sprint(args...))
}
func (c Color) Printf(format string, a ...interface{}) {
	doPrintV2(c.Code(), fmt.Sprintf(format, a...))
}
func (c Color) Println(a ...interface{}) {
	doPrintlnV2(c.String(), a)
}
func (c Color) Light() Color {
	val := int(c)
	if val >= 30 && val <= 47 {
		return Color(uint8(c) + 60)
	}
	return c
}
func (c Color) Darken() Color {
	val := int(c)
	if val >= 90 && val <= 107 {
		return Color(uint8(c) - 60)
	}
	return c
}
func (c Color) C256() Color256 {
	val := uint8(c)
	if val < 10 {  
		return emptyC256  
	}
	var isBg uint8
	if val >= BgBase && val <= 47 {  
		isBg = AsBg
		val = val - 10  
	} else if val >= HiBgBase && val <= 107 {  
		isBg = AsBg
		val = val - 10  
	}
	if c256, ok := basicTo256Map[val]; ok {
		return Color256{c256, isBg}
	}
	return Color256{val}
}
func (c Color) ToFg() Color {
	val := uint8(c)
	if val < 10 {
		return c
	}
	return Color(Bg2Fg(val))
}