ryanoasis / nerd-fonts

Iconic font aggregator, collection, & patcher. 3,600+ icons, 50+ patched fonts: Hack, Source Code Pro, more. Glyph collections: Font Awesome, Material Design Icons, Octicons, & more
https://NerdFonts.com
Other
53.81k stars 3.63k forks source link

Icons overlap other text, Propo doesn't work #1703

Closed keliss closed 1 week ago

keliss commented 1 week ago

Requirements

Experienced Behavior

Hello. Maybe someone raised this in the past, but I couldn't find a definitive answer. The only font with icons I'm using is JetBrainsMono installed through the Arch package repository. This font is set to be used by my terminal (foot): image

And for some reason, I cannot get rid of icons overlapping with other symbols in my terminal: image

Note that I tried the "plain" variant of that font as well (without the word Propo) and the result doesn't change. If I set the font to Mono, the icons become too small: image

Expected Behavior

Icons are big enough when using Propo/normal font variant, and they don't overlap any other symbols.

Thank you.

Example Symbols or Text

\uf269 - firefox icon is a good example.

Font Used

JetBrainsMono Nerd Font Propo/JetBrainsMono Nerd Font/JetBrainsMono Nerd Font Mono

Source of Font File

https://archlinux.org/packages/extra/any/ttf-jetbrains-mono-nerd/

Terminal Emulator (and the title of the terminal window)

foot

Operating System and Version

Arch Linux (btw)

Screenshots

No response

keliss commented 1 week ago

By the way, setting the Symbols font as the first one to be used (downloaded from https://archlinux.org/packages/extra/any/ttf-nerd-fonts-symbols/) as advised here https://github.com/polybar/polybar/issues/991 doesn't help either, still getting the icon overlap.

Finii commented 1 week ago

Sorry to hear of your problem!

Hmm, the glyph itself is not defective; the cursor advance width is indicated by the two vertial black helper lines:

Screenshot 2024-09-02 at 06 29 59

Nerd Font Propo

Screenshot 2024-09-02 at 06 32 58

Nerd Font ("normal")

I do not know foot. Maybe you can try the proportional font in a non-terminal application like Libreoffice Writer. Terminals usually can not by design have glyphs wider than one 'cell' because that would break the row-and-columns grid that people expect from terminals. So what you want is in principle not possible and does not have anything to do with the font. That is the reason why we have Mono. If the icons are too small the only possibility for environments where the cursor advance width is fixed (like in terminals) is to add a blank after the icon if it is bigger than one cell. But that is a limitation of the terminal or this is what is expected of terminals.

Maybe some more light can be shed on the issue with https://github.com/ryanoasis/nerd-fonts/discussions/1103

Maybe you can report back your findings of the Writer test.

Another thing to try is using JetBrainsMono NFP as family name instead of the long form JetBrainsMono Nerd Font Propo. I doubt that that is the problem; I expect you just hit on a terminal emulator limitation.

keliss commented 1 week ago

Thank you for the detailed response @Finii, apparently, this is indeed a terminal issue, because nothing helps. I think we close this.