editor: Show format selections for cursor ranges - #56571
Merged
ChristopherBiscardi merged 2 commits intoJun 9, 2026
Merged
Conversation
|
That was very quick! Probably not neeed given the screen recording is very clear but I did also run a local build (with my normal keymaps and other config reinstated) and can confirm that, with this change, everything works as I am used to from 0.233.10. |
daniel-thompson
approved these changes
Jun 3, 2026
daniel-thompson
left a comment
There was a problem hiding this comment.
LGTM. Very targeted, "obviously correct" and with a test case.
ChristopherBiscardi
approved these changes
Jun 9, 2026
ChristopherBiscardi
left a comment
Contributor
There was a problem hiding this comment.
thanks!
And thank you @daniel-thompson for the community review. That kind of review is a valuable contribution too.
This was referenced Jun 18, 2026
Closed
This was referenced Jul 1, 2026
This was referenced Jul 10, 2026
jonx
pushed a commit
to jonx/zed-aros
that referenced
this pull request
Jul 17, 2026
Resolves zed-industries#56556 This diff fixes format selections being unavailable when the selection is a cursor range. The action was gated on having at least one non-empty selection, which hid it even when the active formatter supported range formatting. With this change, cursor ranges are included when checking whether the selected buffers support range formatting. This restores the cursor-based `Format Selections` behavior while preserving the existing formatter-capability gate, so the action still stays hidden for formatters that cannot format ranges. https://github.com/user-attachments/assets/fc2ab2b7-1af3-4849-841a-b57a685d748f Release Notes: - Fixed format selections not being available for cursor ranges when the active formatter supports range formatting. Co-authored-by: Christopher Biscardi <chris@christopherbiscardi.com>
jolutz
pushed a commit
to jolutz/zed
that referenced
this pull request
Aug 8, 2026
Resolves zed-industries#56556 This diff fixes format selections being unavailable when the selection is a cursor range. The action was gated on having at least one non-empty selection, which hid it even when the active formatter supported range formatting. With this change, cursor ranges are included when checking whether the selected buffers support range formatting. This restores the cursor-based `Format Selections` behavior while preserving the existing formatter-capability gate, so the action still stays hidden for formatters that cannot format ranges. https://github.com/user-attachments/assets/fc2ab2b7-1af3-4849-841a-b57a685d748f Release Notes: - Fixed format selections not being available for cursor ranges when the active formatter supports range formatting. Co-authored-by: Christopher Biscardi <chris@christopherbiscardi.com>
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.
Resolves #56556
This diff fixes format selections being unavailable when the selection is a cursor range. The action was gated on having at least one non-empty selection, which hid it even when the active formatter supported range formatting.
With this change, cursor ranges are included when checking whether the selected buffers support range formatting. This restores the cursor-based
Format Selectionsbehavior while preserving the existing formatter-capability gate, so the action still stays hidden for formatters that cannot format ranges.Screen.Recording.2026-05-12.at.2.57.44.PM.mov
Release Notes: