Xft Hack Improves Antialiased Font Rendering
Eugenia writes: "Font antialiasing first made its way to XFree through Qt/KDE only a year ago and GTK+/Gnome followed some time after. Even with the latest version of Freetype 2.08, which reportedly brings better quality, the result is still not up to par with the rendering quality found on some commercial OSes. David Chester has hacked through the Xft library and he achieved an incredibly good quality on antialias rendering under XFree86. With this hack, at last, XFree can deliver similar aesthetic results to Mac OS X's or Windows' rendering engines. Check the two brand-new screenshots ('before' and 'after') at his web page and notice the difference with your own eyes."
I get the feeling that there is still work to be done, though. If you have windows xp, it's worth turning on the ClearType setting in Display -> Appearance -> Effects. XP starts as anti-aliased, but ClearType brings an even greater level. Of course, if you haven't seen ClearType in action, it's hard to expect improvement from plain old win2k. But the font improvements shown above in XFree are amazing, like night and day, no more blocky p's and q's at the wrong font size, which will make a lot of happy people at non MSFT boxes. =)
Having worked with GOOD font rendering software (mainly for broadcast television) I can say that most gui renderers do a pretty horrible job.
It's not that they get the font shape wrong, or don't antialias correctly, it's that they don't allow for how people see things, and just antialias 'mathmatically correct'.
With the fonts we use for television character generaters, several seperate rendering passes are used to give:
1 - a solid and anti-aliased 'interior' to the font (this is 'normal' antialiasing)
2 - a perimeter or border to the font, in a slightly different colour/darkless level, to make the edge stand out
3 - a seperate rednering to the alpha channel to stop the font from 'blending' excessivly at the edges with the background (ie: a buffer zone).
This makes a MASSIVE difference to the quality of the fonts, especially on anything other than a solid colour background.
unfortunately, no OS as yet does this for it's screen display fonts, which is a pity, as it makes a BIG difference.
Having said that, I'm VERY happy that improvements are happening, as good font rendering makes a hugh difference to the effort required to read text.
Comment removed based on user account deletion
Here's another mirror. Sorry about those stupid ads.
I also want emphasize one thing that I say on the website. I can't take a whole lot of credit for the improvement. For sure, the freetype project and Keith Packard, author of XRender and Xft did all of the hard work. I just tweaked a few settings (adjusted glyph proportions and turned off hinting).
David Chester
Most people believe it.
It's possible to get fonts to look correct... My fonts look fine. The real trick I think, is to get fonts working right by default.
XFree86 4 supports sub-pixel anti-aliasing (aka ClearType). You just need to put match edit rgba=rgb; in XftConfig.
Be patient. Keith Packard is pretty well done with his design and implementation of a new font selection configuration mechanism currently known as "fontconfig". Fontconfig separates the font selection from the rest of Xft, allowing other applications such as printer drivers to select fonts using the same mechanism and policy as X applications.
In the process, fontconfig replaces the arcane Xft configuration language with an XML DTD. This should allow easier hand-editing of this configuration. More importantly, it should allow GUI toolkits such as KDE and Gnome to easily put a GUI interface on font selection configuration. Hopefully, in a few months you'll be able to just click a button to get sub-pixel font rendering with Xft.
This might explain why client-side rendering was chosen. There are pros and cons but the pros seem to outweight the cons by far.
...even Athena widgets...
The biggest advantage of this scheme by far is that you don't have to have any magic support for antialiased fonts in your toolkits
This doesn't seem to be a problem since most populair toolkits already support the Render extension. Remember, RENDER is a completely new rendering system for X, not just anti-aliasing.
If there was great demand for this it would already have happenend don't you think? Changing the Xaw toolkit to support RENDER would not be too hard I think.
-adnans
"In short: just say NO TO DRUGS, and maybe you won't end up like the Hurd people." --Linus Torvalds
Ah, how intuitive... how many hours of reading manpages, HOWTOs and FAQs did it take to figure that one out?
It could have taken you one Google search for "xfree86 subpixel rendering" to find this link!
-adnans
"In short: just say NO TO DRUGS, and maybe you won't end up like the Hurd people." --Linus Torvalds
It is available for X. See my other post on this page.
--Ben
On the contrary...
If there is a browser that you got a chance to see an IE only web site is Konqueror on KDE 3.0 - it got the most compatible with MSIE javascript and rendering techniques...
Hetz (Heunique)
Actually the result of hinting depends on two things. First, the font needs to be hinted well. Unfortunately only very few fonts are well-hinted. For those that aren't it makes indeed sense to turn hinting off entirely. Second, your font renderer needs to support the hinting information embedded into the font.
TrueType fonts have bytecode with hinting information that can be interpreted by the renderer. This is what freetype-2.0 did up to version 2.0.1. Due to patent issues this feature was turned off by default in version 2.0.2. All newer versions of freetype use something what they call autohinter. While this gives better results for badly hinted or unhinted fonts, it does not (yet) achieve the excellent results you get from using the hints embedded in well-hinted fonts.
The solution is thus not to disable hinting but to enable the bytecode interpreter in your freetype2 libs. Of course you also need some decent fonts.
It's true, disabling hinting is just plain stupid. The real problem is that TrueType font hinting is patented (by Apple!) and so though the freetype library (used by Xft for font rendering) has the code to do it properly, it's disabled by default in favor of an "automatic hinting engine" that probably makes things worse. So I'm not surprised that disabling hinting in a default build of freetype makes things look better. But it's a really dumb way to proceed.
The right solution is to recompile freetype with the patented hinting turned ON, and the automatic hinting engine turned OFF. It really looks good, way better than either of that guy's screenshots.
V = B < .04045 ? v/12.92 : pow((v+.055)/1.055, 2.4)
Sun is working on advanced font rendering and layout in the X server. The project is still in the early stages of development, but since it's open source, you can see what's there so far at http://stsf.sourceforge.net/.