"Color selection" off-by-one regression: it colors 1 cell past the end #23086

Open
opened 2026-01-31 08:31:54 +00:00 by claunia · 0 comments
Owner

Originally created by @jazzdelightsme on GitHub (Mar 28, 2025).

Originally assigned to: @carlos-zamora on GitHub.

Windows Terminal version

1.23.10732.0

Windows build number

10.0.26388.1001

Other Software

No response

Steps to reproduce

I use the "Color Selection" feature a lot, and often the "all matches" variant, which lets you select some text, and then change the fg/bg color for all occurrences of the selected text.

Recently it started coloring one cell past the end of the selection. In the screenshot below, I selected "abcd", but the colorization applies to "abcde" (as well as "abcdeX", demonstrating that the search is not similarly afected):

Image

Expected Behavior

Just the "abcd" should have been colorized.

Actual Behavior

Colorization included one character past the end.

Originally created by @jazzdelightsme on GitHub (Mar 28, 2025). Originally assigned to: @carlos-zamora on GitHub. ### Windows Terminal version 1.23.10732.0 ### Windows build number 10.0.26388.1001 ### Other Software _No response_ ### Steps to reproduce I use the "Color Selection" feature a lot, and often the "all matches" variant, which lets you select some text, and then change the fg/bg color for all occurrences of the selected text. Recently it started coloring one cell past the end of the selection. In the screenshot below, I selected "abcd", but the colorization applies to "abcde" (as well as "abcdeX", demonstrating that the search is not similarly afected): ![Image](https://github.com/user-attachments/assets/6258a18f-d941-443d-9f3e-c7fd6750dbe3) ### Expected Behavior Just the "abcd" should have been colorized. ### Actual Behavior Colorization included one character past the end.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#23086