wez / wezterm

A GPU-accelerated cross-platform terminal emulator and multiplexer written by @wez and implemented in Rust
https://wezfurlong.org/wezterm/
Other
17.28k stars 781 forks source link

The unicode glyph u2630 (Trigram for heaven) does not render on Ubuntu 22.04 X11 #2660

Closed themadsens closed 1 year ago

themadsens commented 1 year ago

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

Linux X11

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

Cinnamon on Ubuntu 22.04

WezTerm version

wezterm 20221019-200013-cc4a155a

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

The unicode glyph u2630 (Trigram for heaven) does not render on Linux X11. Works fine on MacOS. This is a standard glyph in the vim "airline" plugin and I believe similar ones As can be seen, it works perfectly in gedit with the same font. Also tried adding 'Arial unicode MS' as a fallback, which I know for sure includes this glyph

To Reproduce

Attempt to use this glyph in any conext. Ie. paste from here:

Configuration

return { font = wezterm.font('Monospace'), }

Expected Behavior

No response

Logs

Debug Overlay
wezterm version: 20221019-200013-cc4a155a
OpenGL version: Mesa Intel(R) HD Graphics 520 (SKL GT2) 4.6 (Compatibility Profile) Mesa 22.0.5
Enter lua statements or expressions and hit Enter.
Press ESC or CTRL-D to exit
17:22:40.181 WARN wezterm_font > No fonts contain glyphs for these codepoints: \u{2630}.
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.

Anything else?

See missing glyph after in the statuslines. And rendered in gedit in the same font

image

wez commented 1 year ago

Please run:

wezterm ls-fonts

and then:

wezterm ls-fonts --codepoints 2630

and

fc-list ':charset=2630'

and share the output from each of those.

After that: Monospace is a bit of a special case font name. Can you try explicitly setting the actual font that you want to use and see if that works better?

themadsens commented 1 year ago

Thanks for that! I had copied "Arial Unicode MS" from my Mac as I know this to include the glyph, but no matter what I tried, it would not work. However the commands you suggested seems to have rehashed the font machinery somehow and now it works!

The 'Monospace' font is the system default which i tried for max compliance. it seems to be an alias for "DejaVu Sans Mono" though. The attached "output1.txt" is with the font set to "Monospace" The attached "output2.txt" is with the font set to my preference "Monaco Nerd Font Mono" As can be seen in "output2.txt", the missing glyph can now be found in "Arial Unicode MS" which is set as a fallback.

Thanks again. I'll close the issue with this comment

output1.txt

output2.txt

fc-list.txt

The glyph in all its glory at lower right corner image

github-actions[bot] commented 1 year ago

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.