9

In my settings I have:

"editor.fontLigatures": true,
"editor.fontFamily": "Fira Code, Comic Sans MS, Tahoma, Consolas",

and I've tried (according to this) different combinations of apostrophes, spaces and capitalization. No matter what I do, I get Comic Sans to pop (or some plain, weird junk if I only specify Fira Code with no secondary font.

I verified that I've installed all the fonts from their GitHub and I can see the fonts in the list in my text processor (of course they do look as supposed to when typed with said font too). I also tried sweeten up the process using choco install FiraCode, reported as successful.

The ligatures are turned set to true, as shown above. The latest version of VSC is installed and the system is rebooted to the borders of ridiculity. I have almost no extensions and those few I had, I deactivated.

What else can I do to troubleshoot the issue?

Konrad Viltersten
  • 36,151
  • 76
  • 250
  • 438
  • I would completely uninstall Fira Code - all versions - there was a v1 and lately a v2 - and then install only v2 (on my machine it doesn't work to have both versions installed). – Mark Mar 30 '20 at 15:46
  • @Mark You don't say? Didn't hear anything about that at all. How does one uninstalls all versions of FireCode on Windows? And how do I make sure that I'm installing the newer version afterwards? Also, isn't it weird that MS Word can find the font and use it, if it's the old (or both) version that are isntalled on my system? – Konrad Viltersten Mar 30 '20 at 19:25
  • Go to your Settings/Font Settings. Search for "Fira Code" - click on the entry. I think you should have no more than 5 font faces listed fro Fira Code (Light ... Retina) and it should say version 2. There is an uninstall button there. If you have anything in addition to Fira Code v2 and 5 font faces I would uninstall them all, reboot Windows and reinstall just v2 - probably another reboot afterwards too. – Mark Mar 30 '20 at 19:34
  • I'm assuming you saw this: https://github.com/tonsky/FiraCode/wiki/Installing – Mark Mar 30 '20 at 19:42
  • I'd suggest manually resetting windows 10 font cache which involves shutting down some windows services and deleting some files (i trust you can google). Also rather than default fira code it may be worth trying some other alternatives, [specifically these ones](https://www.nerdfonts.com/) that have ligatures but are also powerline patched for use in the terminal. For fonts with ligatures i'd suggest Cascadia Code (and derivative) or Victor Mono. You can also try Fura Code (not a typo). – marblewraith Mar 30 '20 at 19:57
  • @Mark Please post your comments as an answer to be accepted. – Konrad Viltersten Mar 31 '20 at 16:57
  • Glad to see you got it working. Did you have Fira Code v1 and v2 both installed? – Mark Mar 31 '20 at 20:03

8 Answers8

13

In my case I downloaded Fira Code v2 without first uninstalling v1. And I don't think it will ever work with both versions installed. So in Windows, go to your Settings/Font Settings and search for Fira Code - there will be an uninstall button there.

After installing v2, (install instructions https://github.com/tonsky/FiraCode/wiki/Installing) the variants you installed like Light, Regular, Medium,BoldandRetina` for example will be listed along with the version number.

Then I would definitely reboot your computer before trying to get Fira Code and font ligatures working in vscode. Also see vscode: update to stylistic sets using font ligatures with Fira Code for some gothchas with ligatures.

Then after changing the font face in vscode I would reload vscode too. These settings work for me:

"editor.fontFamily": "Fira Code",
"editor.fontLigatures":"'zero', 'ss02', 'ss03', 'ss04', 'ss05', 'calt'",

if you want the other stylistic sets that Fira Code offers. The calt on the end was necessary to make most of the rest work for some reason. See the SO question link just above for more on that.

Mark
  • 143,421
  • 24
  • 428
  • 436
7

I was having this same issue and instead of using Fira Code I used fira code and then I restarted VS Code and then I had the expected fonts in the editor.

Dom Hallan
  • 1,057
  • 1
  • 8
  • 16
5

hi use this settings just select fira code font only

"editor.fontFamily": "Fira Code",
"editor.fontLigatures": true,

and download this font https://github.com/tonsky/FiraCode/blob/master/distr/otf/FiraCode-Bold.otf

Nadim Al Abdou
  • 768
  • 7
  • 13
  • Not sure how it's supposed to work. The hint on list of font faces only containing Fira Code makes no sense, because the one past the located font are ignored. The font from OTF instead of TTF are just different kind of format, not commonly used in VS Code. Do you have a reference to an article stating otherwise or was this just a wild shot in the dark? (Oh, to be clear - I tested your suggestion confirming that it's not resolving the issue at hand.) – Konrad Viltersten Mar 30 '20 at 06:25
  • i just shared my settings https://imgur.com/BHmLtkx & https://imgur.com/YcheI47 – Nadim Al Abdou Mar 30 '20 at 06:32
  • Ah, I see. If it would be that easy, it would work based on the link I provided. Regrettably, it's not and the question is, as you might have noticed, *what **else** can I do to **troubleshoot*** not *how to activate it*, which in this case makes a lot of difference. For some reason, it doesn't work as as usually expected and I'm stuck on what to try **other than** what I described. Thanks for trying, though. – Konrad Viltersten Mar 30 '20 at 06:35
  • It works for me. Just edited the `settings.json`. – Blues Clues Jun 20 '21 at 08:49
2

I followed the direction to right click on each font and choose install as per direction https://github.com/tonsky/FiraCode/wiki/Installing

My fonts didn't show up tried rebooting, Changing from "Fira Code" to "fira code" and tried "'Fira Code'" in settings.json.

What worked for me on Windows 10 VSCode 1.71.2 was unpack the Fira Code fonts and right click on them and choose Install for all users

enter image description here

1

I had the same problem, and restarting the system (Windows 10) after installing the font fixed it.

1

the simple solution is that you should edit settings.json in Workspace not Userimage

VietPham
  • 11
  • 1
0

I used this

"editor.fontLigatures": true,
"editor.fontFamily": "'Cascadia Code'"

worked for me don't know why

Rami Jamleh
  • 1,819
  • 1
  • 13
  • 10
0

In Windows go to Settings > Fonts

Windows_Font_Settings

  1. Enter your font name. In this case it's Fira Code
  2. Grab the exact name and now go to VS Code and open the settings.json file
  3. Append the following.
  4. Save the file and you would see the font change instantly (happened in my case) if not just restart VS Code.
"editor.fontFamily": "'FiraCode Nerd Font Mono'",
"editor.fontLigatures": true

Hope this helps as it worked for me because I installed this font from Nerd Fonts and it had a different name.

  • Is there a reason why not get the fonts from Tonsky, the original creator and copyright owner? As far I could see, the page you linked to has no mentioning of him, which resembles plagiarism (and possibly self-promotion). Please explain. – Konrad Viltersten Jun 11 '23 at 13:58
  • I have similarly named font files on macOS from brew, FWIW. – karl Jul 16 '23 at 12:23