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

Some icons not showing (nvim-tree, bufferline, etc.) #4107

Closed
lunacd opened this issue May 1, 2023 · 12 comments · Fixed by #4111
Closed

Some icons not showing (nvim-tree, bufferline, etc.) #4107

lunacd opened this issue May 1, 2023 · 12 comments · Fixed by #4111
Labels
bug Something isn't working

Comments

@lunacd
Copy link

lunacd commented May 1, 2023

Problem description

Lots of icons are not showing properly.

LunarVim version

release-1.3/neovim-0.9-e823ccb

Neovim version (>= 0.8.0)

0.9.0

Terminal name

Windows Terminal

Operating system/version

Windows 11

Steps to reproduce

Note: I use NerdFont v3.0.0, so that might be the issue. Because I don't see this issue being tracked on another issue, I might as well just open one.

  1. Open lunarvim
  2. Open two buffers
  3. Open nvim-tree

Screenshots

image

@lunacd lunacd added the bug Something isn't working label May 1, 2023
@kobzar
Copy link

kobzar commented May 1, 2023

Install nerd fonts in your system, reboot windows.
Select Nerd font in terminal app for example "Hack Nerd Font Mono"
Thats all.
Also try another terminal app like alacritty, kitty.

@lunacd
Copy link
Author

lunacd commented May 1, 2023

I am using NF. Notice, for example, that the orbit icon on the bottom left renders properly.

And thanks for recommending other terminal emulators. Kitty unfortunately does not run on Windows. So, here is the reproduction using Alacritty:

image

@kobzar
Copy link

kobzar commented May 1, 2023

Not all Nerd fonts has needed gplyps. More info you can find here #539
try this one for alacritty

font:
  normal:
    family: Hack Nerd Font Mono
    style: Regular

  bold:
    family: Hack Nerd Font Mono
    style: Bold

  italic:
    family: Hack Nerd Font Mono 
    style: Italic

  bold_italic:
    family: Hack Nerd Font Mono 
    style: Bold Italic

@niflostancu
Copy link

Happened to me today on Arch Linux after upgrading ttf-sourcecodepro-nerd from 2.3.3 to 3.0.0.

Only missing a few icons (default folder in nvim-tree being the most annoying)...

Also see the changelog for nerd-fonts has some breaking changes [1].
The lvim.icons table probably uses some of those dropped code points.

[1] https://github.com/ryanoasis/nerd-fonts/releases/tag/v3.0.0

@cpea2506
Copy link
Member

cpea2506 commented May 2, 2023

Please copy this line into your config.lua

lvim.icons.ui.Folder = "󰉋"

Does this bring back your folder icon?

@niflostancu
Copy link

I also had to replace nvimtree's glyph:

lvim.icons.ui.Folder = "󰉋"
lvim.builtin.nvimtree.setup.renderer.icons.glyphs.folder.default = lvim.icons.ui.Folder

The folder renders fine ;)

@kobzar
Copy link

kobzar commented May 2, 2023

VoidLinux, ArchLinux, OsX
lvim 1.3
Alacritty
Hack Nerd Font Mono
(I'm never use any NerdFont installers. Just download the few fonts from https://www.nerdfonts.com/font-downloads
and extract it to .local/share/fonts or c:windows\fonts and dont update it more one years)

lvim.builtin.nvimtree.setup.renderer.icons.show.git = true
lvim.builtin.nvimtree.setup.renderer.icons.glyphs.git = { staged = "✓", untracked = "★" }

image

@joshukraine
Copy link

FWIW, I experienced this same issue today after upgrading to NerdFonts v3. It really broke a lot of icons, even basic ones like the folder icon. 😐 As a stopgap, I went back to grab a version of FiraCode from v2.3.3 and installed it manually. This works for now. BUT, the reason this is happening has to do with icon codepoints that have been dropped, specifically from Material Icons. (see explanation in NF v3 release notes)

The problem is that plugins like NvimTree and probably Bufferline will have to implement changes to account for the icon updates. NvimTree already has a PR pending and Bufferline will likely follow suit. Once those are merged, people using v2 versions of nerd fonts will see breaks again and have to upgrade.

Not really sure at what level this will need to be addressed with LunarVim, but I think sooner or later changes will be needed. 🤷🏻‍♂️

More info here: ryanoasis/nerd-fonts#1190

@kobzar
Copy link

kobzar commented May 3, 2023

Sorry, but this not look like neovim or fonts problem. On my VoidLinux the stable nerd is still 2.xx. I was write twice, remove pkg and install just for test selected fonts by manual. And all will work. So problem not in fonts - problem in broken pkg. So issue must be opened on NerdFonts git.

@Hermanverschooten
Copy link

My nerdfonts - installed by homebrew - were recently upgraded to v3, now I am missing a number of icons, even on the first page when you open LunarVim, Find file, Find Text and Quit all are missing. I tried the Hack Nerd font mentioned above, but nothing changed.

@kobzar
Copy link

kobzar commented May 3, 2023

One more time:
Thi is NOT LunarVim problem.
Problem with last 3.x release of NerdFonts.
ryanoasis/nerd-fonts#1190

For example i just download fonts directly from here
https://www.nerdfonts.com/
ComicShannsMono.zip extract it to ~/.local/share/fonts
run "fc-cache -f -v" and select it om wezterm
All icons look fine
image

@brneor
Copy link

brneor commented May 3, 2023

One more time:
Thi is NOT LunarVim problem.

I don't know... Lunarvim requires a nerd font. Nerd font updates and mark glyphs at some codepoints as obsolete. Nerd font updates again and remove the glyphs previously marked as obsolete. Lunarvim does not update to use the new codepoints. As Lunarvim does not require a specific version of nerd fonts, looks like a Lunarvim problem for me.

But it's okay, looks like it's being fixed in #4111 so probably everything will be all right soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants