Skip to content
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

Fix off-by-2 calculation in horizontal scrolling of Tree & DirectoryTree #4744

Merged
merged 3 commits into from
Jul 15, 2024

Conversation

darrenburns
Copy link
Member

@darrenburns darrenburns commented Jul 15, 2024

Fixes #4741.

I think the addition of the two was something to account for the emojis in the directory tree - however, it broke tree scrolling.

Also, it seems it caused an additional 2 blank cells on the right side of the tree widget.

I've tested the fix here with Tree and DirectoryTree, with show_root=True and show_root=False.

It's a visual thing, but not sure it warrants a new snapshot test.

@darrenburns darrenburns marked this pull request as draft July 15, 2024 08:43
@darrenburns darrenburns marked this pull request as ready for review July 15, 2024 09:12
@darrenburns darrenburns merged commit 142f437 into main Jul 15, 2024
20 checks passed
@darrenburns darrenburns deleted the fix-tree-horizontal-scroll branch July 15, 2024 10:08
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.

Tree.scroll_to_line() off-by-2 error in x coordinate?
2 participants