Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong unicode display after font resize #4467

Open
LinoWhy opened this issue Oct 20, 2023 · 6 comments
Open

Wrong unicode display after font resize #4467

LinoWhy opened this issue Oct 20, 2023 · 6 comments
Labels
bug Something isn't working Windows Issue applies to Microsoft Windows

Comments

@LinoWhy
Copy link

LinoWhy commented Oct 20, 2023

What Operating System(s) are you seeing this problem on?

Windows

Which Wayland compositor or X11 Window manager(s) are you using?

No response

WezTerm version

wezterm 20230712-074712-5d1136d2

Did you try the latest nightly build to see if the issue is better (or worse!) than your current version?

Yes, and I updated the version box above to show the version of the nightly that I tried

Describe the bug

unicode "U+1F784" can be displayed correctly on start.
However it displays a square, once I change the font size. See the right side of the picture below.

image

To Reproduce

No response

Configuration

local config = {
  default_prog = { "wsl.exe", "--cd", "~" },
}

return config

Expected Behavior

No response

Logs

No response

Anything else?

No response

@LinoWhy LinoWhy added the bug Something isn't working label Oct 20, 2023
@wez wez added the Windows Issue applies to Microsoft Windows label Feb 4, 2024
@wez
Copy link
Owner

wez commented Feb 4, 2024

Please try the latest release

@wez wez added the waiting-on-op Waiting for more information from the original poster label Feb 4, 2024
@LinoWhy
Copy link
Author

LinoWhy commented Feb 6, 2024

Still not fixed in 20240203-110809-5046fc22.

@github-actions github-actions bot removed the waiting-on-op Waiting for more information from the original poster label Feb 6, 2024
@wez
Copy link
Owner

wez commented Feb 6, 2024

Please run: wezterm ls-fonts --codepoints 1F784 and share the output

@wez wez added the waiting-on-op Waiting for more information from the original poster label Feb 6, 2024
@LinoWhy
Copy link
Author

LinoWhy commented Feb 6, 2024

output:

wezterm ls-fonts --codepoints 1F784
14:29:52.573  WARN   wezterm_font > No fonts contain glyphs for these codepoints: \u{1f784}.
Placeholder glyphs are being displayed instead.
You may wish to install additional fonts, or adjust your
configuration so that it can find them.
https://wezfurlong.org/wezterm/config/fonts.html has more information about configuring fonts.
Set warn_about_missing_glyphs=false to suppress this message.
LeftToRight
 0 🞄    \u{1f784}    x_adv=10 cells=1  glyph=.notdef,0    wezterm.font("JetBrains Mono", {weight="Regular", stretch="Normal", style="Normal"})
                                      C:\WINDOWS\FONTS\JETBRAINSMONO-REGULAR.TTF, DirectWrite

The picture below is a comparison between Windows Terminal & Wezterm.
image

@github-actions github-actions bot removed the waiting-on-op Waiting for more information from the original poster label Feb 6, 2024
@wez
Copy link
Owner

wez commented Feb 6, 2024

Sounds like the same underlying issue as in, where DirectWrite isn't telling us which font to use:

the workaround is to explicitly list in your wezterm.font_with_fallback list the font that you know contains that codepoint.

@LinoWhy
Copy link
Author

LinoWhy commented Feb 7, 2024

This still occurs with font Cascadia Code. But Windows Terminal with the same font setting doesn't have this issue.
image

It's weird that sometimes when I change the font size in Wezterm, it will show the correct glyphs ever before it's closed. But sometimes it doesn't.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Windows Issue applies to Microsoft Windows
Projects
None yet
Development

No branches or pull requests

2 participants