mirror of
https://github.com/Llewellynvdm/fzf.git
synced 2024-11-18 11:05:16 +00:00
Restore scroll after rendering full-height Sixel image (#2544)
When a Sixel image touches the bottom of the screen, the whole screen scrolls up one line to make room for the cursor. Add an ANSI escape code to compensate for the movement. Unfortunately, the movement of the screen is sometimes noticeable. fzf --preview='fzf-preview.sh {}' --preview-window border-left
This commit is contained in:
parent
1cfa3ee4c7
commit
278dce9ba6
@ -2061,7 +2061,10 @@ Loop:
|
||||
|
||||
if requiredLines > 0 {
|
||||
if y+requiredLines == height {
|
||||
t.pwindow.Move(y+requiredLines, 0)
|
||||
if t.tui.MaxY() == t.pwindow.Top()+height {
|
||||
t.tui.PassThrough("\x1b[1T")
|
||||
}
|
||||
t.pwindow.Move(height-1, maxWidth-1)
|
||||
t.previewed.filled = true
|
||||
break Loop
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user