ソースを参照

Changed readme

Signed-off-by: Vishal Rana <vr@labstack.com>
Vishal Rana 10 年 前
コミット
955dbf2925
2 ファイル変更8 行追加7 行削除
  1. 6 5
      color/README.md
  2. 2 2
      color/color_test.go

+ 6 - 5
color/README.md

@@ -6,8 +6,8 @@ Style terminal text.
 
 ### Usage
 [labstack/gommon/color](https://github.com/labstack/gommon/blob/master/color/color_test.go)
-```go
 // Colored text
+```go
 fmt.Println(color.Black("black"))
 fmt.Println(color.Red("red"))
 fmt.Println(color.Green("green"))
@@ -20,8 +20,8 @@ fmt.Println(color.Grey("grey"))
 ```
 ![Colored Text](http://i.imgur.com/8RtY1QR.png)
 
-```go
 // Colored background
+```go
 fmt.Println(color.BlackBg("black background", color.Wht))
 fmt.Println(color.RedBg("red background"))
 fmt.Println(color.GreenBg("green background"))
@@ -33,8 +33,8 @@ fmt.Println(color.WhiteBg("white background"))
 ```
 ![Colored Background](http://i.imgur.com/SrrS6lw.png)
 
-```go
 // Emphasis
+```go
 fmt.Println(color.Bold("bold"))
 fmt.Println(color.Dim("dim"))
 fmt.Println(color.Italic("italic"))
@@ -44,12 +44,13 @@ fmt.Println(color.Hidden("hidden"))
 fmt.Println(color.Strikeout("strikeout"))
 ```
 ![Emphasis](http://i.imgur.com/3RSJBbc.png)
+
+// Mix and match
 ```go
-// Combo
 fmt.Println(Green("bold green with white background", B, WhtBg))
 fmt.Println(Red("underline red", U))
 fmt.Println(Yellow("dim yellow", D))
 fmt.Println(Cyan("inverse cyan", In))
 fmt.Println(Blue("bold underline dim blue", B, U, D))
 ```
-![Combo](http://i.imgur.com/jWGq9Ca.png)
+![Mix and match](http://i.imgur.com/jWGq9Ca.png)

+ 2 - 2
color/color_test.go

@@ -43,8 +43,8 @@ func TestEmphasis(t *testing.T) {
 	fmt.Println(color.Strikeout("strikeout"))
 }
 
-func TestCombo(t *testing.T) {
-	fmt.Println("*** combo ***")
+func TestMixMatch(t *testing.T) {
+	fmt.Println("*** mix and match ***")
 	fmt.Println(Green("bold green with white background", B, WhtBg))
 	fmt.Println(Red("underline red", U))
 	fmt.Println(Yellow("dim yellow", D))