From 7782da6c00ebc8f9df77da9816165323cc6d218c Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Sun, 19 Apr 2026 13:55:26 +0900 Subject: [PATCH] Add dashed border style MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit New --border=dashed / --list-border=dashed / --header-border=dashed etc. Uses U+2576 (╶) for horizontal edges and U+2506 (┆) for verticals, with rounded corners (╭╮╰╯) and sharp T-junction mids (├┤). Terminal cells are taller than wide (~2:1), so horizontals use a sparse stub per cell while verticals need more dashes per cell to look evenly dashed. Works with inline sections. --- CHANGELOG.md | 3 +++ man/man1/fzf.1 | 6 +++++- src/options.go | 18 +++++++++++------- src/terminal.go | 4 ++-- src/tui/tui.go | 18 ++++++++++++++++++ 5 files changed, 39 insertions(+), 10 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2851d62f..16934241 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,9 @@ CHANGELOG - `--header-label` and `--footer-label` render on their respective separator row. - The separator inherits `--color list-border` when the section's own border color is not explicitly set. - `inline` takes precedence over `--header-first`: the inline section stays inside the list frame. `--header-border=inline` requires `--header-lines-border` to be `inline` or unset. +- New `dashed` border style with dashed edges (`╶` / `┆`) and rounded corners. + - `--border=dashed`, `--list-border=dashed`, etc. + - Works with inline sections (T-junctions render correctly). - [vim] Move and resize popup window when detecting `VimResized` event (#4778) (@Vulcalien) - Bug fixes - Fixed gutter display in `--style=minimal` diff --git a/man/man1/fzf.1 b/man/man1/fzf.1 index 4b17a48d..2eb28da1 100644 --- a/man/man1/fzf.1 +++ b/man/man1/fzf.1 @@ -517,6 +517,8 @@ Draw border around the finder .br .BR double " Border with double lines" .br +.BR dashed " Border with dashed lines and rounded corners" +.br .BR block " Border using block elements; suitable when using different background colors" .br .BR thinblock " Border using legacy computing symbols; may not be displayed on some terminals" @@ -955,6 +957,8 @@ Should be used with one of the following \fB\-\-preview\-window\fR options. .br .B * border\-double .br +.B * border\-dashed +.br .B * border\-block .br .B * border\-thinblock @@ -1104,7 +1108,7 @@ separator line between the header window and the list section. \fBinline\fR style embeds the header inside the list border frame, joined to the list section by a horizontal separator; it requires a \fB\-\-list\-border\fR shape that has both top and bottom segments (rounded / sharp / bold / -double / block / thinblock / horizontal) and falls back to \fBline\fR +double / dashed / block / thinblock / horizontal) and falls back to \fBline\fR otherwise. When the list border also has side segments, the separator joins them with T-junctions; \fBhorizontal\fR has no side borders, so the separator is drawn without T-junction endpoints. Takes precedence over diff --git a/src/options.go b/src/options.go index 3f171d51..081621b8 100644 --- a/src/options.go +++ b/src/options.go @@ -85,7 +85,7 @@ Usage: fzf [options] --margin=MARGIN Screen margin (TRBL | TB,RL | T,RL,B | T,R,B,L) --padding=PADDING Padding inside border (TRBL | TB,RL | T,RL,B | T,R,B,L) --border[=STYLE] Draw border around the finder - [rounded|sharp|bold|block|thinblock|double|horizontal|vertical| + [rounded|sharp|bold|block|thinblock|double|dashed|horizontal|vertical| top|bottom|left|right|line|none] (default: rounded) --border-label=LABEL Label to print on the border --border-label-pos=COL Position of the border label @@ -128,7 +128,7 @@ Usage: fzf [options] (each for list section and preview window) --no-scrollbar Hide scrollbar --list-border[=STYLE] Draw border around the list section - [rounded|sharp|bold|block|thinblock|double|horizontal|vertical| + [rounded|sharp|bold|block|thinblock|double|dashed|horizontal|vertical| top|bottom|left|right|none] (default: rounded) --list-label=LABEL Label to print on the list border --list-label-pos=COL Position of the list label @@ -148,7 +148,7 @@ Usage: fzf [options] --ghost=TEXT Ghost text to display when the input is empty --filepath-word Make word-wise movements respect path separators --input-border[=STYLE] Draw border around the input section - [rounded|sharp|bold|block|thinblock|double|horizontal|vertical| + [rounded|sharp|bold|block|thinblock|double|dashed|horizontal|vertical| top|bottom|left|right|line|none] (default: rounded) --input-label=LABEL Label to print on the input border --input-label-pos=COL Position of the input label @@ -165,7 +165,7 @@ Usage: fzf [options] [,+SCROLL[OFFSETS][/DENOM]][,~HEADER_LINES] [,default][,