editor: Fix newline below when selection is at the end of an multibuffer excerpt#49132
Merged
Veykril merged 2 commits intozed-industries:mainfrom Feb 17, 2026
Conversation
a multibuffer Switches `newline_below` from adding a newline to the start of the next line in a multibuffer, to appending a newline at the end of the selections current lines. This keeps the insertion within the excerpt of the selection rather than adding a newline to the excerpt below.
auto-merge was automatically disabled
February 16, 2026 15:37
Head branch was pushed to by a user without write access
auto-merge was automatically disabled
February 16, 2026 15:41
Head branch was pushed to by a user without write access
4676a5b to
b273b87
Compare
Contributor
Author
|
Should be passing now! Had to make some changes to not shift around collaborator cursors and group edits by the buffer they belong to. |
Veykril
approved these changes
Feb 17, 2026
rtfeldman
pushed a commit
that referenced
this pull request
Feb 17, 2026
…fer excerpt (#49132) Switches `newline_below` from adding a newline to the start of the next line in a multibuffer, to appending a newline at the end of the selections current lines. This keeps the insertion within the excerpt of the selection rather than adding a newline to the excerpt below. Closes #47965 Before you mark this PR as ready for review, make sure that you have: - [x] Added a solid test coverage and/or screenshots from doing manual testing - [x] Done a self-review taking into account security and performance aspects - [x] Aligned any UI changes with the [UI checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist) Release Notes: - Fixed `editor::NewlineBelow` adding a newline to the next multibuffer excerpt when selection is at the end of an excerpt
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
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.
Switches
newline_belowfrom adding a newline to the start of the next line in a multibuffer, to appending a newline at the end of the selections current lines. This keeps the insertion within the excerpt of the selection rather than adding a newline to the excerpt below.Closes #47965
Before you mark this PR as ready for review, make sure that you have:
Release Notes:
editor::NewlineBelowadding a newline to the next multibuffer excerpt when selection is at the end of an excerpt