Linux安装心仪字体
Scribus 的下载页上,有个标题字体非常好看,毕竟人家是专业书籍排版软件,常年和各种字体打交道,所选非常。
1.确认目标字体,如下图所示,翻看网页源码找到字体名字,搜索下载安装
2.下载字体
Libre Baskerville,打开网页,点击右上角的下载按钮
3.安装字体
➜ fonts pwd
/usr/share/fonts
➜ fonts sudo mkdir googlefonts
➜ fonts cd googlefonts
➜ googlefonts sudo unzip -d . ~/Downloads/Libre_Baskerville.zip
Archive: /home/mephisto/Downloads/Libre_Baskerville.zip
replace ./OFL.txt? [y]es, [n]o, [A]ll, [N]one, [r]ename: A
inflating: ./OFL.txt
inflating: ./LibreBaskerville-Regular.ttf
inflating: ./LibreBaskerville-Italic.ttf
inflating: ./LibreBaskerville-Bold.ttf
➜ googlefonts ls
Karla-Italic-VariableFont_wght.ttf LibreBaskerville-Bold.ttf LibreBaskerville-Regular.ttf README.txt
Karla-VariableFont_wght.ttf LibreBaskerville-Italic.ttf OFL.txt
我安装了2个字体,另外一个是karla,也是上面排版软件的页面字体
3.创建字体信息缓存文件(build font information cache files)
fc-cache 会扫描系统的字体目录,创建字体信息缓存文件给相关软件使用
➜ googlefonts sudo fc-cache -fv
/usr/share/fonts: caching, new cache contents: 0 fonts, 8 dirs
/usr/share/fonts/X11: caching, new cache contents: 0 fonts, 4 dirs
/usr/share/fonts/X11/Type1: caching, new cache contents: 8 fonts, 0 dirs
/usr/share/fonts/X11/encodings: caching, new cache contents: 0 fonts, 1 dirs
/usr/share/fonts/X11/encodings/large: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/X11/misc: caching, new cache contents: 89 fonts, 0 dirs
/usr/share/fonts/X11/util: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/cMap: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/cmap: caching, new cache contents: 0 fonts, 5 dirs
/usr/share/fonts/cmap/adobe-cns1: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/cmap/adobe-gb1: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/cmap/adobe-japan1: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/cmap/adobe-japan2: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/cmap/adobe-korea1: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/googlefonts: caching, new cache contents: 17 fonts, 1 dirs
/usr/share/fonts/googlefonts/static: caching, new cache contents: 14 fonts, 0 dirs
/usr/share/fonts/opentype: caching, new cache contents: 0 fonts, 5 dirs
/usr/share/fonts/opentype/font-awesome: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/opentype/malayalam: caching, new cache contents: 7 fonts, 0 dirs
/usr/share/fonts/opentype/mathjax: caching, new cache contents: 24 fonts, 0 dirs
/usr/share/fonts/opentype/noto: caching, new cache contents: 30 fonts, 0 dirs
/usr/share/fonts/opentype/urw-base35: caching, new cache contents: 35 fonts, 0 dirs
/usr/share/fonts/truetype: caching, new cache contents: 0 fonts, 52 dirs
/usr/share/fonts/truetype/Gargi: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/Gubbi: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/Nakula: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/Navilu: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/Sahadeva: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/Sarai: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/abyssinica: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/ancient-scripts: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/arphic: caching, new cache contents: 0 fonts, 0 dirs
/usr/share/fonts/truetype/dejavu: caching, new cache contents: 6 fonts, 0 dirs
/usr/share/fonts/truetype/droid: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/font-awesome: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/fonts-beng-extra: caching, new cache contents: 6 fonts, 0 dirs
/usr/share/fonts/truetype/fonts-deva-extra: caching, new cache contents: 3 fonts, 0 dirs
/usr/share/fonts/truetype/fonts-gujr-extra: caching, new cache contents: 5 fonts, 0 dirs
/usr/share/fonts/truetype/fonts-guru-extra: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/fonts-kalapi: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/fonts-orya-extra: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/fonts-telu-extra: caching, new cache contents: 2 fonts, 0 dirs
/usr/share/fonts/truetype/fonts-yrsa-rasa: caching, new cache contents: 15 fonts, 0 dirs
/usr/share/fonts/truetype/freefont: caching, new cache contents: 12 fonts, 0 dirs
/usr/share/fonts/truetype/kacst: caching, new cache contents: 15 fonts, 0 dirs
/usr/share/fonts/truetype/kacst-one: caching, new cache contents: 2 fonts, 0 dirs
/usr/share/fonts/truetype/lao: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lato: caching, new cache contents: 18 fonts, 0 dirs
/usr/share/fonts/truetype/liberation: caching, new cache contents: 16 fonts, 0 dirs
/usr/share/fonts/truetype/liberation2: caching, new cache contents: 12 fonts, 0 dirs
/usr/share/fonts/truetype/libreoffice: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-assamese: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-bengali: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-devanagari: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-gujarati: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-kannada: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-malayalam: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-oriya: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-punjabi: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-tamil: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-tamil-classical: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/lohit-telugu: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/malayalam: caching, new cache contents: 10 fonts, 0 dirs
/usr/share/fonts/truetype/noto: caching, new cache contents: 4 fonts, 0 dirs
/usr/share/fonts/truetype/padauk: caching, new cache contents: 4 fonts, 0 dirs
/usr/share/fonts/truetype/pagul: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/quicksand: caching, new cache contents: 4 fonts, 0 dirs
/usr/share/fonts/truetype/samyak: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/samyak-fonts: caching, new cache contents: 3 fonts, 0 dirs
/usr/share/fonts/truetype/sinhala: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/teluguvijayam: caching, new cache contents: 20 fonts, 0 dirs
/usr/share/fonts/truetype/tibetan-machine: caching, new cache contents: 1 fonts, 0 dirs
/usr/share/fonts/truetype/tlwg: caching, new cache contents: 58 fonts, 0 dirs
/usr/share/fonts/truetype/ttf-khmeros-core: caching, new cache contents: 2 fonts, 0 dirs
/usr/share/fonts/truetype/ubuntu: caching, new cache contents: 14 fonts, 0 dirs
/usr/share/fonts/type1: caching, new cache contents: 0 fonts, 2 dirs
/usr/share/fonts/type1/gsfonts: caching, new cache contents: 35 fonts, 0 dirs
/usr/share/fonts/type1/urw-base35: caching, new cache contents: 35 fonts, 0 dirs
/usr/share/fonts/wenquanyi: caching, new cache contents: 0 fonts, 1 dirs
/usr/share/fonts/wenquanyi/wqy-zenhei: caching, new cache contents: 2 fonts, 0 dirs
/usr/local/share/fonts: caching, new cache contents: 0 fonts, 0 dirs
/root/.local/share/fonts: skipping, no such directory
/root/.fonts: skipping, no such directory
/usr/share/fonts/X11: skipping, looped directory detected
/usr/share/fonts/cMap: skipping, looped directory detected
/usr/share/fonts/cmap: skipping, looped directory detected
/usr/share/fonts/googlefonts: skipping, looped directory detected
/usr/share/fonts/opentype: skipping, looped directory detected
/usr/share/fonts/truetype: skipping, looped directory detected
/usr/share/fonts/type1: skipping, looped directory detected
/usr/share/fonts/wenquanyi: skipping, looped directory detected
/usr/share/fonts/X11/Type1: skipping, looped directory detected
/usr/share/fonts/X11/encodings: skipping, looped directory detected
/usr/share/fonts/X11/misc: skipping, looped directory detected
/usr/share/fonts/X11/util: skipping, looped directory detected
/usr/share/fonts/cmap/adobe-cns1: skipping, looped directory detected
/usr/share/fonts/cmap/adobe-gb1: skipping, looped directory detected
/usr/share/fonts/cmap/adobe-japan1: skipping, looped directory detected
/usr/share/fonts/cmap/adobe-japan2: skipping, looped directory detected
/usr/share/fonts/cmap/adobe-korea1: skipping, looped directory detected
/usr/share/fonts/googlefonts/static: skipping, looped directory detected
/usr/share/fonts/opentype/font-awesome: skipping, looped directory detected
/usr/share/fonts/opentype/malayalam: skipping, looped directory detected
/usr/share/fonts/opentype/mathjax: skipping, looped directory detected
/usr/share/fonts/opentype/noto: skipping, looped directory detected
/usr/share/fonts/opentype/urw-base35: skipping, looped directory detected
/usr/share/fonts/truetype/Gargi: skipping, looped directory detected
/usr/share/fonts/truetype/Gubbi: skipping, looped directory detected
/usr/share/fonts/truetype/Nakula: skipping, looped directory detected
/usr/share/fonts/truetype/Navilu: skipping, looped directory detected
/usr/share/fonts/truetype/Sahadeva: skipping, looped directory detected
/usr/share/fonts/truetype/Sarai: skipping, looped directory detected
/usr/share/fonts/truetype/abyssinica: skipping, looped directory detected
/usr/share/fonts/truetype/ancient-scripts: skipping, looped directory detected
/usr/share/fonts/truetype/arphic: skipping, looped directory detected
/usr/share/fonts/truetype/dejavu: skipping, looped directory detected
/usr/share/fonts/truetype/droid: skipping, looped directory detected
/usr/share/fonts/truetype/font-awesome: skipping, looped directory detected
/usr/share/fonts/truetype/fonts-beng-extra: skipping, looped directory detected
/usr/share/fonts/truetype/fonts-deva-extra: skipping, looped directory detected
/usr/share/fonts/truetype/fonts-gujr-extra: skipping, looped directory detected
/usr/share/fonts/truetype/fonts-guru-extra: skipping, looped directory detected
/usr/share/fonts/truetype/fonts-kalapi: skipping, looped directory detected
/usr/share/fonts/truetype/fonts-orya-extra: skipping, looped directory detected
/usr/share/fonts/truetype/fonts-telu-extra: skipping, looped directory detected
/usr/share/fonts/truetype/fonts-yrsa-rasa: skipping, looped directory detected
/usr/share/fonts/truetype/freefont: skipping, looped directory detected
/usr/share/fonts/truetype/kacst: skipping, looped directory detected
/usr/share/fonts/truetype/kacst-one: skipping, looped directory detected
/usr/share/fonts/truetype/lao: skipping, looped directory detected
/usr/share/fonts/truetype/lato: skipping, looped directory detected
/usr/share/fonts/truetype/liberation: skipping, looped directory detected
/usr/share/fonts/truetype/liberation2: skipping, looped directory detected
/usr/share/fonts/truetype/libreoffice: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-assamese: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-bengali: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-devanagari: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-gujarati: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-kannada: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-malayalam: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-oriya: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-punjabi: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-tamil: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-tamil-classical: skipping, looped directory detected
/usr/share/fonts/truetype/lohit-telugu: skipping, looped directory detected
/usr/share/fonts/truetype/malayalam: skipping, looped directory detected
/usr/share/fonts/truetype/noto: skipping, looped directory detected
/usr/share/fonts/truetype/padauk: skipping, looped directory detected
/usr/share/fonts/truetype/pagul: skipping, looped directory detected
/usr/share/fonts/truetype/quicksand: skipping, looped directory detected
/usr/share/fonts/truetype/samyak: skipping, looped directory detected
/usr/share/fonts/truetype/samyak-fonts: skipping, looped directory detected
/usr/share/fonts/truetype/sinhala: skipping, looped directory detected
/usr/share/fonts/truetype/teluguvijayam: skipping, looped directory detected
/usr/share/fonts/truetype/tibetan-machine: skipping, looped directory detected
/usr/share/fonts/truetype/tlwg: skipping, looped directory detected
/usr/share/fonts/truetype/ttf-khmeros-core: skipping, looped directory detected
/usr/share/fonts/truetype/ubuntu: skipping, looped directory detected
/usr/share/fonts/type1/gsfonts: skipping, looped directory detected
/usr/share/fonts/type1/urw-base35: skipping, looped directory detected
/usr/share/fonts/wenquanyi/wqy-zenhei: skipping, looped directory detected
/usr/share/fonts/X11/encodings/large: skipping, looped directory detected
/var/cache/fontconfig: cleaning cache directory
/root/.cache/fontconfig: not cleaning non-existent cache directory
/root/.fontconfig: not cleaning non-existent cache directory
fc-cache: succeeded
5.确认是否安装成功
➜ googlefonts fc-match Libre\ Baskerville
LibreBaskerville-Regular.ttf: "Libre Baskerville" "Regular"
6.使用Terminator试试看效果,如下图所示
标识1处设置titlebar为目标字体、2为实际效果, 3和2对比字体一致
最后修改于: Monday, August 28, 2023
版权申明:
- 未标注来源的内容全部为原创,未经授权请勿转载(因转载后排版往往错乱、内容不可控、无法持续更新等);
- 非营利为目的,演绎本博客任何内容,请以'原文出处'或者'参考链接'等方式给出本站相关网页地址(方便读者)。