[PR #4466] [MERGED] Make ScreenInfoUiaProvider::GetSelection() Return One Selection #25773

Open
opened 2026-01-31 09:11:42 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/4466
Author: @carlos-zamora
Created: 2/4/2020
Status: Merged
Merged: 2/20/2020
Merged by: @undefined

Base: masterHead: dev/cazamor/acc/sig/selection


📝 Commits (10+)

  • 7e828cc Return one UTR for selection, instead of one per line
  • 1bd65b6 Move TriggerSelection to TermControl. Terminal now has no responsibility triggering the selection on the renderer.
  • 87e793f fix ctor start/end issue
  • 68c35bd static analysis fix + code format
  • 47b33b8 static analysis fix
  • 8d8f9ae added todo to track box selection misrepresentation
  • 459a743 port change to ConHost
  • 1fdb3f6 merge master
  • 2cfabac merge master
  • d9fa7b0 remove unnecessary active selection check

📊 Changes

18 files changed (+130 additions, -167 deletions)

View changed files

📝 src/cascadia/TerminalControl/TermControl.cpp (+2 -0)
📝 src/cascadia/TerminalControl/TermControlUiaProvider.cpp (+12 -16)
📝 src/cascadia/TerminalControl/TermControlUiaProvider.hpp (+1 -1)
📝 src/cascadia/TerminalControl/UiaTextRange.cpp (+0 -28)
📝 src/cascadia/TerminalControl/UiaTextRange.hpp (+0 -5)
📝 src/cascadia/TerminalCore/Terminal.hpp (+2 -1)
📝 src/cascadia/TerminalCore/TerminalSelection.cpp (+16 -5)
📝 src/cascadia/TerminalCore/terminalrenderdata.cpp (+0 -1)
📝 src/host/renderData.cpp (+40 -1)
📝 src/host/renderData.hpp (+2 -1)
📝 src/interactivity/win32/screenInfoUiaProvider.cpp (+12 -16)
📝 src/interactivity/win32/screenInfoUiaProvider.hpp (+1 -1)
📝 src/interactivity/win32/uiaTextRange.cpp (+0 -28)
📝 src/interactivity/win32/uiaTextRange.hpp (+0 -5)
📝 src/types/IUiaData.h (+2 -1)
📝 src/types/ScreenInfoUiaProviderBase.cpp (+25 -54)
📝 src/types/ScreenInfoUiaProviderBase.h (+1 -1)
📝 src/types/UiaTextRangeBase.cpp (+14 -2)

📄 Description

Summary of the Pull Request

We used to return multiple text ranges to represent one selection. We only support one selection at a time, so we should only return one range.

Additionally, I moved all TriggerSelection() calls to the renderer from Terminal to TermControl for consistency. This ensures we only call it once when we make a change to our selection state.

References

#2447 - helps polish Signaling for Selection
#4465 - This is more apparent as the problem holding back Signaling for Selection

PR Checklist

Tested using Accessibility Insights.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/4466 **Author:** [@carlos-zamora](https://github.com/carlos-zamora) **Created:** 2/4/2020 **Status:** ✅ Merged **Merged:** 2/20/2020 **Merged by:** [@undefined](undefined) **Base:** `master` ← **Head:** `dev/cazamor/acc/sig/selection` --- ### 📝 Commits (10+) - [`7e828cc`](https://github.com/microsoft/terminal/commit/7e828cce8bfa1e61a3216fff6e841c01cf687629) Return one UTR for selection, instead of one per line - [`1bd65b6`](https://github.com/microsoft/terminal/commit/1bd65b6be8d3c3831fa3abdbe7d0d6da31936061) Move TriggerSelection to TermControl. Terminal now has no responsibility triggering the selection on the renderer. - [`87e793f`](https://github.com/microsoft/terminal/commit/87e793fcd693ca46a68711a62bbf4999d6f00c45) fix ctor start/end issue - [`68c35bd`](https://github.com/microsoft/terminal/commit/68c35bdecce80e6ed48afefe9231d102b5100cf1) static analysis fix + code format - [`47b33b8`](https://github.com/microsoft/terminal/commit/47b33b8128c124397e275fa4aebc8046b385ba09) static analysis fix - [`8d8f9ae`](https://github.com/microsoft/terminal/commit/8d8f9aea96fc6b5f4f8ae45ca3df1c19f8522e84) added todo to track box selection misrepresentation - [`459a743`](https://github.com/microsoft/terminal/commit/459a743e8c71e1e9b7b59e0a0a6fa6a44e994d90) port change to ConHost - [`1fdb3f6`](https://github.com/microsoft/terminal/commit/1fdb3f605df39dff944544f0013efb019215c05a) merge master - [`2cfabac`](https://github.com/microsoft/terminal/commit/2cfabac96f8d6098f409f41b20dbee1eabb291fe) merge master - [`d9fa7b0`](https://github.com/microsoft/terminal/commit/d9fa7b0205d95695ae82d7ac7a569ee34e8b2f68) remove unnecessary active selection check ### 📊 Changes **18 files changed** (+130 additions, -167 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/TerminalControl/TermControl.cpp` (+2 -0) 📝 `src/cascadia/TerminalControl/TermControlUiaProvider.cpp` (+12 -16) 📝 `src/cascadia/TerminalControl/TermControlUiaProvider.hpp` (+1 -1) 📝 `src/cascadia/TerminalControl/UiaTextRange.cpp` (+0 -28) 📝 `src/cascadia/TerminalControl/UiaTextRange.hpp` (+0 -5) 📝 `src/cascadia/TerminalCore/Terminal.hpp` (+2 -1) 📝 `src/cascadia/TerminalCore/TerminalSelection.cpp` (+16 -5) 📝 `src/cascadia/TerminalCore/terminalrenderdata.cpp` (+0 -1) 📝 `src/host/renderData.cpp` (+40 -1) 📝 `src/host/renderData.hpp` (+2 -1) 📝 `src/interactivity/win32/screenInfoUiaProvider.cpp` (+12 -16) 📝 `src/interactivity/win32/screenInfoUiaProvider.hpp` (+1 -1) 📝 `src/interactivity/win32/uiaTextRange.cpp` (+0 -28) 📝 `src/interactivity/win32/uiaTextRange.hpp` (+0 -5) 📝 `src/types/IUiaData.h` (+2 -1) 📝 `src/types/ScreenInfoUiaProviderBase.cpp` (+25 -54) 📝 `src/types/ScreenInfoUiaProviderBase.h` (+1 -1) 📝 `src/types/UiaTextRangeBase.cpp` (+14 -2) </details> ### 📄 Description ## Summary of the Pull Request We used to return multiple text ranges to represent one selection. We only support one selection at a time, so we should only return one range. Additionally, I moved all TriggerSelection() calls to the renderer from Terminal to TermControl for consistency. This ensures we only call it _once_ when we make a change to our selection state. ## References #2447 - helps polish Signaling for Selection #4465 - This is more apparent as the problem holding back Signaling for Selection ## PR Checklist * [x] Closes #4452 Tested using Accessibility Insights. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:11:42 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#25773