Don't indent line if all we're outputting is ANSI sequences

This commit is contained in:
Christian Muehlhaeuser
2019-12-04 08:56:15 +01:00
parent f7244397d2
commit 550c0bdbd5
3 changed files with 30 additions and 18 deletions
+1 -1
View File
@@ -24,7 +24,7 @@ func (w *AnsiWriter) Write(b []byte) (int, error) {
w.ansiseq += string(c)
} else if w.ansi {
w.ansiseq += string(c)
if (c >= 0x40 && c <= 0x5a) || (c >= 0x61 && c <= 0x7a) {
if (c >= 0x41 && c <= 0x5a) || (c >= 0x61 && c <= 0x7a) {
// ANSI sequence terminated
w.ansi = false