Font Configuration
This guide covers installing custom fonts and setting them as system defaults.
Step 1: Install a Font
Section titled “Step 1: Install a Font”Many fonts are in the official repos, others require AUR:
# From official repossudo pacman -S ttf-jetbrains-mono noto-fonts
# From AUR (example: Atkinson Hyperlegible)paru -S otf-atkinson-hyperlegible-nextStep 2: Find the Font Family Name
Section titled “Step 2: Find the Font Family Name”After installing, find the exact family name:
fc-list | grep -i "atkinson"For more details:
fc-list : family | sort | uniq | grep -i "atkinson"Step 3: Create System-Wide Configuration
Section titled “Step 3: Create System-Wide Configuration”Create or edit /etc/fonts/local.conf:
sudo nvim /etc/fonts/local.confAdd the following (adjust font names as needed):
<?xml version="1.0"?><!DOCTYPE fontconfig SYSTEM "fonts.dtd"><fontconfig> <!-- Default sans-serif font --> <alias> <family>sans-serif</family> <prefer> <family>Atkinson Hyperlegible</family> <family>Noto Sans</family> </prefer> </alias>
<!-- Default serif font --> <alias> <family>serif</family> <prefer> <family>Noto Serif</family> </prefer> </alias>
<!-- Default monospace font --> <alias> <family>monospace</family> <prefer> <family>JetBrains Mono</family> <family>Noto Sans Mono</family> </prefer> </alias></fontconfig>Step 4: Refresh Font Cache
Section titled “Step 4: Refresh Font Cache”Rebuild the font cache:
sudo fc-cache -fvRestart applications or your desktop session for changes to apply.
Quick Setup with Pre-Configured File
Section titled “Quick Setup with Pre-Configured File”If you have a pre-configured local.conf:
sudo cp ~/your-backup/local.conf /etc/fonts/sudo fc-cache -fvVerify Font Configuration
Section titled “Verify Font Configuration”Check what font is being used for a family:
fc-match sans-seriffc-match seriffc-match monospacePopular Font Packages
Section titled “Popular Font Packages”| Package | Description |
|---|---|
ttf-jetbrains-mono | Excellent monospace font for coding |
noto-fonts | Google’s font family with wide language support |
ttf-fira-code | Monospace with programming ligatures |
ttf-cascadia-code | Microsoft’s monospace font |
inter-font | Clean sans-serif UI font |