[PR #5795] [MERGED] Make most emojis full-width #26479

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

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/5795
Author: @leonMSFT
Created: 5/7/2020
Status: Merged
Merged: 5/8/2020
Merged by: @undefined

Base: masterHead: dev/lelian/emojibig


📝 Commits (9)

📊 Changes

3 files changed (+130 additions, -145 deletions)

View changed files

📝 .github/actions/spell-check/whitelist/whitelist.txt (+1 -0)
📝 src/types/CodepointWidthDetector.cpp (+129 -55)
📝 src/types/convert.cpp (+0 -90)

📄 Description

The table that we refer to in CodepointWidthDetector.cpp to determine
whether or not a codepoint should be rendered as Wide vs Narrow was
based off EastAsianWidth[1]. If a codepoint wasn't included in this
table, they're considered Narrow. Many emojis aren't specified in the
EAW list, so this PR supplements our table with emoji codepoints from
emoji-data[2] in order to render most, if not all, emojis as full-width.

There are certain codepoints I've added to the comments (in case we want
to add them officially to the table in the future) that Microsoft
decided to give an emoji presentation even if it's specified as
Narrow/Ambiguous in the EAW list and are not specified in the Unicode
emoji list. These include all of the Mahjong Tiles block, different
direction pencils (✎✐), different pointing index fingers (☜, ☞) among
others. I have no idea if I've captured all of them, as I don't know of
an easy way to detect which are Microsoft specific emojis.

Validation Steps Performed

I have looked at so many emojis that I dream emoji.

These screenshots aren't encompassing all emoji but I've tried to grab
a couple from all across the codepoint ranges:

Before:
before

After:
after

[1] http://www.unicode.org/Public/UCD/latest/ucd/EastAsianWidth.txt
[2] https://www.unicode.org/Public/13.0.0/ucd/emoji/emoji-data.txt

Closes #900


🔄 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/5795 **Author:** [@leonMSFT](https://github.com/leonMSFT) **Created:** 5/7/2020 **Status:** ✅ Merged **Merged:** 5/8/2020 **Merged by:** [@undefined](undefined) **Base:** `master` ← **Head:** `dev/lelian/emojibig` --- ### 📝 Commits (9) - [`19e4c53`](https://github.com/microsoft/terminal/commit/19e4c53e4c1664491646acb2e7ff69f36c4ec97d) adding the rest of the emoji codepoints in to see - [`e0eac63`](https://github.com/microsoft/terminal/commit/e0eac63e4f01c257beb3b1ce2aae4e23a5a27092) comment - [`e8e2beb`](https://github.com/microsoft/terminal/commit/e8e2beb8be59d39b2ce2ca4a25a241d81b6ebc92) comments and microsoft emoji additions - [`7ae5d20`](https://github.com/microsoft/terminal/commit/7ae5d203c9d04936904a05e97769c955aff2775f) marking the overridden ones - [`ee2b59f`](https://github.com/microsoft/terminal/commit/ee2b59f92cfc98a71c4107d4a38b497b65923efe) removed MS emoji codepoints - [`224f880`](https://github.com/microsoft/terminal/commit/224f88077259680e77b4b3599082a518ea513ad9) added a few missing - [`56000d4`](https://github.com/microsoft/terminal/commit/56000d45497fe6ddedae699191662a10f67545de) hot springs, female sign - [`fc0fe03`](https://github.com/microsoft/terminal/commit/fc0fe0375febebefcbad013a8e2e59f0de033bc1) spell check - [`9e2ee25`](https://github.com/microsoft/terminal/commit/9e2ee25ce8a7932a44c6dc4c3a02e3252e45e485) wow i can't do math ### 📊 Changes **3 files changed** (+130 additions, -145 deletions) <details> <summary>View changed files</summary> 📝 `.github/actions/spell-check/whitelist/whitelist.txt` (+1 -0) 📝 `src/types/CodepointWidthDetector.cpp` (+129 -55) 📝 `src/types/convert.cpp` (+0 -90) </details> ### 📄 Description The table that we refer to in `CodepointWidthDetector.cpp` to determine whether or not a codepoint should be rendered as Wide vs Narrow was based off EastAsianWidth[1]. If a codepoint wasn't included in this table, they're considered Narrow. Many emojis aren't specified in the EAW list, so this PR supplements our table with emoji codepoints from emoji-data[2] in order to render most, if not all, emojis as full-width. There are certain codepoints I've added to the comments (in case we want to add them officially to the table in the future) that Microsoft decided to give an emoji presentation even if it's specified as Narrow/Ambiguous in the EAW list and are _not_ specified in the Unicode emoji list. These include all of the Mahjong Tiles block, different direction pencils (✎✐), different pointing index fingers (☜, ☞) among others. I have no idea if I've captured all of them, as I don't know of an easy way to detect which are Microsoft specific emojis. ## Validation Steps Performed I have looked at so many emojis that I dream emoji. These screenshots aren't encompassing _all_ emoji but I've tried to grab a couple from all across the codepoint ranges: Before: ![before](https://user-images.githubusercontent.com/57155886/81445092-2051a980-912d-11ea-9739-c9f588da407d.png) After: ![after](https://user-images.githubusercontent.com/57155886/81445107-2778b780-912d-11ea-9615-676c2150e798.png) [1] http://www.unicode.org/Public/UCD/latest/ucd/EastAsianWidth.txt [2] https://www.unicode.org/Public/13.0.0/ucd/emoji/emoji-data.txt Closes #900 --- <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:16:20 +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#26479