新しくフォントを入れる

システムにフォントを入れるには

 
Ubuntu機の場合で、入手したフォントファイルを、例えばFont.ttcとすると次のコマンドで、所定の場所にファイルをコピーします

$ cd /usr/share/fonts
$ sudo mkdir MyFonts
$ sudo cp ~/Desktop/Font.ttc /usr/share/fonts/MyFonts
$ sudo fc-cache -fv

上記を実行すると、メッセージが出て、一旦、表示が止まりますが、完了は未だです・・・

/usr/share/fonts: caching, new cache contents: 0 fonts, 6 dirs
/usr/share/fonts/MyFonts: caching, new cache contents: 9 fonts, 0 dirs
/usr/share/fonts/X11: caching, new cache contents: 0 fonts, 5 dirs
/usr/share/fonts/X11/100dpi: caching, new cache contents: 358 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/opentype: caching, new cache contents: 0 fonts, 3 dirs
/usr/share/fonts/opentype/noto:
ここで一旦表示が止まりますが、このあと続きがありますので、終わるのを待ちます

次のメッセージは途中からですが、最後に succeeded の文字が出れば終了です

Re-scanning /usr/share/fonts/truetype: caching, new cache contents: 2 fonts, 27 dirs
Re-scanning /usr/share/fonts/type1: caching, new cache contents: 0 fonts, 1 dirs
/var/cache/fontconfig: cleaning cache directory
/home/hirobe/.cache/fontconfig: cleaning cache directory
/home/hirobe/.fontconfig: not cleaning non-existent cache directory
fc-cache: succeeded               この文字が出れば正常に終了しています
user@hocalhost:/usr/share/fonts$ 

WriterなどのLibeOfficeで新しくフォントが追加されたのを確認できます。

タイトルとURLをコピーしました