freetype
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft] blurry texts


From: Werner LEMBERG
Subject: Re: [ft] blurry texts
Date: Sun, 27 Aug 2017 20:49:39 +0200 (CEST)

> Is there any Environment Variables to enhance font rendering on
> Linux?

Define `enhance'.  

> Why Windows 7 font rendering is perfect?

Define `perfect'.

In general, there are two different philosophies how fonts should be
rendered on screen.

* Optimize rendering for screens only.  This is what e.g. Windows does
  while using system fonts.  The costs w.r.t. to font shapes is high:
  To make pixels as much black and readable as possible, the shapes
  must be distorted quite severely.  As a result, fonts at small sizes
  inevitably look very similar.

* Optimize rendering to preserve font shapes.  This is what Apple does
  (and GNU/Linux distributions), at the cost of increased blurriness.
  Fonts at small sizes do become distinguishable.

> but font rendering for Linux is not?

You are barking up the wrong tree.  FreeType already provides the
necessary tools, I believe, but most (all?) GNU/Linux GUIs don't do
the right thing.

* It is necessary to convert to and from linear alpha blending while
  handling fonts.  Otherwise gamma values are wrong, causing visual
  artifacts.

* If TrueType bytecode hinting is activated (`full' hinting, i.e., not
  using the auto-hinter), it is necessary to obey the `gasp' table in
  the font.  AFAIK, this doesn't happen in most (all?) GNU/Linux GUIs.

> Any idea?

First of all, get used to the GNU/Linux font rendering philosophy –
you simply have to accept that things are done differently.  Note that
I don't say that the current situation can't be improved!

IIRC very recent Qt versions introduced linear alpha blending, so
chances are high that at least KDE soon provides the same.

I'll probably add automatic `gasp' table support to FreeType in the
near future, which might be beneficial to `strong' hinting in general.


    Werner

reply via email to

[Prev in Thread] Current Thread [Next in Thread]