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

Unable to find the selected font CaskaydiaCove NF #12587

Closed
va-it opened this issue Feb 26, 2022 · 34 comments
Closed

Unable to find the selected font CaskaydiaCove NF #12587

va-it opened this issue Feb 26, 2022 · 34 comments
Labels
Needs-Tag-Fix Doesn't match tag requirements Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting

Comments

@va-it
Copy link

va-it commented Feb 26, 2022

N.B. I have looked at the other font related issues (e.g. #11648), but I believe mine is slightly different. In my case, the Cascadia Mono font is found without problems.

This issue is occurring in both Terminal and Terminal Preview. I have the CaskaydiaCove NF font installed and I am able to use it on other apps such as WordPad. However, upon starting the Terminal, I receive the "Unable to find the selected font" error.

The problem is temporarily resolved by simply opening the settings and saving, even without changing anything. But then the error is presented once more when the program is closed and opened again.

Windows Terminal Version: 1.12.10393.0
Windows Terminal Preview Version: 1.13.10395.0

terminal_error

terminal_fonts

@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Feb 26, 2022
@zadjii-msft
Copy link
Member

Hmm. This sounds like #9360, but that was duped to #9375 which was supposed to be fixed like, months ago.

Maybe this is a variant of the thing in PR at #12554? (Mind confirming for me @lhecker?)

@lhecker
Copy link
Member

lhecker commented Feb 28, 2022

Maybe this is a variant of the thing in PR at #12554? (Mind confirming for me @lhecker?)

Hmm... no, on Windows 11 this should've worked. The experimental text rendering engine doesn't support proper font fallback, which is why this can't be it either (WT crashes instead of presenting a Warning popup).
This is probably an unrelated issue.

@lhecker
Copy link
Member

lhecker commented Feb 28, 2022

Here's what I did:

The result: It works!
image

Unfortunately this means that I can't reproduce your issue in neither 1.12 nor 1.13.

@va-it
Copy link
Author

va-it commented Feb 28, 2022

Here's what I did:

The result: It works! image

Unfortunately this means that I can't reproduce your issue in neither 1.12 nor 1.13.

Thanks a lot for looking into this guys. I am not sure why I was having that issue, but I have followed the steps described and now I cannot replicate it either.

Sorry for wasting your time, but the issue is now resolved so thanks a lot again 🙏.

@va-it va-it closed this as completed Feb 28, 2022
@va-it va-it reopened this Mar 1, 2022
@va-it
Copy link
Author

va-it commented Mar 1, 2022

Sorry for reopening this, but the issue is back... After restarting the computer the error message appears again.

Maybe there is a problem in Windows and the way fonts are installed? If I search for the font in settings I don't see CaskaydiaCove NF (I believe I could see it yesterday after following @lhecker suggestions).

image

But I can see it (and use it) in WordPad for example

image

@lhecker
Copy link
Member

lhecker commented Mar 1, 2022

@va-it Can you check the old legacy Fonts control panel? You can find it in the start menu by typing "Fonts".
If it's there I'd suggest removing the font and adding it back in.

@va-it
Copy link
Author

va-it commented Mar 1, 2022

@va-it Can you check the old legacy Fonts control panel? You can find it in the start menu by typing "Fonts". If it's there I'd suggest removing the font and adding it back in.

Ok, so I deleted the font via the Control Panel and installed it again. Predictably, I could see the font in various apps and the new Settings, and I was able to use it in Terminal.
Then I have restarted the computer, and again the font is not visible in Settings and cannot be used in Terminal.
When I try to install it again (without removing it first from Control Panel) I am told that it's already installed.

I believe something is wrong with Windows 11...

@lhecker
Copy link
Member

lhecker commented Mar 1, 2022

@va-it Is your "Windows Font Cache Service" running? Which .ttf file from the nerd fonts collection are you using specifically?

@va-it
Copy link
Author

va-it commented Mar 1, 2022

The service is running and the .ttf is the one you suggested yesterday: Caskaydia Cove Nerd Font Complete Mono Windows Compatible.ttf

image

@lhecker
Copy link
Member

lhecker commented Mar 1, 2022

I can find various internal feedback that fonts are lost after a restart. One particular issue seems to occur if you install fonts via drag and drop in the settings app.

Did you try installing these fonts using this?
image

If it works correctly, fonts should end up in C:\Users\<username>\AppData\Local\Microsoft\Windows\Fonts.
If they aren't there, something is wrong...

@zadjii-msft
Copy link
Member

something makes me think this is like #3257

@va-it
Copy link
Author

va-it commented Mar 1, 2022

I can find various internal feedback that fonts are lost after a restart. One particular issue seems to occur if you install fonts via drag and drop in the settings app.

Did you try installing these fonts using this? image

If it works correctly, fonts should end up in C:\Users\<username>\AppData\Local\Microsoft\Windows\Fonts. If they aren't there, something is wrong...

@lhecker Yes, I have always installed the font using the Install button. The font is in the AppData folder even after restarting the computer, but the error is still there.

Thanks @zadjii-msft. I have read the comments in that thread and I have now installed the font using the "Install for all users" options. After restarting the computer, I don't have the problem anymore.

I thought it worth mentioning that the "Install for all users" option is not available in the new style right-click menu, so this is a very obscure workaround.

But it solved the problem, so many thanks again to both of you for your time 🙂.

@lhecker
Copy link
Member

lhecker commented Mar 1, 2022

@va-it I'll try to escalate one of the internal issues we have (or create one if needed) based one the information you've given us.
In the meantime I'll close this issue and if anything comes up I'll report back here. 🙂

@AkariiinMKII
Copy link

I've suffered this issue since updated to Windows 11, I believe that's the problem of system. Fortunately restarting font cache service solves this on my machine till next boot up.

@Yastruhank
Copy link

I've suffered this issue since updated to Windows 11,

I've suffered this issue since I updated my Windows 11 to 22H2 too. I guess this is the problem of update with Windows 11.

@teeroddesigns
Copy link

I have the same issue. Restarting the Windows Font Cache Service also works for me.

@fredizzimo
Copy link

For me it also started after the Window 11 22H2 update. It seems like it looses all user installed fonts.

The old control panel still shows the fonts, but they are missing from the new set settings Personalization/Fonts and Windows programs.

Like above, restarting the Windows Font Cache Service, seems to make it work again.

@alecthegeek
Copy link
Contributor

I now have this problem, and restarting the Font Cache Service did not fix it :-(.

Happy to run any diagnostics people suggest, meanwhile I will keep pooking it

@GlennWo
Copy link

GlennWo commented Dec 24, 2022

I was having this problem as well on Windows 11. I tried lots of things which stopped working after reboot. I finally found this solution which worked for me.

https://answers.microsoft.com/en-us/windows/forum/all/solution-installed-fonts-disappearing-after/146f4039-47c3-4017-a9b1-76f72badce39

  1. Press Windows Key + R to open the Run dialog
  2. Paste %LOCALAPPDATA%\Microsoft\Windows\Fonts and press Enter
  3. You should see all your installed fonts, press Ctrl + A to select all the font files
  4. While all the files are selected, right click any one of the files and press "Install for all users", not "Install" (with the shield icon, requires administrator privileges)

@johanvanmol
Copy link

Thank you @GlennWo . This worked for me. Like a lot of other commenters, I was restarting the FontCacheService at least daily. I even created a small batch script for this. Your solutions is way better: a one time fix that takes care of this problem.

@ChromaticRanger
Copy link

I was having this problem as well on Windows 11. I tried lots of things which stopped working after reboot. I finally found this solution which worked for me.

https://answers.microsoft.com/en-us/windows/forum/all/solution-installed-fonts-disappearing-after/146f4039-47c3-4017-a9b1-76f72badce39

  1. Press Windows Key + R to open the Run dialog
  2. Paste %appdata%..\Local\Microsoft\Windows\Fonts and press Enter
  3. You should see all your installed fonts, press Ctrl + A to select all the font files
  4. While all the files are selected, right click any one of the files and press "Install for all users", not "Install" (with the shield icon, requires administrator privileges)

A small addition. If you try this and get confused that you are not seeing "Install for all users". You need to be holding down the Shift key when right clicking on the selected files. You will then see that option in the displayed menu.

@MrKomputerKid
Copy link

I was having this problem as well on Windows 11. I tried lots of things which stopped working after reboot. I finally found this solution which worked for me.

https://answers.microsoft.com/en-us/windows/forum/all/solution-installed-fonts-disappearing-after/146f4039-47c3-4017-a9b1-76f72badce39

1. Press Windows Key + R to open the Run dialog

2. Paste %appdata%..\Local\Microsoft\Windows\Fonts and press Enter

3. You should see all your installed fonts, press Ctrl + A to select all the font files

4. While all the files are selected, right click any one of the files and press "Install for all users", not "Install" (with the shield icon, requires administrator privileges)

Amazing! Thank you! This worked for me on my PC at home! Once again thank you!

@4N7
Copy link

4N7 commented Sep 13, 2023

The replies in this issue contain a malformed path.
Here's the instructions with the correct path and pretty formatting 🙂:

  1. Press ⊞ Win + R to open the Run dialog
  2. Paste %appdata%\..\Local\Microsoft\Windows\Fonts and press Enter
  3. You should see all your installed fonts in file explorer. Select the desired font(s) (press Ctrl + A to select all).
  4. With the desired fonts selected, right-click one of the files and click "Install for all users" (NOT "Install") next to the shield icon (requires administrator privileges). If you do not see "Install for all users", hold down Shift before right-clicking.

@Hoernchen
Copy link

This is still a problem, btw. Maybe adding a hint to the error popup would help?

@DHowett
Copy link
Member

DHowett commented Nov 16, 2023

This is still a problem, btw. Maybe adding a hint to the error popup would help?

Which version of Terminal are you on? We just published an update that should fix this.

@Hoernchen
Copy link

The current store version, 1.18.2822.0 - it is too late to try the preview, because I manually fixed it as described in #12587 (comment)

@anatilopan
Copy link

anatilopan commented Dec 5, 2023

Which version of Terminal are you on? We just published an update that should fix this.

Hello, I have the same issue (and some of my friends too). After testing a theory.. I found out that only the versions installed via Microsoft Store have this issue.
I tried the preview (v. 1.19.231113002-preview) version installed from ms. store and the same issue appeared;
Tired the preview version manually downloaded and put under program files directory (to be in the same zone as the ms. store one) and I could not reproduce the issue.
Same for the current stable version (v. 1.18.3181.0)

So I have new theories but i cannot confirm them right now as i do not own a Windows machine myself. (the one I've tested the theory is from work and i cannot make the necessary changes on it)

  1. Somewhere the way that store apps are run/installed does not have the proper permissions to check user's installed fonts.
  2. There is some GPO/administrative setting in my company that restricts store apps to have access to the fonts.

There could be other things but frankly, i'm not a windows user and do not know a lot about it.. and i do not have a lot of time for testing those issues right now even if i'm an administrator on this machine, sorry for that.

Hope it helps somewhat... Have a nice day! ^^

@Gonkers
Copy link

Gonkers commented Dec 6, 2023

This is still a problem, btw. Maybe adding a hint to the error popup would help?

Which version of Terminal are you on? We just published an update that should fix this.

I just decided to try Oh-My-Posh and I ran into this issue today. I had to install the fonts into c:\windows\fonts in order to get this working. I have installed Windows Terminal via winget
Windows Terminal Preview
Version: 1.19.3172.0

Windows 11 23H2

Edit: Never mind, I'm back at square one, I thought I had it working, but Terminal cannot find the fonts. Visual Studio 2022 sees them and uses them just fine.

@NewtonChutney
Copy link

I have recently been seeing more of this issue:

Unable to find the selected font "FiraCode Nerd Font Mono".

"Consolas" has been selected instead.

Please either install the missing font or choose another one.

WT version: Windows Terminal - Version: 1.18.3181.0
winver - Microsoft Windows [Version 10.0.22631.2861]

Looks like whatever fix was pushed didn't completely solve the issue..

I installed the fonts by dragging and dropping into the fonts section in both control panel and Settings UWP. I see that the fonts are installed in `%LOCALAPPDATA%\Microsoft\Windows\Fonts`. They are still visible in control panel after a restart, but not in Settings UWP.

Settings UWP:

image


%LOCALAPPDATA%\Microsoft\Windows\Fonts:

image


Control panel

image

@lhecker
Copy link
Member

lhecker commented Jan 8, 2024

Looks like whatever fix was pushed didn't completely solve the issue..

Just to be clear, this was never fixed by us. It's a bug in Windows font handling code and affects any store application. Follow these steps instead: #12587 (comment)
To add, you should also make sure to delete all fonts from %LOCALAPPDATA%\Microsoft\Windows\Fonts if you can, since those don't work consistently correct anyways.

@NewtonChutney
Copy link

Just to be clear, this was never fixed by us. It's a bug in Windows font handling code and affects any store application. Follow these steps instead: #12587 (comment)
To add, you should also make sure to delete all fonts from %LOCALAPPDATA%\Microsoft\Windows\Fonts if you can, since those don't work consistently correct anyways.

Yep, I had installed for all users and removed those in my (user's) localappdata..
But, this wouldn't be a solution for the enterprise lot.. They wouldn't have admin privileges..

Now I think of it.. I don't remember seeing the font not found prompts on my non-admin enterprise user account.. 🤔
I'll check and comment again

@dlplenin
Copy link

dlplenin commented Aug 8, 2024

I had the same issue (with a different font) after installing Docker on Windows 11.

The solution was to reset the app:
image

I hope this helps someone in a similar situation.

UPDATE:
This works after restarting the terminal, but after restarting the PC the error is still there.
Since my problem was with ohmyposh, I installed the font for all users by running the terminal as Administrator, which fixed the problem:
image

@DonutWrecker
Copy link

#14231 (comment)

The solution in the link solved my issue.

@ignatirabo
Copy link

ignatirabo commented Nov 4, 2024

#12587 (comment)

Comment above fixed the issue. Problem is still present with Terminal 1.21.2911.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs-Tag-Fix Doesn't match tag requirements Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting
Projects
None yet
Development

No branches or pull requests