Font Glyphs are cut off by the Windows Terminal #7113

Closed
opened 2026-01-31 00:55:21 +00:00 by claunia · 15 comments
Owner

Originally created by @DoCode on GitHub (Mar 24, 2020).

Environment

Windows build number: 10.0.18363.0
Windows Terminal version (if applicable): 0.10.781.0

Steps to reproduce

Some Unicode glyphs are cut off, ONLY in Windows Terminal.

Expected behavior

ConEmu:

image

PowerShell Core:

image

PowerShell:

image

Actual behavior

Windows Terminal:

image

Originally created by @DoCode on GitHub (Mar 24, 2020). <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING: 1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement. 2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement. 3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number). 4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement. 5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement. All good? Then proceed! --> <!-- This bug tracker is monitored by Windows Terminal development team and other technical folks. **Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues**. Instead, send dumps/traces to secure@microsoft.com, referencing this GitHub issue. If this is an application crash, please also provide a Feedback Hub submission link so we can find your diagnostic data on the backend. Use the category "Apps > Windows Terminal (Preview)" and choose "Share My Feedback" after submission to get the link. Please use this form and describe your issue, concisely but precisely, with as much detail as possible. --> # Environment ```none Windows build number: 10.0.18363.0 Windows Terminal version (if applicable): 0.10.781.0 ``` # Steps to reproduce Some Unicode glyphs are cut off, ONLY in Windows Terminal. # Expected behavior **ConEmu:** ![image](https://user-images.githubusercontent.com/1489133/77381002-0a567800-6d7d-11ea-93e5-bc3a42f6aef0.png) **PowerShell Core:** ![image](https://user-images.githubusercontent.com/1489133/77381010-0e829580-6d7d-11ea-8c8c-5ed7a96322db.png) **PowerShell:** ![image](https://user-images.githubusercontent.com/1489133/77381027-1b9f8480-6d7d-11ea-824b-53be50c14c84.png) # Actual behavior **Windows Terminal:** ![image](https://user-images.githubusercontent.com/1489133/77380976-f14dc700-6d7c-11ea-87cd-4208b4964d67.png)
Author
Owner

@fabienheureux commented on GitHub (Mar 24, 2020):

Maybe related to https://github.com/microsoft/terminal/issues/4974 ?
Do you use a font with ligatures ?

@fabienheureux commented on GitHub (Mar 24, 2020): Maybe related to https://github.com/microsoft/terminal/issues/4974 ? Do you use a font with ligatures ?
Author
Owner

@DoCode commented on GitHub (Mar 24, 2020):

No ligatures, but oversized glyphs. But I preserve space for it with one empty char as postfix for each oversized glyph.

But why only Windows Terminal struggled with this?

@DoCode commented on GitHub (Mar 24, 2020): No ligatures, but oversized glyphs. But I preserve space for it with one empty char as postfix for each oversized glyph. But why only Windows Terminal struggled with this?
Author
Owner

@fabienheureux commented on GitHub (Mar 24, 2020):

Well, I honestly don't know...but as the v1.0 is not yet released, this is understandable.

@fabienheureux commented on GitHub (Mar 24, 2020): Well, I honestly don't know...but as the v1.0 is not yet released, this is understandable.
Author
Owner

@skyline75489 commented on GitHub (Mar 24, 2020):

@DoCode How do you print this kind of 'oversized' glyph, though. I've tried echo -e '\U0001f602' it only gives me a regular sized folder.

@skyline75489 commented on GitHub (Mar 24, 2020): @DoCode How do you print this kind of 'oversized' glyph, though. I've tried `echo -e '\U0001f602'` it only gives me a regular sized folder.
Author
Owner

@DoCode commented on GitHub (Mar 24, 2020):

@fabienheureux - ok thanks.
So I hope MS would address this issue for the 1.0 milestone.

@DoCode commented on GitHub (Mar 24, 2020): @fabienheureux - ok thanks. So I hope MS would address this issue for the 1.0 milestone.
Author
Owner

