-
-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Fix relative line numbers in sticky headers #45164
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Now it's O(n) where n = number of rows requested, instead of row range extended to `relative_to`
|
We require contributors to sign our Contributor License Agreement, and we don't have @Copilot on file. You can sign our CLA at https://zed.dev/cla. Once you've signed, post a comment here that says '@cla-bot check'. |
1096295 to
9b5dc91
Compare
ac370a0 to
7f7d7f4
Compare
CherryWorm
pushed a commit
to CherryWorm/zed
that referenced
this pull request
Dec 30, 2025
…d-industries#45741) Follow-up to zed-industries#45164 which caused the active line number to always be `0` instead of the actual current line number. No release notes since its only on nightly Release Notes: - N/A
rtfeldman
pushed a commit
that referenced
this pull request
Jan 5, 2026
Closes #42586 This includes a rewrite of `calculate_relative_line_numbers()`. Now it's linear-time with respect to the number of rows displayed, instead of linear time with respect to the number of rows displayed _plus_ the distance to the base row. Release Notes: - Improved performance when using relative line numbers in large files - Fixed relative line numbers not appearing in sticky headers
LivioGama
pushed a commit
to LivioGama/zed
that referenced
this pull request
Jan 20, 2026
Closes zed-industries#42586 This includes a rewrite of `calculate_relative_line_numbers()`. Now it's linear-time with respect to the number of rows displayed, instead of linear time with respect to the number of rows displayed _plus_ the distance to the base row. Release Notes: - Improved performance when using relative line numbers in large files - Fixed relative line numbers not appearing in sticky headers
LivioGama
pushed a commit
to LivioGama/zed
that referenced
this pull request
Jan 20, 2026
…d-industries#45741) Follow-up to zed-industries#45164 which caused the active line number to always be `0` instead of the actual current line number. No release notes since its only on nightly Release Notes: - N/A
LivioGama
pushed a commit
to LivioGama/zed
that referenced
this pull request
Jan 20, 2026
Closes zed-industries#42586 This includes a rewrite of `calculate_relative_line_numbers()`. Now it's linear-time with respect to the number of rows displayed, instead of linear time with respect to the number of rows displayed _plus_ the distance to the base row. Release Notes: - Improved performance when using relative line numbers in large files - Fixed relative line numbers not appearing in sticky headers
LivioGama
pushed a commit
to LivioGama/zed
that referenced
this pull request
Jan 20, 2026
…d-industries#45741) Follow-up to zed-industries#45164 which caused the active line number to always be `0` instead of the actual current line number. No release notes since its only on nightly Release Notes: - N/A
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #42586
This includes a rewrite of
calculate_relative_line_numbers(). Now it's linear-time with respect to the number of rows displayed, instead of linear time with respect to the number of rows displayed plus the distance to the base row.Release Notes:
"relative_line_numbers"setting