devblackops / Terminal-Icons

A PowerShell module to show file and folder icons in the terminal
MIT License
2.32k stars 104 forks source link

Icons not displayed correctly in PS 7 terminal nor in windows terminal #71

Open eliassal opened 2 years ago

eliassal commented 2 years ago

After installing the icons, I fire a new powershell 7 terminal but icons does not display correctly

Expected Behavior

icons expected to display according to items in LS command

Current Behavior

See snapshot below in windows terminal as well as powersll 7 terminal

Your Environment

TerminalIcons

Zakauchocolat commented 2 years ago

Yeah i have the same issue

Decimation commented 2 years ago

Same issue here.

rbullers commented 2 years ago

It's working for me on Windows 11 with PS7 and Windows Terminal

image

Have you guys installed and selected a Nerd Font to use?

Windows Terminal: Settings > Profiles > Powershell > Appearance > Font Face

image

Powershell 7: Right Click on Title Bar > Properties > Font

image

Decimation commented 2 years ago

@rbullers I'm already using a Nerd Font.

WindowsTerminal_PNZeVLVcvG

The glyphs display, but with artifacts:

WindowsTerminal_gPPG87Ozm4

WindowsTerminal_nfaBU0ETzd

This happens regardless of zoom settings, font settings, different fonts, etc.

rbullers commented 2 years ago

@Decimation Do you experience the same behaviour when running Powershell directly?

Decimation commented 2 years ago

@Decimation Do you experience the same behaviour when running Powershell directly?

Yes.

rbullers commented 2 years ago

@Decimation I think your issue is with Nerd Fonts or Oh my posh - rather than a Terminal-Icons issue.

Decimation commented 2 years ago

@Decimation I think your issue is with Nerd Fonts or Oh my posh - rather than a Terminal-Icons issue.

That's what I've been thinking. I'm guessing it's something to do with font rendering, kerning, antialiasing, etc. Any ideas?

rbullers commented 2 years ago

@Decimation Which Nerd Font are you using and which version of oh-my-posh do you have? Will see if I can reproduce.

Decimation commented 2 years ago

conhost_6xmksnGSe2

I've tried InconsolataLGC NF, Inconsolata NF, Consolas NF, Roboto Mono NF, and a few other fonts.

oh-my-posh version is 7.37.2

rbullers commented 2 years ago

@Decimation

So it appears I have the same exact issue when using just pwsh.exe

image

However, when using Windows Terminal with a configured profile for pwsh.exe, everything works as expected.

image

Do you have a profile setup for Powershell in Windows Terminal? You should see something similar in your drop down..

image

Decimation commented 2 years ago

Yes, my Windows Terminal is already configured accordingly.

mattcargile commented 2 years ago

I think wt.exe is the recommended terminal to use instead of conhost.exe. The screenshot showing the issue looks like conhost.exe, @Decimation .

shortthirdman commented 11 months ago

@Decimation @eliassa @mattcargile I have been facing the same issue in my configuration after I upgraded Oh-My-Posh and Terminal-Icons recently. Icons for a directory on the prompt don't appear correctly. Please suggest where to look to for a possible misconfiguration.

image

Decimation commented 11 months ago

@shortthirdman @mattcargile @eliassal:

After revisiting this, I still have the same issues as I originally described here.

Fresh install of oh-my-posh, up-to-date modules, etc. Windows Terminal is configured correctly, and the NF font I'm using is Consolas NF.

WindowsTerminal_2023-08-05_(13h59m31s)_MFh18UwmYJ

However, Terminal-Icons (appears) to work, and if I remember correctly, this is nothing new.

WindowsTerminal_2023-08-05_(14h06m11s)_NLC9AIGUVt

I haven't bothered trying to fix the issues since my initial bug report and the fresh install just now, so I can't offer any help, sorry.

shortthirdman commented 11 months ago

@Decimation Looks like some font icon names have got changed or likewise. The developer of this module can only comment on the same. I am seeing this icon issue recently after I have upgraded to the latest versions of Oh-My-Posh and Terminal-Icons keeping my initial configurations intact. @devblackops Please comment your thoughts.

shortthirdman commented 11 months ago

Got it resolved. Please head to JanDeDobbeleer/oh-my-posh 's #4129

ndeeH commented 11 months ago

I tried installing the latest version of Caskadia Cove Nerd Font but still some common icons are not displayed - others are: image

nickwelsh1 commented 10 months ago

for me I was setting a nerd font as a default, but hadn't realised another font was applied to the Powershell 7 appearance, which was overriding the default. If I'd opened the settings.json that might have been easier to spot.

Another issue I'd had was by copying a file over a cloud drive it had renamed it slightly by removing the first character of my theme filename which was a ".".

kunalshah017 commented 2 weeks ago

For me same problem was happening in Terminal, as font was already set to Firacode in appearance but font was not showing in powershell 7.

FIX: Remove the default powershell 7 profile set in terminal and create a custom Powershell 7 profile yourself by adding a new empty profile and Use this command line - C:\Program Files\PowerShell\7\pwsh.exe

Set the nerd font for this newly added profile and it will work properly

image

Decimation commented 2 weeks ago

I believe this is ultimately caused by an issue with Windows Terminal as described in this issue. The fix is to be included in 12.1 which should release soon.