Skip to content
Myr

Allow \e[K in addition to \e[0K for full-line background

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Junegunn Choi · committed by Junegunn Choi · parent 3a21116 · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:src/ansi.go+1 added-1 removed
354 unmodified lines
355 } else {356 state = ansiState{prevState.fg, prevState.bg, prevState.attr, prevState.lbg, prevState.url}357 }358 if ansiCode[0] != '\x1b' || ansiCode[1] != '[' || ansiCode[len(ansiCode)-1] != 'm' {359 if prevState != nil && strings.HasSuffix(ansiCode, "0K") {359 if prevState != nil && (strings.HasSuffix(ansiCode, "0K") || strings.HasSuffix(ansiCode, "[K")) {360 state.lbg = prevState.bg361 } else if strings.HasPrefix(ansiCode, "\x1b]8;") && (strings.HasSuffix(ansiCode, "\x1b\\") || strings.HasSuffix(ansiCode, "\a")) {362 stLen := 2363 if strings.HasSuffix(ansiCode, "\a") {
123 unmodified lines