@DoCode commented on GitHub (Mar 24, 2020):

@DoCode How do you print this kind of 'oversized' glyph, though. I've tried echo -e '\U0001f602' it only gives me a regular sized folder.

@skyline75489 - I print this kind with simple following a whitespace, like echo -e '\uF07C'' ' to preserve overlapping.

This works on all platforms and terminals, except the new Windows Terminal!

@DoCode commented on GitHub (Mar 24, 2020): > @DoCode How do you print this kind of 'oversized' glyph, though. I've tried `echo -e '\U0001f602'` it only gives me a regular sized folder. @skyline75489 - I print this kind with simple following a whitespace, like `echo -e '\uF07C'' '` to preserve overlapping. > This works on all platforms and terminals, except the new Windows Terminal!
Author
Owner

@zadjii-msft commented on GitHub (Mar 24, 2020):

@DoCode could you share what font you're using as well?

Also, are you sure that \uF07C is the glyph you want? I'm pretty sure that's not a valid unicode character. \U0001F5C1 looks a bit like what you want...

@zadjii-msft commented on GitHub (Mar 24, 2020): @DoCode could you share what font you're using as well? Also, are you sure that `\uF07C` is the glyph you want? I'm pretty sure that's [not a valid unicode character](https://www.fileformat.info/info/unicode/char/f07c/index.htm). [`\U0001F5C1`](https://www.fileformat.info/info/unicode/char/1f5c1/index.htm) looks a bit like what you want...
Author
Owner

@DoCode commented on GitHub (Mar 24, 2020):

@zadjii-msft yes, \uF07C, that's the glyph I want. It's ported from powerleve10k and this used larger icons. Works like a charm as I said.

Here's the font I used.

