1

I am new to linux, my question is simply : how I can force Ubuntu to use font A instead of font B in all applications and web pages? For example there is a web page that uses Tahoma Font, but I want my browser use Ubuntu font instead of Tahoma automatically.

  • 1
    What browser are you using? – Evandro Silva Oct 31 '12 at 20:45
  • it is an example, i mean all all applications, it can be chromium or libreoffice word or inkscape... – Nasser Mansouri Nov 1 '12 at 6:54
6

I use this content in ~/.fonts.conf to replace several fonts with Ubuntu

<!--?xml version="1.0"?>-->
<!--DOCTYPE fontconfig SYSTEM "fonts.dtd">-->
<!-- ~/.fonts.conf for per-user font configuration -->
<fontconfig>
<alias>
    <family>sans-serif</family>
    <prefer>
        <family>Ubuntu</family>
    </prefer>
</alias>
<alias>
    <family>monospace</family>
    <prefer>
        <family>Ubuntu Mono</family>
    </prefer>
</alias>
<match>
    <test name="family"><string>Arial</string></test>
    <edit name="family" mode="prepend" binding="strong">
        <string>Ubuntu</string>
        <string>Arial</string>
    </edit>
</match>
<match>
    <test name="family"><string>helvetica</string></test>
    <edit name="family" mode="prepend" binding="strong">
        <string>Ubuntu</string>
        <string>Helvetica</string>
    </edit>
</match>

</fontconfig>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.