[solved] Installing fonts?  [Solved]

Help for Current Versions of MX
When asking for help, use Quick System Info from MX Tools. It will be properly formatted using the following steps.
1. Click on Quick System Info in MX Tools
2. Right click in your post and paste.
Message
Author
Domarius

[solved] Installing fonts?

#1 Post by Domarius »

Should I follow the "Ubuntu" instructions from this page? Or is there a built-in way?
https://www.techrepublic.com/blog/linux ... -in-linux/

I found in Ubuntu I could just right-click on the .ttf file and click "Install". I was wondering if there was something as straight forward in MX Linux, because I've been led to believe that it's generally a bad idea to modify the system folders in Linux.
Last edited by Domarius on Wed Apr 17, 2019 4:34 am, edited 1 time in total.

skidoo
Posts: 753
Joined: Tue Sep 22, 2015 6:56 pm

Re: Installing fonts?

#2 Post by skidoo »

https://wiki.debian.org/Fonts
If the instructions therein are not exactly applicable, please post back to mention any points of confusion/difficulty... then those points could be covered in a future MX wiki page.

FWIW, the MX User Manual (PDF) does have a section (a few sentences) regarding "Adding Fonts"

Domarius

Re: Installing fonts?

#3 Post by Domarius »

Ah thank you - yes the instructions in the actual MX Manual worked. Basically copying the font file into /usr/share/fonts. It says to "open a root Thunar" so you can copy it, and if I search the manual for "root Thunar", I get the instructions to do that too. After I opened GIMP, the font was available.

I'm sure one day there will be an installer like Ubuntu has, so the average user doesn't have to mess around with admin file access, but the main thing is the MX Manual instructions are reliable. I'll start checking there first now that I'm more aware of it!

User avatar
Head_on_a_Stick
Posts: 919
Joined: Sun Mar 17, 2019 3:37 pm

Re: Installing fonts?

#4 Post by Head_on_a_Stick »

Domarius wrote: Wed Apr 17, 2019 4:34 am copying the font file into /usr/share/fonts
Copy the fonts to ~/.local/share/fonts/ instead to avoid needing elevated permissions. That will only apply per-user though (for obvious reasons).

As an aside, I like to set the fonts in all applications to one the aliases (serif, sans-serif or monospace) and then use ~/.config/fontconfig/fonts.conf to set the font used for any given alias, like this:

Code: Select all

<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
  <alias>
    <family>monospace</family>
    <prefer><family>Inconsolata</family></prefer>
  </alias>
  <alias>
    <family>serif</family>
    <prefer><family>Times New Roman</family></prefer>
  </alias>
  <alias>
    <family>sans-serif</family>
    <prefer><family>Microsoft Sans Serif</family></prefer>
  </alias>
</fontconfig>
With this method the fonts across all applications can be set from the fonts.conf file.
mod note: Signature removed, please read the forum rules

User avatar
Fibogacci
Posts: 165
Joined: Sun Dec 30, 2018 3:19 pm

Re: [solved] Installing fonts?

#5 Post by Fibogacci »

It is good to know, that for many fonts (Should I say hundreds? ;) ) freely available from Google there is application called TypeCatcher.

You will find it in MX Package Installer in Stable Repo.

Just select the font, click Download and you have it on your system.

I really like it and it is easy to discover new fonts.

Image
MX-18 Continuum x86_64: laptop Dell Inspiron N7110, Intel Core i5-2410M @ 2.900GHz, 4GB RAM, Kernel: 4.19, DE: Xfce

Domarius

Re: [solved] Installing fonts?

#6 Post by Domarius »

Bluesguy wrote: Wed Apr 17, 2019 8:35 am Just another quick way to install fonts ... I keep a stash of xtra fonts (especially MS and Apple TTFs) that I install on all my (and others) Linux-based machines. Quite simple to do ... in MX you already have an invisible folder in your Home directory named .fonts ... simply copy over your xtras into that folder and run this in your terminal:
sudo fc-cache -rv
... exit the terminal then logout/in ...your new fonts are now "registered" system-wide. Any time you add or subtract from this folder, simply re-use the command. This way you can carry over your stash from machine/user to machine/user without having them all sitting in the Root directory and then having to filter through what is default-system and your new additions in order to install them to another machine/user.
Ah, I will do that moving forward!
Fibogacci wrote: Wed Apr 17, 2019 5:48 am It is good to know, that for many fonts (Should I say hundreds? ;) ) freely available from Google there is application called TypeCatcher.
Ah that looks convenient. I will try it out, thanks!

User avatar
Head_on_a_Stick
Posts: 919
Joined: Sun Mar 17, 2019 3:37 pm

Re: [solved] Installing fonts?  [Solved]

#7 Post by Head_on_a_Stick »

Bluesguy wrote: Wed Apr 17, 2019 8:35 am @Head_on_a_Stick
There is already a folder in the your MX Home directory as I've indicated above
Not on my system:

Code: Select all

empty@mx:~ $ ls .fonts
ls: cannot access '.fonts': No such file or directory
2|empty@mx:~ $
This is a fresh install; it was copied over onto the metal from a QEMU image rather than installed directly but I don't think that should make a difference.
mod note: Signature removed, please read the forum rules

User avatar
Head_on_a_Stick
Posts: 919
Joined: Sun Mar 17, 2019 3:37 pm

Re: [solved] Installing fonts?

#8 Post by Head_on_a_Stick »

Well it may be present in the "live" system but it isn't in my installed system.

I've just unpacked the ISO image to check and there doesn't seem to be /etc/skel/.fonts there either.

And anyway ~/.fonts is obsolete now, ~/.local/share/fonts is the preferred location.

Also note that the fc-cache command should be run as the normal user rather than root (and doesn't need to be run anyway if ~/.local/share/fonts is used).
Bluesguy wrote: Sat Apr 20, 2019 11:01 amunless, of course, you're still using MX-14
No, MX 18.2 is the first version I've tried.
mod note: Signature removed, please read the forum rules

User avatar
Stevo
Developer
Posts: 14419
Joined: Fri Dec 15, 2006 7:07 pm

Re: [solved] Installing fonts?

#9 Post by Stevo »

This program looks interesting: https://github.com/FontManager/font-manager

Though we already have a slightly older version in the Stretch repo already. I'll check to see if it's compiled with Thunar and Nemo integration, though.

But you can just install font-manager, and it should open up when you click a font file, plus it has a "Install Font" button.

User avatar
dreamer
Posts: 878
Joined: Sun Oct 15, 2017 11:34 am

Re: [solved] Installing fonts?

#10 Post by dreamer »

Stevo wrote: Sat Apr 20, 2019 3:56 pm This program looks interesting: https://github.com/FontManager/font-manager

Though we already have a slightly older version in the Stretch repo already. I'll check to see if it's compiled with Thunar and Nemo integration, though.

But you can just install font-manager, and it should open up when you click a font file, plus it has a "Install Font" button.
Font Manager doesn't display properly on my system. The left part of the application is cut off. Also the design is very, very Gnome 3. I used the MATE font installer (maybe part of Caja File Manager) and also manually copied fonts to usr/share/fonts.
Note to self and others: SysVinit is a good option. However if you run into problems try with systemd first. This applies to AppImages, Flatpaks, GitHub packages and even some Debian packages.

Post Reply

Return to “MX Help”