Skip to content

Commit

Permalink
Fix for search selections highlight going backward when the selection…
Browse files Browse the repository at this point in the history
… wraps to next line (#16691)

Hi, I realized I had a bug in my pull request for search selections
where when the highlight is wrapped it causes the selection to select
back to start of the current line instead of wrapping to the next line.

PR where I introduced this bug: #16227

(cherry picked from commit bef2340)
Service-Card-Id: 91808626
Service-Version: 1.20
  • Loading branch information
e82eric authored and DHowett committed Feb 21, 2024
1 parent f01fb26 commit b520c80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cascadia/TerminalCore/TerminalSelection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ std::vector<til::inclusive_rect> Terminal::_GetSearchSelectionRects(Microsoft::C
for (auto selection = lowerIt; selection != upperIt; ++selection)
{
const auto start = til::point{ selection->left, selection->top };
const auto end = til::point{ selection->right, selection->top };
const auto end = til::point{ selection->right, selection->bottom };
const auto adj = _activeBuffer().GetTextRects(start, end, _blockSelection, false);
for (auto a : adj)
{
Expand Down

0 comments on commit b520c80

Please sign in to comment.