Go语言的颜色包:Color

jopen 9年前

Color 是用 Go 语言编写的 ANSI Escape Codes 术语,你可以自定义屏幕的输出颜色。

Color

标准颜色:

// Print with default helper functions  color.Cyan("Prints text in cyan.")  // A newline will be appended automatically  color.Blue("Prints %s in blue.", "text")  // These are using the default foreground colors  color.Red("We have red")  color.Magenta("And many others ..")

项目主页:http://www.open-open.com/lib/view/home/1449151278467