Skip to content

Everything is underlined in diff view #65

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
fr-joseph opened this issue Oct 21, 2024 · 6 comments
Open

Everything is underlined in diff view #65

fr-joseph opened this issue Oct 21, 2024 · 6 comments
Labels
bug Something isn't working

Comments

@fr-joseph
Copy link

fr-joseph commented Oct 21, 2024

Hello!

How can I get rid of the excess underlines in the diff view? What am I doing wrong?

It happens in both diff variants (color words and git diff).
I've tried on X and Wayland.
I've tried different terminal emulators (foot, kitty, wezterm, alacritty).
I've tried with a few different fonts.

Thank you!

lazyjj-underlines-comp

@fr-joseph fr-joseph changed the title Underlines in diff view Everything is underlined in diff view Oct 21, 2024
@istudyatuni
Copy link
Collaborator

istudyatuni commented Oct 26, 2024

Could you share your jj config? I have this in mine

[colors]
# do not underline lines in hunks (since 0.19)
"diff removed token" = { underline = false }
"diff added token" = { underline = false }

and lazyjj doesn't underline in diff, but if I comment these lines out, behavior the same as on your screenshot

upd. Okay, jj doesn't underline without this, strange

@fr-joseph
Copy link
Author

@istudyatuni , adding the [colors] config fixed it. Thank you!

Feel free to close this.

@istudyatuni
Copy link
Collaborator

Feel free to close this.

I can't, but you can because you are the author of the issue

@fr-joseph
Copy link
Author

fr-joseph commented Oct 26, 2024

Hmm, I changed my mind. I'm not really satisfied with disabling all the underlines. Is it possible to replicate the way that plain jj underlines the diff view?

The underlines are very useful for when spaces get added or removed. Hopefully this new example makes it easier to see, where the indentation changes after adding the surrounding if block.

lazyjj_underlines_example2

@Cretezy
Copy link
Owner

Cretezy commented Feb 15, 2025

I can replicate this as well. I have found the issue (reset bug in ansi-to-tui) and opened a PR: ratatui/ansi-to-tui#57

@Cretezy Cretezy added the bug Something isn't working label Feb 15, 2025
@Cretezy
Copy link
Owner

Cretezy commented Feb 15, 2025

Image

Fixed in v0.5.0 using fork (but not in cargo version)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants