Find the font used to render a character, or containing the glyph?

See there for an answer (if your GNOME version has not deprecated the feature)

https://fedoraproject.org/wiki/Identifying_fonts


You can use fontconfig:

fc-list ':charset=<hex_code1> <hex_code2>'

For details see https://unix.stackexchange.com/a/393740/14907

For bash script see gist.github.com/akostadinov/202550a1e2fd4ea8cf523d91b437fa09

#!/usr/bin/env bash
# example: ./font_find.sh 🎩︎
# credits: David Baynard, https://unix.stackexchange.com/a/393740/14907

param="$1"
char=${param:0:1}
printf '%x' \'"$char" | xargs -I{} fc-list ":charset={}"

Alternative Python solution here: https://superuser.com/a/1452828/111432


From the Fedora wiki.

Looking up this glyph in the gucharmap application, using the same font family, is usually sufficient to learn where it's taken from. Gucharmap will display the origin font when you right-click on a glyph.

enter image description here

sudo apt install gucharmap

Tags:

Linux

Fonts