summaryrefslogtreecommitdiffstats
path: root/fontconfig/conf.d/68-unifont.conf
diff options
context:
space:
mode:
Diffstat (limited to 'fontconfig/conf.d/68-unifont.conf')
-rw-r--r--fontconfig/conf.d/68-unifont.conf104
1 files changed, 104 insertions, 0 deletions
diff --git a/fontconfig/conf.d/68-unifont.conf b/fontconfig/conf.d/68-unifont.conf
new file mode 100644
index 0000000..1d8c463
--- /dev/null
+++ b/fontconfig/conf.d/68-unifont.conf
@@ -0,0 +1,104 @@
+<?xml version="1.0"?>
+<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
+<fontconfig>
+ <!--
+ Antialiased TTF Unifont is a bit blurry at the "native" pixel size,
+ which may strain eyes. Disable antialiasing in this case.
+ -->
+
+ <match target="font">
+ <test name="file" compare="contains">
+ <string>unifont</string>
+ </test>
+ <test name="file" compare="contains">
+ <string>.ttf</string>
+ </test>
+ <test name="pixelsize" compare="eq" qual="any">
+ <double>16</double>
+ </test>
+ <test target="pattern" name="slant" compare="eq">
+ <const>roman</const>
+ </test>
+ <edit name="antialias" mode="assign">
+ <bool>false</bool>
+ </edit>
+ </match>
+
+ <!--
+ Hinting uglifies the TTF Unifont a lot. Disable it.
+ (For some reason it never happened before 7.0.04.)
+ Unfortunately, libcairo will not respect this setting without being patched.
+ See <https://bugs.freedesktop.org/show_bug.cgi?id=11838>.
+ -->
+ <match target="font">
+ <test name="file" compare="contains">
+ <string>unifont</string>
+ </test>
+ <test name="file" compare="contains">
+ <string>.ttf</string>
+ </test>
+ <edit name="hinting" mode="assign">
+ <bool>false</bool>
+ </edit>
+ <edit name="autohint" mode="assign">
+ <bool>false</bool>
+ </edit>
+ <edit name="hintstyle" mode="assign">
+ <const>hintnone</const>
+ </edit>
+ </match>
+
+<!-- this file makes fontconfig consider "Unifont", "Unifont Upper" and "Unifont CSUR" parts of the same font -->
+
+ <match target="scan">
+ <test name="file" compare="contains">
+ <string>unifont_upper.ttf</string>
+ </test>
+ <edit name="family">
+ <string>Unifont</string>
+ </edit>
+ <edit name="fullname">
+ <string>Unifont</string>
+ </edit>
+ <edit name="fontversion">
+ <int>8</int>
+ </edit>
+ </match>
+
+ <match target="scan">
+ <test name="file" compare="contains">
+ <string>unifont_csur.ttf</string>
+ </test>
+ <edit name="family">
+ <string>Unifont</string>
+ </edit>
+ <edit name="fullname">
+ <string>Unifont</string>
+ </edit>
+ <edit name="fontversion">
+ <int>8</int>
+ </edit>
+ </match>
+
+ <alias binding="same">
+ <family>Unifont Upper</family>
+ <accept>
+ <family>Unifont</family>
+ </accept>
+ </alias>
+
+ <alias binding="same">
+ <family>Unifont CSUR</family>
+ <accept>
+ <family>Unifont</family>
+ </accept>
+ </alias>
+
+ <alias binding="same">
+ <family>Unifont Upper CSUR</family>
+ <accept>
+ <family>Unifont</family>
+ </accept>
+ </alias>
+</fontconfig>
+
Un proyecto texto-plano.xyz