Disabling the anti-aliasing for a specific font with user's fonts.conf
Solution 1:
[I know this question is 5 years old, but it still appears in search engines.]
I just made a .fonts.conf
file in the Home directory. It worked right away in Ubuntu 18.04 LTS.
(Replace the font names accordingly!)
<!--
~/.fonts.conf
Remember to run "fc-cache" after you modify this file.
-->
<fontconfig>
<match target="font">
<test name="family" qual="any">
<string>Ubuntu Mono</string>
<string>Free Pixel</string>
</test>
<edit name="antialias" mode="assign">
<bool>false</bool>
</edit>
</match>
</fontconfig>
I put it into a Gist, plus some additional documentation just in case: https://gist.github.com/gonzalocesar/7ef41572a2627b65da976001a29ba7ee