[PR #905] [MERGED] Selection for wide glyphs #24381

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

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/905
Author: @carlos-zamora
Created: 5/20/2019
Status: Merged
Merged: 6/18/2019
Merged by: @carlos-zamora

Base: masterHead: dev/cazamor/bugfix-emoji-selection


📝 Commits (10+)

📊 Changes

5 files changed (+344 additions, -164 deletions)

View changed files

📝 src/cascadia/TerminalCore/Terminal.cpp (+0 -151)
📝 src/cascadia/TerminalCore/Terminal.hpp (+6 -0)
src/cascadia/TerminalCore/TerminalSelection.cpp (+211 -0)
📝 src/cascadia/TerminalCore/terminalcore-common.vcxproj (+1 -0)
📝 src/cascadia/UnitTests_TerminalCore/SelectionTest.cpp (+126 -13)

📄 Description

Summary of the Pull Request

Fixes a bug/feature to select wide glyphs (#935 ). Short summary of it is that selecting emojis and other wide glyphs should encompass the entire glyph, not just half.

Also moved selection logic to new file for cleanliness.

I had to rebase from the ADO branch but it looks good. And tested :)

References

PR Checklist

  • Closes Alt+Numpad not working (#935)
  • CLA signed. If not, go over here and sign the CLA
  • Tests added/passed
  • Requires documentation to be updated
  • I've discussed this with core contributors already. If not checked, I'm ready to accept this work might be rejected in favor of a different grand plan. Issue number where discussion took place: #xxx

Detailed Description of the Pull Request / Additional comments

Basically, selection has to be covered in two cases: expand left and expand right. Made 2 similar looking functions.

To the team: this was already somewhat reviewed back before we went on GitHub. So if you have a deja vu feeling, that's why.


🔄 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/905 **Author:** [@carlos-zamora](https://github.com/carlos-zamora) **Created:** 5/20/2019 **Status:** ✅ Merged **Merged:** 6/18/2019 **Merged by:** [@carlos-zamora](https://github.com/carlos-zamora) **Base:** `master` ← **Head:** `dev/cazamor/bugfix-emoji-selection` --- ### 📝 Commits (10+) - [`191dee0`](https://github.com/microsoft/terminal/commit/191dee0d99660a8623ec0e92998fb8ddad78a2ec) Bugfix: selection on wide glyphs - [`3fc7bf2`](https://github.com/microsoft/terminal/commit/3fc7bf2d967696ae79f48a76be44dc8dd986e38c) Bugfix: wide glyph selection - PR changes 1 - [`ffeffd7`](https://github.com/microsoft/terminal/commit/ffeffd7e2b5a56ab2ebdf47541cd89bfbf6f3f33) merge master + fix merge conflicts - [`4a183e0`](https://github.com/microsoft/terminal/commit/4a183e07833a0efe49d839570c408118cab3a5ee) PR Changes - [`3699fcb`](https://github.com/microsoft/terminal/commit/3699fcb2c151143214c646577475c595d563f026) Tests added - [`4268cb3`](https://github.com/microsoft/terminal/commit/4268cb3c45c5bb15cfc945cca73d2ff596fa57af) Merge branch 'master' into dev/cazamor/bugfix-emoji-selection - [`6008640`](https://github.com/microsoft/terminal/commit/6008640c69b4f8a5caa64e92ed118ffd0deddd03) PR changes - [`092ed80`](https://github.com/microsoft/terminal/commit/092ed80926ea9f8027b13774079964d963f493c5) formatted - [`ec91468`](https://github.com/microsoft/terminal/commit/ec914688b99ea9b563df0ba30f817dfcc8995137) PR Changes - [`731acef`](https://github.com/microsoft/terminal/commit/731acef606368c430b1046454bf143a4d844e8b8) Clean up Selection Tests ### 📊 Changes **5 files changed** (+344 additions, -164 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/TerminalCore/Terminal.cpp` (+0 -151) 📝 `src/cascadia/TerminalCore/Terminal.hpp` (+6 -0) ➕ `src/cascadia/TerminalCore/TerminalSelection.cpp` (+211 -0) 📝 `src/cascadia/TerminalCore/terminalcore-common.vcxproj` (+1 -0) 📝 `src/cascadia/UnitTests_TerminalCore/SelectionTest.cpp` (+126 -13) </details> ### 📄 Description ## Summary of the Pull Request Fixes a bug/feature to select wide glyphs (#935 ). Short summary of it is that selecting emojis and other wide glyphs should encompass the entire glyph, not just half. Also moved selection logic to new file for cleanliness. I had to rebase from the ADO branch but it looks good. And tested :) ## References ## PR Checklist * [x] Closes #935 * [x] CLA signed. If not, go over [here](https://cla.opensource.microsoft.com/microsoft/Terminal) and sign the CLA * [x] Tests added/passed * [x] Requires documentation to be updated * [x] I've discussed this with core contributors already. If not checked, I'm ready to accept this work might be rejected in favor of a different grand plan. Issue number where discussion took place: #xxx <!-- Provide a more detailed description of the PR, other things fixed or any additional comments/features here --> ## Detailed Description of the Pull Request / Additional comments Basically, selection has to be covered in two cases: expand left and expand right. Made 2 similar looking functions. To the team: this was already somewhat reviewed back before we went on GitHub. So if you have a deja vu feeling, that's why. --- <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:02:56 +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#24381