mirror of
https://github.com/junegunn/fzf.git
synced 2026-07-21 07:30:35 +08:00
Hide default separator when a border separates input from list
- Applies when adjacent section (header, header lines, or list) draws
border line facing input section
# No separator below header border
fzf --style full --input-border none --header foo
# Separator shown; nothing separates input from list
fzf --style full --input-border none --header foo --no-header-border
- Evaluated dynamically so change-header/toggle-header update it
This commit is contained in:
@@ -3696,6 +3696,9 @@ func (opts *Options) noSeparatorLine() bool {
|
||||
if opts.Inputless {
|
||||
return true
|
||||
}
|
||||
// NOTE: This can overestimate by one line when the default separator is
|
||||
// suppressed at runtime (see Terminal.separatorLength), making the height
|
||||
// lower bounds derived from it one line more generous than necessary.
|
||||
sep := opts.Separator == nil && !opts.InputBorderShape.Visible() || opts.Separator != nil && len(*opts.Separator) > 0
|
||||
return noSeparatorLine(opts.InfoStyle, sep)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user