Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to manage fonts on Linux

2025-01-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

Editor to share with you how to manage fonts on Linux, I believe most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!

Add a new font

For quite a long time, I have been a font collector, and some people will even say that I am a little obsessed. From the early days when I used Linux, I always added fonts to my desktop in the same way. There are two ways to do this:

Make fonts available by user

Make fonts available system-wide.

Because there is no other user on my desktop (except myself), I only use the font settings available to the user. However, I will show you how to complete these two settings. First, let's take a look at how to add a new font to the user. The first thing you need to do is to find the font file. Both True Type fonts (TTF) and Open Type fonts (OTF) can be added. I chose to add fonts manually, that is, I created a new hidden directory called ~ /. Fonts under the ~ / directory. This can be done by the following command:

Mkdir / .fonts

When this folder is newly created, I move all TTF and OTF font files to this folder. In other words, all the fonts you add in this folder can be used in installed applications. Keep in mind, however, that these fonts are only available to this one user.

If you want to make this font collection available to all users, you can do the following:

Hongmeng official Strategic Cooperation to build HarmonyOS Technology Community

Open a terminal window

Change the path to the directory that contains all your fonts

Use the sudo cp * .ttf * .TTF / usr/share/fonts/truetype/ and sudo cp * .otf * .OTF / usr/share/fonts/opentype commands to copy all fonts.

The next time users log in, they will be able to use all these beautiful fonts.

Font management of graphical interface

There are many ways to manage your fonts on Linux, depending on your desktop environment. Let's take KDE as an example. Using Kubuntu 18.04 with KDE as the desktop environment, you can find a pre-installed font management tool. By opening this tool, you can easily add, remove, enable or disable fonts (including, of course, details of all installed fonts). This tool also allows you to easily add and remove fonts for each user or system-wide. If you want to add a specific font for the user, you need to download the font and open the Font Management tool. In this tool (figure 1), click "personal Font" and click the "+" sign add button.

Figure 1: add personal fonts to KDE.

Navigate to your font path, select them, and click Open. Your font will be added to the personal area and immediately available (figure 2).

Figure 2: adding fonts using KDE font management

To do the same in GNOME, you need to install an application. Open the GNOME Software Center or Ubuntu Software Center (depending on the distribution you are using) and search for the font manager. Select Font Manager and click the install button. Once the installation is complete, you can launch it from the desktop menu and let us install the personal font. Here is how to install:

Hongmeng official Strategic Cooperation to build HarmonyOS Technology Community

Select users from the left pane (figure 3)

Click the "+" button at the top of the window

Browse and select the downloaded font

Click "Open".

Figure 3: adding fonts in GNOME

Adjust the font

First, you need to understand three concepts:

Font Tip: use mathematical instructions to adjust the font outline display to align it with the rasterized grid.

Anti-aliasing: a technique that improves the authenticity of digital images by smoothing curves and diagonal jagged edges.

Zoom factor: a zoom unit that allows you to multiply the font size. That is, if your font is 12pt and the zoom factor is 1, then the font size will be 12pt. If your zoom factor is 2, then the font will be 24pt.

Suppose you have installed your fonts, but they don't look as good as you think. How will you adjust the appearance of the font? In both KDE and GNOME, you can make some adjustments. One of the things to consider when adjusting fonts is that the taste of fonts is very subjective. You may find that you have to keep adjusting until you get a font that looks really satisfying (depending on your needs and special tastes). Let's take a look at the situation under KDE first.

Open the system Settings tool and click Font. In this section, not only can you switch between different fonts, you can also enable or configure anti-aliasing or enable font scaling factors (figure 4).

Figure 4: configuring fonts in KDE

To configure anti-aliasing, select enable from the drop-down menu and click configure. In the results window, you can configure "exclusion range", "Sub-Pixel render Type" and "prompt Type".

Once you have made changes, click "apply". Restart all running programs and the new settings will take effect.

To do this in GNOME, you need to install the Font Manager or GNOME Tweaks. GNOME Tweaks is a better tool here. If you open the GNOME Dash menu and cannot find Tweaks, open GNOME "Software" (or Ubuntu "Software") and install GNOME Tweaks. After installation, open and click "Font", where you can configure prompts, anti-aliasing and zoom factors (figure 5).

Figure 5: adjusting fonts in GNOME

The above is all the contents of the article "how to manage fonts on Linux". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report