diff options
| author | Junegunn Choi <junegunn.c@gmail.com> | 2025-06-27 23:21:48 +0900 |
|---|---|---|
| committer | Junegunn Choi <junegunn.c@gmail.com> | 2025-06-27 23:21:48 +0900 |
| commit | 111266d83246cffa0f70d1db054f1e39a555ff80 (patch) | |
| tree | 74eb2891ba0ddfeb3ca9e9d870b031a3d1732c27 /src | |
| parent | 19d858f9b658add0e745e752c28748c7216d52bd (diff) | |
| download | fzf-111266d83246cffa0f70d1db054f1e39a555ff80.tar.gz | |
Reset full-background property after a new line
Diffstat (limited to 'src')
| -rw-r--r-- | src/ansi.go | 2 | ||||
| -rw-r--r-- | src/core.go | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/ansi.go b/src/ansi.go index 1311620d..6bff3d2b 100644 --- a/src/ansi.go +++ b/src/ansi.go @@ -287,6 +287,8 @@ func extractColor(str string, state *ansiState, proc func(string, *ansiState) bo [2]int32{int32(runeCount), int32(runeCount)}, marker, }) + // Reset the full-line background color + newState.lbg = -1 } } diff --git a/src/core.go b/src/core.go index ac42143d..da7da137 100644 --- a/src/core.go +++ b/src/core.go @@ -88,6 +88,9 @@ func Run(opts *Options) (int, error) { marker.color.attr = marker.color.attr | tui.FullBg newOffsets := append(*offsets, marker) offsets = &newOffsets + + // Reset the full-line background color + lineAnsiState.lbg = -1 } return util.ToChars(stringBytes(trimmed)), offsets } |
