diff --git a/src/tui/light.go b/src/tui/light.go index ed537322..97d1effe 100644 --- a/src/tui/light.go +++ b/src/tui/light.go @@ -207,11 +207,6 @@ func (r *LightRenderer) Init() error { if r.fullscreen { r.smcup() } else { - // We assume that --no-clear is used for repetitive relaunching of fzf. - // So we do not clear the lower bottom of the screen. - if r.clearOnExit { - r.csi("J") - } y, x := r.findOffset() r.mouse = r.mouse && y >= 0 // When --no-clear is used for repetitive relaunching, there is a small @@ -222,6 +217,11 @@ func (r *LightRenderer) Init() error { r.upOneLine = true r.makeSpace() } + // We assume that --no-clear is used for repetitive relaunching of fzf. + // So we do not clear the lower bottom of the screen. + if r.clearOnExit { + r.csi("J") + } for i := 1; i < r.MaxY(); i++ { r.makeSpace() }