@DoCode commented on GitHub (Mar 24, 2020): @zadjii-msft yes, `\uF07C`, that's the glyph I want. It's ported from powerleve10k and this used larger icons. Works like a charm as I said. [Here's](https://github.com/microsoft/terminal/files/4375852/cascadia-nerd-font-complete.zip) the font I used.
Author
Owner

@DoCode commented on GitHub (Mar 24, 2020):

FYI, also the integrated VS Code terminal works like a charm:

image

@DoCode commented on GitHub (Mar 24, 2020): FYI, also the integrated VS Code terminal works like a charm: ![image](https://user-images.githubusercontent.com/1489133/77440470-a2d61200-6de8-11ea-864a-fb7c79c2f507.png)
Author
Owner

@jdebp commented on GitHub (Mar 24, 2020):

U+F07C is in the Unicode Private Use Area. Powerline, and "nerd fonts", fill this up with a whole bunch of stuff. Their users are sometimes surprised, in my experience, to learn that Private Use Area really does mean something that does not work the same everywhere. In this case, Windows Terminal is treating the character as a narrow character. The whole Private Use range is marked as "ambiguous" width in the Unicode standard.

U+1F5C1 is a standard character, with narrow width. Amusingly, Unicode version 13 now gives you U+1FBB9 and U+1FBBA for making a wide folder icon in a text display, in the way that computer people used to. (-:

@jdebp commented on GitHub (Mar 24, 2020): U+F07C is in the Unicode Private Use Area. Powerline, and ["nerd fonts"](https://github.com/ryanoasis/nerd-fonts/wiki/Glyph-Sets-and-Code-Points), fill this up with a whole bunch of stuff. Their users are sometimes surprised, in my experience, to learn that Private Use Area _really does mean_ something that does not work the same everywhere. In this case, Windows Terminal is treating the character as a narrow character. The whole Private Use range is marked as "ambiguous" width in the Unicode standard. U+1F5C1 is a standard character, with narrow width. Amusingly, Unicode version 13 now gives you U+1FBB9 and U+1FBBA for making a wide folder icon in a text display, in the way that computer people used to. (-:
Author
Owner

@DoCode commented on GitHub (Mar 24, 2020):

@jdebp thanks for the detailed explanation.
I will try your suggestions about unicode version 13.
However, I don't think it's okay that Windows Terminal doesn't behave like all other terminals. This will annoy many users. Windows Terminal is not the first and primary terminal on the market and should be as compatible as possible.

@DoCode commented on GitHub (Mar 24, 2020): @jdebp thanks for the detailed explanation. I will try your suggestions about unicode version 13. However, I don't think it's okay that Windows Terminal doesn't behave like all other terminals. This will annoy many users. Windows Terminal is not the first and primary terminal on the market and should be as compatible as possible.
Author
Owner

@waltermaldonado commented on GitHub (Mar 24, 2020):

I can confirm the same behavior here, but it is not present only in the Windows Terminal app. If Iuse WSL with the default terminal app, I get the icons from lsd cut off too.

Look closely to the folder's icons.

image

image

@waltermaldonado commented on GitHub (Mar 24, 2020): I can confirm the same behavior here, but it is not present only in the Windows Terminal app. If Iuse WSL with the default terminal app, I get the icons from lsd cut off too. Look closely to the folder's icons. ![image](https://user-images.githubusercontent.com/8573950/77487419-302d5c80-6e11-11ea-853f-412a765cdf6c.png) ![image](https://user-images.githubusercontent.com/8573950/77487464-49cea400-6e11-11ea-82b9-713c00eb55e7.png)
Author
Owner

@DHowett-MSFT commented on GitHub (Mar 26, 2020):

It's a very unfortunate situation that we've been put into by the ill-defined use of the private use area. We may need to fix this as part of a holistic look at how we handle ambiguous-width characters.

@DHowett-MSFT commented on GitHub (Mar 26, 2020): It's a very unfortunate situation that we've been put into by the ill-defined use of the private use area. We may need to fix this as part of a holistic look at how we handle ambiguous-width characters.
Author
Owner

@DHowett-MSFT commented on GitHub (Apr 24, 2020):

So, I've just installed one of these "fonts for nerds" and I cannot reproduce this issue in 0.11. There's an overlap problem, but I'm not seeing your folder glyph cut off if appropriate space is left for it.

image

If appropriate space isn't left for it, there's not much we can do.

At the end of the day, this glyph is reported as being "ambiguous" width and we've decided that ambiguous glyphs are one cell wide. Sorry.

For the record, this seems to be very close to xterm's behavior (xterm-344 pictured below).

image

and gnome-terminal

image

@DHowett-MSFT commented on GitHub (Apr 24, 2020): So, I've just installed one of these "fonts for nerds" and I cannot reproduce this issue in 0.11. There's an _overlap_ problem, but I'm not seeing your folder glyph cut off _if appropriate space is left for it_. ![image](https://user-images.githubusercontent.com/14316954/80246143-ca570f00-8620-11ea-8d28-efde70232c97.png) If appropriate space _isn't_ left for it, there's not much we can do. At the end of the day, this glyph is reported as being "ambiguous" width and we've decided that ambiguous glyphs are one cell wide. Sorry. For the record, this seems to be very close to _xterm's_ behavior (xterm-344 pictured below). ![image](https://user-images.githubusercontent.com/14316954/80246734-c1b30880-8621-11ea-88d9-018a69d8ce8a.png) _and gnome-terminal_ ![image](https://user-images.githubusercontent.com/14316954/80247104-60d80000-8622-11ea-88c3-fc6ed27db594.png)
Author
Owner

@DHowett-MSFT commented on GitHub (Apr 24, 2020):

Yes, we don't let the font outside of its bounding box if we're about to put another character right up against it. The result of striking the C or < down over the right side of the folder is visually offensive and cannot possibly be clearer than cutting it off.

@DHowett-MSFT commented on GitHub (Apr 24, 2020): Yes, we don't let the font outside of its bounding box if we're about to put another character right up against it. The result of striking the C or < down over the right side of the folder is visually offensive and cannot possibly be clearer than cutting it off.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#7113