Improved font rendering in Guix
Collected in Guix
There is a neat trick to make fonts on Linux look thicker and smoother and sharper. Set the following variable in /etc/environment:
FREETYPE_PROPERTIES="cff:no-stem-darkening=0 cff:darkening-parameters=500,400,1000,350,1500,325,2000,300 autofitter:no-stem-darkening=0 autofitter:darkening-parameters=500,400,1000,350,1500,325,2000,300"
FREETYPE_PROPERTIES is set in /etc/environment so that it sticks as a global configuration. You can see the effect in the following screenshots stitched together from before and after applying the configuration:
I was able to set FREETYPE_PROPERTIES in Guix with the help of a great tip from Lo Peter on how to set a global environment variable in a Guix system.
Here is the final configuration, to be put in the Guix system's configuration file (I call it os.scm).
(operating-system
(services
(cons*
(simple-service
'global-environment-variables
session-environment-service-type
'(("FREETYPE_PROPERTIES" . "cff:no-stem-darkening=0 cff:darkening-parameters=500,400,1000,350,1500,325,2000,300 autofitter:no-stem-darkening=0 autofitter:darkening-parameters=500,400,1000,350,1500,325,2000,300"))))))
Written by Jayesh Bhoot