Skip to content

feat: block border merging - #1874

Merged
orhun merged 110 commits into
ratatui:mainfrom
j-g00da:block-border-merging
Jun 4, 2025
Merged

feat: block border merging#1874
orhun merged 110 commits into
ratatui:mainfrom
j-g00da:block-border-merging

Conversation

@j-g00da

@j-g00da j-g00da commented May 27, 2025

Copy link
Copy Markdown
Member

Co-authored by @pauladam94
Fork of #1729

pauladam94 and others added 30 commits March 20, 2025 01:18
Only added on the first one of the +1/-1 to avoid redundancy
refactor : more compact early return

Co-authored-by: Orhun Parmaksız <orhunparmaksiz@gmail.com>
Co-authored-by: Jagoda Estera Ślązak <128227338+j-g00da@users.noreply.github.com>
Co-authored-by: Jagoda Estera Ślązak <128227338+j-g00da@users.noreply.github.com>
Co-authored-by: Jagoda Estera Ślązak <128227338+j-g00da@users.noreply.github.com>
Co-authored-by: Jagoda Estera Ślązak <128227338+j-g00da@users.noreply.github.com>
Co-authored-by: Jagoda Estera Ślązak <128227338+j-g00da@users.noreply.github.com>
Co-authored-by: Jagoda Estera Ślązak <128227338+j-g00da@users.noreply.github.com>
@j-g00da
j-g00da requested review from joshka and orhun June 3, 2025 14:01
Comment thread ratatui-widgets/src/block/merge/exact.txt Outdated
Comment thread ratatui-core/src/symbols/merge.rs Outdated
@joshka
joshka requested a review from orhun June 3, 2025 23:05

@joshka joshka left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. @orhun @j-g00da are you both happy with my changes?

@j-g00da j-g00da left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM just one thing

Comment thread ratatui-widgets/src/block.rs Outdated
Comment thread ratatui-widgets/src/block.rs Outdated
Co-authored-by: Jagoda Estera Ślązak <128227338+j-g00da@users.noreply.github.com>

@orhun orhun left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@orhun
orhun merged commit 4255296 into ratatui:main Jun 4, 2025
orhun added a commit that referenced this pull request Jun 4, 2025
When two borders overlap, they will automatically merge into a single,
clean border instead of overlapping.

This improves visual clarity and reduces rendering glitches around corners.

For example:

```
assert_eq!(Cell::new("┘").merge_symbol("┏", MergeStrategy::Exact).symbol(), "╆");
```

Co-authored-by: pauladam94 <poladam2002@gmail.com>
Co-authored-by: Paul Adam <65903440+pauladam94@users.noreply.github.com>
Co-authored-by: Orhun Parmaksız <orhunparmaksiz@gmail.com>
Co-authored-by: Orhun Parmaksız <orhun@archlinux.org>
Co-authored-by: Josh McKinney <joshka@users.noreply.github.com>
@joshka

joshka commented Jun 4, 2025

Copy link
Copy Markdown
Member

Updated commit message was force pushed in 671c2b4

@joshka

joshka commented Jun 4, 2025

Copy link
Copy Markdown
Member

Thanks @pauladam94 for kicking this off, and @j-g00da for jumping on it and doing a bunch of work to get it over the line.

@joshka joshka mentioned this pull request Jun 24, 2025
takumi-earth pushed a commit to earthlings-dev/ratatui that referenced this pull request Jan 27, 2026
When two borders overlap, they will automatically merge into a single,
clean border instead of overlapping.

This improves visual clarity and reduces rendering glitches around corners.

For example:

```
assert_eq!(Cell::new("┘").merge_symbol("┏", MergeStrategy::Exact).symbol(), "╆");
```

Co-authored-by: pauladam94 <poladam2002@gmail.com>
Co-authored-by: Paul Adam <65903440+pauladam94@users.noreply.github.com>
Co-authored-by: Orhun Parmaksız <orhunparmaksiz@gmail.com>
Co-authored-by: Orhun Parmaksız <orhun@archlinux.org>
Co-authored-by: Josh McKinney <joshka@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants