Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Font Awesome and fontconfig
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
BWStevens
n00b
n00b


Joined: 10 Jun 2015
Posts: 61
Location: Hobart

PostPosted: Sat Sep 08, 2018 3:29 pm    Post subject: Font Awesome and fontconfig Reply with quote

Hi community,

I'm running Bspwm with polybar and I have been trying for the last couple of days to get workspace icons in the bar.
I've installed font awesome and everything is set correctly but I cannot get them to all show up.
I've checked fc-list and they are definitely installed but when I type fc-match awesome I get a strange result

fc-match awesome LiberationSans-Regular.ttf: "Liberation Sans" "Regular"

It seems like freetype is thinking font awesome is Liberation Sans
Do I need to use eselect fontconfig to set something. I've looked in the list but I cant see anything about font awesome.
Thankyou for your time and patience

Respectfully

Brett Stevens
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 783
Location: usually offline

PostPosted: Mon Sep 10, 2018 2:46 am    Post subject: Reply with quote

Interesting! I get
Code:
$ fc-match awesome
DejaVuSans.ttf: "DejaVu Sans" "Book"


I have had many issues with the newer fontawesome-5.x packages. Downgraded back to fontawesome-4.7.0. Try that version?
I am thinking of moving away from fontawesome, but for lack of alternatives. I use i3wm.


Last edited by josephg on Tue Sep 11, 2018 12:32 am; edited 1 time in total
Back to top
View user's profile Send private message
v_andal
Guru
Guru


Joined: 26 Aug 2008
Posts: 541
Location: Germany

PostPosted: Mon Sep 10, 2018 7:00 am    Post subject: Reply with quote

I'd say such things are quite normal for fontconfig. It is designed to find matching font, not the one the user wants :roll:

In this case one should try

Code:

fc-match 'Font Awesome 5 Free'


Looks like this is the name that the font is using now (obtained from fc-list output).
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 783
Location: usually offline

PostPosted: Mon Sep 10, 2018 12:37 pm    Post subject: Reply with quote

Code:
$ fc-match 'Font Awesome 5 Free'
DejaVuSans.ttf: "DejaVu Sans" "Book"

Code:
$ fc-list | grep -i awesome
/usr/share/fonts/fontawesome/FontAwesome.otf: FontAwesome:style=Regular
/usr/share/fonts/fontawesome/fontawesome-webfont.ttf: FontAwesome:style=Regular

_________________
"Growth for the sake of growth is the ideology of the cancer cell." Edward Abbey
Back to top
View user's profile Send private message
The Main Man
Veteran
Veteran


Joined: 27 Nov 2014
Posts: 1165
Location: /run/user/1000

PostPosted: Mon Sep 10, 2018 12:59 pm    Post subject: Reply with quote

Maybe you should try Nerd fonts, it includes Font Awesome as well as many other icons.
I use that one for polybar and urxvt, never had any problems.

https://github.com/ryanoasis/nerd-fonts
Back to top
View user's profile Send private message
v_andal
Guru
Guru


Joined: 26 Aug 2008
Posts: 541
Location: Germany

PostPosted: Tue Sep 11, 2018 6:53 am    Post subject: Reply with quote

And this is what I get:

Code:

9:21 % fc-list | grep -i awesom
/usr/share/fonts/fontawesome/fa-regular-400.ttf: Font Awesome 5 Free:style=Regular
/usr/share/fonts/fontawesome/fa-brands-400.ttf: Font Awesome 5 Brands:style=Regular
/usr/share/fonts/fontawesome/Font Awesome 5 Free-Solid-900.otf: Font Awesome 5 Free,Font Awesome 5 Free Solid:style=Solid
/usr/share/fonts/fontawesome/fa-solid-900.ttf: Font Awesome 5 Free:style=Solid
/usr/share/fonts/fontawesome/Font Awesome 5 Brands-Regular-400.otf: Font Awesome 5 Brands,Font Awesome 5 Brands Regular:style=Regular
/usr/share/fonts/fontawesome/Font Awesome 5 Free-Regular-400.otf: Font Awesome 5 Free,Font Awesome 5 Free Regular:style=Regular


I have version 5.1.0. So, if your fc-list reports that awesome font has name 'FontAwesome' then you should use that name

Code:

fc-match FontAwesome


HTH
Back to top
View user's profile Send private message
josephg
l33t
l33t


Joined: 10 Jan 2016
Posts: 783
Location: usually offline

PostPosted: Wed Sep 12, 2018 8:45 am    Post subject: Reply with quote

since then i've found that just the fontname itself is sufficient.
Code:
$ fc-match fontawesome
FontAwesome.otf: "FontAwesome" "Regular"
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum