mirror of
https://github.com/Llewellynvdm/fzf.git
synced 2024-11-29 16:23:57 +00:00
Fix header not shown when the lines go beyond the screen limit
This commit is contained in:
parent
bbaa3ab8bd
commit
928fccc15b
@ -388,7 +388,7 @@ func (t *Terminal) printHeader() {
|
|||||||
line -= 1
|
line -= 1
|
||||||
}
|
}
|
||||||
if line >= max {
|
if line >= max {
|
||||||
break
|
continue
|
||||||
}
|
}
|
||||||
trimmed, colors, newState := extractColor(&lineStr, state)
|
trimmed, colors, newState := extractColor(&lineStr, state)
|
||||||
state = newState
|
state = newState
|
||||||
|
@ -680,7 +680,10 @@ class TestGoFZF < TestBase
|
|||||||
|
|
||||||
def test_header_lines_overflow
|
def test_header_lines_overflow
|
||||||
tmux.send_keys "seq 100 | #{fzf '--header-lines=200'}", :Enter
|
tmux.send_keys "seq 100 | #{fzf '--header-lines=200'}", :Enter
|
||||||
tmux.until { |lines| lines[-2].include?('0/0') }
|
tmux.until do |lines|
|
||||||
|
lines[-2].include?('0/0') &&
|
||||||
|
lines[-3].include?(' 1')
|
||||||
|
end
|
||||||
tmux.send_keys :Enter
|
tmux.send_keys :Enter
|
||||||
assert_equal '', readonce.chomp
|
assert_equal '', readonce.chomp
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user