You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Atm your bar support icons from fontawesome project.
This carry many problems with weird fallbacks which depends on the font set installed by the user (to my knowledge) (I've seen several issues about fontawesome missing/mispatched fonts etc.).
Is it possible/hard to implement the possibility for the user to select a different font for the icons?
I know that this can be performed by using the pango markup as in: "<span font_desc='whateverfont'>your character</span>"
but the configuration will become uite unreadable.
Edit: typo
Edit2: closed and reopened by mistake
Reacted by José Ribeiro, Michael Garate, Rihards Skuja, jeffmakes, Entrapta, Frestein ☁️ and haansn08
Obviously you have to replace with the fonts you want. The problem with this is that some characters, for instance the "Clock" in FA5, render as a ~ in text fonts, and because CSS tests fonts from left to right, Roboto is used to display it.
Maybe there is a way to target only the icon with a selector like #clock .icon. I've tried this one, and it does not work.
Reacted by Vyacheslav Konovalov, sayid and haansn08
I think this is more of a bug, if you set the {icon} placeholder to the left of text with a space in between, the space gets rendered with the icons font, and at least "Material Design Icons" font doesn't have the space glyph (0x0020), so a weird placeholder glyph shows up.
Had also issues with some icons not showing up. I tinkered a while until I found out, that my AUR package ttf-ms-fonts (Arial probably) "overwrote" some glyps (volume-up, down for example).
I tried the suggestion above (put FontAwesome in styles.css). It works, but for me all other characters were now slightly different and colons were misplaced. Not as pretty as before.
I uninstalled ttf-ms-fonts now, and all icons and fonts are as expected.
I want to set this font to the specific module, while I keep JoyPixels as system emoji font. I prefer the non-wavy rectangle flag (Twitter Color Emoji) instead of rounded flag (JoyPixels) and of wavy flag (Apple Color Emoji and Noto Emoji).
I second this. It would be great if all icons were wrapped in <span class="icon">...</span> by default. That way we could explicitly set which font to use for an icon and not have to rely on complicated font fallback behavior.
Reacted by Ghostface, fuzxi, John Connor, Victor Zamanian, akay, annuel, lilithium-hydride, dollil-g, Lena Fuhrimann, heyzec and 9 more
Yes, @gusbemacbe were you able to get a module specific font-family to work?
For me it only seems to pick the main one and ignores the module specific one.
Yes, @gusbemacbe were you able to get a module specific font-family to work?
For me it only seems to pick the main one and ignores the module specific one.
I have tested it a dozen times, but it didn't work. It captures still rounded flags of JoyPixels instead of rectangular flags of Twemoji. I uninstalled JoyPixels and Noto Emoji fonts, left only Twemoji font, and the emojis in that module ended up being tofu.
I second this. It would be great if all icons were wrapped in <span class="icon">...</span> by default. That way we could explicitly set which font to use for an icon and not have to rely on complicated font fallback behavior.
Pango markup doesn’t support <span class="icon">...</span>, so I came up with another workaround: wrapping all icons in the Waybar config in <span font='icon'>...</span> and adding a font “alias” into font-config /etc/fonts/local.conf:
I'll recommend "Symbols Nerd Font" which does not include ascii characters and has many more symbols beyond fontawesome, the next candidate fonts will be used for regular characters.
Reacted by Amin D., Nicolaos Skimas and Hans-Nikolai Viessmann
I use Inter font with Nerd fonts Symbols for the icons and summing with not using mono fonts for GUIs/Interface (waybar for example), I'm having no problems anymore. So I can change from Inter to Iosevka, Cantarell, Fira Sans or any non-monospaced one.
Font Awesome, apparently, but I'm not able to find the corresponding package in Ubuntu repo.
This is because the package is called fonts-font-awesome on Ubuntu and only covers fonts in Font Awesome 4, not 5 or 6. The Ubuntu package is outdated. Try manually installing the font or try looking for a better supported icon font for your distro and replacing the unicodes yourself. In most cases I believe so long as your icon font is installed properly you should be able to use CTRL+SHIFT+U to enter a unicode character corresponding to the font icon you want. I edit from the kitty terminal using neovim and it works flawlessly this way, and provides several ways to search from within the terminal.
Would it be better to use 'real' icons instead of font glyphs? As it will follow XDG Icon Theme Specification and it will match currently used system icon theme?
I made a discussion thread #4713 check it out
Activity
cinghiopinghio commentedon Mar 13, 2019
I know that this can be performed by using the pango markup as in:
"<span font_desc='whateverfont'>your character</span>"but the configuration will become uite unreadable.
Edit: typo
Edit2: closed and reopened by mistake
dtnmr commentedon Mar 13, 2019
You can make it (kinda) work setting your font like this in
style.css:Obviously you have to replace with the fonts you want. The problem with this is that some characters, for instance the "Clock" in FA5, render as a
~in text fonts, and because CSS tests fonts from left to right, Roboto is used to display it.Maybe there is a way to target only the icon with a selector like
#clock .icon. I've tried this one, and it does not work.severoraz commentedon Jul 14, 2019
I think this is more of a bug, if you set the
{icon}placeholder to the left of text with a space in between, the space gets rendered with the icons font, and at least "Material Design Icons" font doesn't have the space glyph (0x0020), so a weird placeholder glyph shows up.cryptoluks commentedon Dec 7, 2019
Had also issues with some icons not showing up. I tinkered a while until I found out, that my AUR package
ttf-ms-fonts(Arial probably) "overwrote" some glyps (volume-up, down for example).I tried the suggestion above (put FontAwesome in
styles.css). It works, but for me all other characters were now slightly different and colons were misplaced. Not as pretty as before.I uninstalled
ttf-ms-fontsnow, and all icons and fonts are as expected.gusbemacbe commentedon Feb 10, 2021
@Alexays and @dtnmr
Does Waybar support his style? For example:
I want to set this font to the specific module, while I keep JoyPixels as system emoji font. I prefer the non-wavy rectangle flag (Twitter Color Emoji) instead of rounded flag (JoyPixels) and of wavy flag (Apple Color Emoji and Noto Emoji).
Hubro commentedon Jul 25, 2021
I second this. It would be great if all icons were wrapped in
<span class="icon">...</span>by default. That way we could explicitly set which font to use for an icon and not have to rely on complicated font fallback behavior.nnuel commentedon Jan 15, 2022
Yes, @gusbemacbe were you able to get a module specific font-family to work?
For me it only seems to pick the main one and ignores the module specific one.
gusbemacbe commentedon Jan 15, 2022
I have tested it a dozen times, but it didn't work. It captures still rounded flags of JoyPixels instead of rectangular flags of Twemoji. I uninstalled JoyPixels and Noto Emoji fonts, left only Twemoji font, and the emojis in that module ended up being tofu.
mrshmllow commentedon Apr 17, 2022
Was this ever opened/implemented?
jirutka commentedon May 1, 2022
Pango markup doesn’t support
<span class="icon">...</span>, so I came up with another workaround: wrapping all icons in the Waybar config in<span font='icon'>...</span>and adding a font “alias” into font-config/etc/fonts/local.conf:[-]ability to define font family for the icons[/-][+]Ability to define font family for the icons[/+]adamant-pwn commentedon Nov 28, 2022
Which font family should cover
"", "", "", "", "", "", "", "", ""? Is itSymbols Nerd Font?mlazzarotto commentedon Feb 1, 2023
Font Awesome, apparently, but I'm not able to find the corresponding package in Ubuntu repo.
xz-dev commentedon Aug 21, 2023
Install firacode-nerdfont also helpful
iceeburr commentedon Dec 10, 2023
Any news or solution on this?
even if it's a really dumb fix I would rather go for it
xz-dev commentedon Dec 10, 2023
I just simply fix it by install fontawesome(6.1.1) and setting
font-family: 'Font Awesome 6 Free';at style.css.rtgiskard commentedon May 8, 2024
I'm using the piece:
I'll recommend "Symbols Nerd Font" which does not include ascii characters and has many more symbols beyond fontawesome, the next candidate fonts will be used for regular characters.
msmafra commentedon Feb 5, 2025
I use Inter font with Nerd fonts Symbols for the icons and summing with not using mono fonts for GUIs/Interface (waybar for example), I'm having no problems anymore. So I can change from Inter to Iosevka, Cantarell, Fira Sans or any non-monospaced one.
all: unset;
font-size: 16px;
font-family: "Inter Variable", "Symbols Nerd Font";
font-feature-settings: '"zero", "tnum", "ss01", "ss02", "ss03", "cv01", "cv05", "cv08", "cv10", "cv11", "cpsp", "case"';
font-weight: 700;
}
D34D4L1V3 commentedon May 2, 2025
This is because the package is called
fonts-font-awesomeon Ubuntu and only covers fonts in Font Awesome 4, not 5 or 6. The Ubuntu package is outdated. Try manually installing the font or try looking for a better supported icon font for your distro and replacing the unicodes yourself. In most cases I believe so long as your icon font is installed properly you should be able to useCTRL+SHIFT+Uto enter a unicode character corresponding to the font icon you want. I edit from the kitty terminal using neovim and it works flawlessly this way, and provides several ways to search from within the terminal.oisanjaya commentedon Dec 24, 2025
Would it be better to use 'real' icons instead of font glyphs? As it will follow XDG Icon Theme Specification and it will match currently used system icon theme?
I made a discussion thread #4713 check it out