oh-my-fish / theme-bobthefish

A Powerline-style, Git-aware fish theme optimized for awesome.
MIT License
1.44k stars 223 forks source link

1px lines between powerline glyphs on Windows Terminal #296

Closed kaysond closed 3 years ago

kaysond commented 3 years ago

Describe the problem you are having and how to reproduce it. Include any other additional context that can help us troubleshoot.

I'm using Ubuntu via WSL on Windows Terminal. The powerline glyphs used in bobthefish all seem to have a 1px line between them with a different color.: image image

I've tried multiple nerdfont fonts (using set -g theme_nerd_fonts yes) and multiple color schemes, and its always like this.

Any ideas?

Environment report

Oh My Fish version:   7-29-g9886b88
OS type:              Linux
Fish version:         fish, version 3.1.2
Git version:          git version 2.25.1
Git core.autocrlf:    no
Checking for a sane environment...
bobthecow commented 3 years ago

This comes down to rendering by your terminal app. There's nothing OMF or Fish or bobthefish can do to control that. We just say "print these characters" and hope for the best 😕

I haven't spent a ton of time on WSL and Windows Terminal, but the sort of setting names that might be related are: anti-aliasing (or subpixel anti-aliasing), horizontal letter spacing, "treat ambiguous characters as double-width", switching fonts for powerline or non-ascii characters, "optimize legibility" or anything else that deals with pixel placement for rendered glyphs. You might even get better results by going up or down a font size?

Your best bet is probably toggling as many text rendering settings as you can and seeing if any combination of them fixes it.

kaysond commented 3 years ago

You're right this is definitely a WSL rendering issue as you can see it on their powerline tutorial: https://docs.microsoft.com/en-us/windows/terminal/tutorials/powerline-setup

Setting "useAcrylic": true and "acrylicOpacity" : 0.899 helped the last glyph, but not the first one.

bobthecow commented 3 years ago

Oh! I've seen a thing in another terminal app where allowing background color opacity resulted in compositing errors that looked like this (on any explicitly rendered background color; the window background was fine). The fix was to set the window background to partially transparent, but ensure that characters and background colors were 100% opaque.

kaysond commented 3 years ago

Hmm I think you're right, given that dropping the window background opacity helped. Unfortunately WSL doesn't allow you to set characters/background opacity. I would assume its already 100%, but maybe not...

kaysond commented 3 years ago

See: https://github.com/microsoft/terminal/issues/8993