LogoopenSUSE Build Service > Projects
Sign Up | Log In

Ubuntu Style Font Rendering

This repo provides Ubuntu style font rendering for OpenSUSE by implementing Ubuntu's versions of fontconfig and freetype2 for enhanced font presentation with subpixel rendering.  This repo is currently based on Ubuntu's 17.04 Zesty Zapus release and is updated periodically with Ubuntu's latest versions.

Install as follows:

1) Add one of the following repository links using YaST or zypper according to your OS version:

http://download.opensuse.org/repositories/home:/gldickens3/openSUSE_42.1/
http://download.opensuse.org/repositories/home:/gldickens3/openSUSE_Leap_42.2/

Note: The above repositories are based on freetype-2.6.3 which is the current freetype2 version used by Ubuntu.  Repos based on freetype-2.7.1 are available here:

http://download.opensuse.org/repositories/home:/gldickens3:/Advanced/openSUSE_Leap_42.1/
http://download.opensuse.org/repositories/home:/gldickens3:/Advanced/openSUSE_Leap_42.2/
http://download.opensuse.org/repositories/home:/gldickens3:/Advanced/openSUSE_Tumbleweed/

Note: Tumbleweed requires freetype-2.7.1 from the "Advanced" repository. freetype-2.6.3 will not work with Tumbleweed due to a conflict with the version of the harfbuzz package on Tumbleweed.

2) Switch packages to this repo with either YaST or the command line as follows:

Using YaST:

     Software Management > Repositories > This Repo > Switch system packages > Accept

Using the command line: 

     sudo zypper dup --from <This Repo>

The packages from this repo that should be used are: fontconfig, fontconfig-32bit, libfreetype6 and libfreetype6-32bit.

3) Logout/in.

4) Verify that the following content is included in ~/.config/fontconfig/fonts.conf and/or
/etc/fonts/local.conf:

<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
 <match target="font">
  <edit mode="assign" name="rgba">
   <const>rgb</const>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="hinting">
   <bool>true</bool>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="hintstyle">
   <const>hintmedium</const>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="antialias">
   <bool>true</bool>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="lcdfilter">
   <const>lcddefault</const>
  </edit>
 </match>
</fontconfig>

Edit the hintstyle in ~/.config/fontconfig/fonts.conf and/or /etc/fonts/local.conf and try each available setting: "hintslight", "hintmedium", "hintfull".  "hintmedium" is the default value and which usually produces the best results.

You should logout/login after changing the font configuration.

Alternatively, you can use your desktop environment's GUI to set the font configuration.  For example, with KDE, go to Font Settings and enable anti-aliasing > Configure > RGB > Slight/Medium/Full.

5) For best results, you should also install a robust font package such as a set of MS truetype fonts. You can install additional fonts from an existing Windows installation in /usr/share/fonts/ or use the OpenSUSE package, fetchmsttfonts, which provides a selection of freely available MS truetype fonts including Ariel, Verdana and Times New Roman.

Comments for home:gldickens3 (2)

Alexandre Silva abatistas1709 wrote about 2 months ago

Works fine! Congrats!

Bengt Frost bfrost wrote about 1 month ago

Just installed updated packages in Leap 42.2, works great!