Skip to content

Instantly share code, notes, and snippets.

@danielsource
Last active October 25, 2025 22:41
Show Gist options
  • Select an option

  • Save danielsource/025d2bf00ee5f1cf2fb9b0b7b484a19e to your computer and use it in GitHub Desktop.

Select an option

Save danielsource/025d2bf00ee5f1cf2fb9b0b7b484a19e to your computer and use it in GitHub Desktop.
~/.config/fontconfig/fonts.conf
<!-- Replace the comments with the fonts and save this file as ~/.config/fontconfig/fonts.conf -->
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "urn:fontconfig:fonts.dtd">
<fontconfig>
<alias>
<family>serif</family>
<prefer><family><!-- SERIF FONT HERE --></family></prefer>
</alias>
<alias>
<family>sans-serif</family>
<prefer><family><!-- SANS SERIF FONT HERE --></family></prefer>
</alias>
<alias>
<family>monospace</family>
<prefer>
<family><!-- MONOSPACED FONT HERE --></family>
<!-- You can specify multiple fonts too -->
<family>Liberation Mono</family>
</prefer>
</alias>
<!-- Example of changing monospaced font default size:
<match>
<test name="family"><string>monospace</string></test>
<edit name="size"><double>10</double></edit>
</match> -->
<dir><!-- CUSTOM FONT FOLDER HERE --></dir>
</fontconfig>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment