mirror of
https://github.com/junegunn/fzf
synced 2026-08-09 19:51:46 +00:00
Fix --preview-window follow not working correctly with wrapping
Fix #3243 Fix #4258
This commit is contained in:
+4
-2
@@ -1423,8 +1423,10 @@ func (w *LightWindow) fill(str string, resetCode string) FillReturn {
|
||||
for i, line := range allLines {
|
||||
lines := WrapLine(line, w.posx, w.width, w.tabstop, w.wrapSignWidth)
|
||||
for j, wl := range lines {
|
||||
w.stderrInternal(wl.Text, false, resetCode)
|
||||
w.posx += wl.DisplayWidth
|
||||
if w.posx < w.width {
|
||||
w.stderrInternal(wl.Text, false, resetCode)
|
||||
w.posx += wl.DisplayWidth
|
||||
}
|
||||
|
||||
// Wrap line
|
||||
if j < len(lines)-1 || i < len(allLines)-1 {
|
||||
|
||||
Reference in New Issue
Block a user