Просмотр исходного кода

Fixed Alerbox size with Unicode.

bugz 1 год назад
Родитель
Сommit
9054d1db50
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      door/box.go

+ 1 - 1
door/box.go

@@ -85,7 +85,7 @@ func (b *Box) Bottom() string {
 
 func AlertBox(text string, style int) []string {
 	var results []string
-	b := Box{Width: len(text), Style: style}
+	b := Box{Width: StringLen(text), Style: style}
 	results = append(results, b.Top())
 	results = append(results, b.Row(text))
 	results = append(results, b.Bottom())