Hacker News new | past | comments | ask | show | jobs | submit login
Google and Adobe team up to improve fonts on iOS and Linux (zdnet.com)
98 points by microwise on May 2, 2013 | hide | past | favorite | 76 comments



The article's font sample image is pretty shoddy. They've resized it and so lost all the features of the renderer! To my eyes, the top example seems clearer and sharper than the bottom one.

The original image is found at http://google-opensource.blogspot.com.au/2013/05/got-cff.htm... and is much better.



I'm glad you linked that because the second example, not shown at the ZDNet article, is actually a much better demonstration of improvement IMO.


The "responsive" design of the page might shrink the image down if your window is too narrow. Here's a direct link to the image on the page: http://cdn-static.zdnet.com/i/r/story/70/00/014803/freetype-... which looks fine, I think.


Seriously? Ubuntu has the best font rendering of any operating system that I've used.

Mac OS X is perfectly good, but it doesn't tend to feel as nice as Ubuntu. Especially when you get to things like Indic scripts.

Windows' font rendering (I can only speak for up to Windows 7) is still quite nasty, especially at larger font sizes. The lack of vertical antialiasing ruins it for these cases.


This debate is pointless because people almost always give the nod to what they're personally most accustomed to, perhaps also labelling the others as garbage for good measure.


> Windows' font rendering (I can only speak for up to Windows 7) is still quite nasty, especially at larger font sizes. The lack of vertical antialiasing ruins it for these cases.

Weird, I would consider that Windows has the best font rendering. Do you have any example photos you'd like to show?

A comment below [1] has some pictures, do you really find Windows's rendering to be bad?

1: https://news.ycombinator.com/item?id=5644228


I remember reading that people get very used/comfortable to Mac vs. Windows style of font rendering, and tend to perceive the other as inferior.


Yes, this classic flame war. There used to be a Windows vs OSX font rendering flame war every week on HN, in the good old days.

OSX uses antialiasing, which means the fonts have a nice shape, but they are fuzzy, blurry, and to some users headache-inducing.

Windows reshapes the fonts so they fit perfectly in the pixel grid, but the shape is not what will be printed, and it looks ugly to some users.

Because people like what they are used to, and because Apple vs Microsoft is already a flame war, no-one can really agree.


I used to like Windows' font rendering (when they introduced ClearType), but after having to Mac OS X about five years ago and using an iPhone and iPad for a couple of years I'm so used to Apple's font rendering that Windows looks really ugly to me... Quite subjective though.

Perhaps it's partially due to the fact that Mac laptops and iDevices have higher quality displays than typical Windows machines?


Higher quality... in what way? Resolution, or something else?


Yes, but many are also based on IPS technology instead of TN, which supports a much wider colour gamut.


The article is about an upgrade to the Freetype library, more specifically to the CFF rasterizer. It has nothing to do with TrueType fonts (most of them, probably).

I've been using Arch Linux as my only OS for more than 5 years, and the only certain applications have given me font-related trouble. Firefox somehow doesn't select the correct alternative (even though fontconfig works fine).


Ubuntu's patches for the various font rendering technologies are my #1 must-have software on Linux. Any distro I use is either a Ubuntu or something that has these patches an easy install away. (Arch has them in the AUR, for example)


This has, honestly, been a blind spot of mine and something that has kept me in Ubuntu rather than Arch or Debian. Can you elaborate on what the patches are called and how to replicate Ubuntu's rendering in Arch? Thanks so much.



Now I really feel clueless for not knowing better to check the Arch Wiki. Thanks.


Although I haven't tried 13.04 yet, Qt apps on Ubuntu weren't that great on font rendering. There's room for improvement there.

Also, take into account that Linux is not Ubuntu. It's a growing trend to identify Linux with Ubuntu, as if other distributions (or even other desktop environments in the same Ubuntu distro) weren't to take into account. Have you seen KDE font rendering? Open a Chromium browser, navigate to some pages, it's awful.


Even among the Ubuntu variants, font rendering is only smooth in GTK-based desktop environments, i.e. GNOME/Unity and XFCE. Last time I checked, fonts looked awful in Kubuntu, especially if you opened either Firefox or LibreOffice. Lubuntu likewise looks like it received none of the font rendering improvements that Ubuntu has had by default for ages.

Of course, "awful" is subjective so you might prefer the way KDE and LXDE render fonts. But it doesn't change the fact that they're different.


You can make the fonts looks equally good in Kubuntu by doing this - http://askubuntu.com/questions/130758/how-to-configure-kubun... and changing the Desktop Effect -> Scaling Method to Crisp.


Does it also affect Firefox and LibreOffice?


Yes, just make sure to use the gtk-oxygen theme with the right font for GTK+ apps.


>Also, take into account that Linux is not Ubuntu.

And that FreeType is not Linux only.


What kind of font rendering does Ubuntu uses? I'm on Arch and freetype-infinality rendering is incredibe eye candy.


Agreed. I made this in the past:

http://i.imgur.com/4dGbR.png (Ubuntu)

http://i.imgur.com/mfyjw.png (OS X)

http://i.imgur.com/BqOdg.png (Windows 7)


Interesting: in terms of visual quality, I would rank those in order of decreasing preference as OS X, Windows 7, Ubuntu.


Is Windows even using the same font? I think Windows prioritizes making the text look sharp over getting all the character strokes in the right place. OS X and Ubuntu look very similar except for the line spacing, and the lowercase ‘a’, which looks kind of strange/vertically compressed on Ubuntu.


>I think Windows prioritizes making the text look sharp over getting all the character strokes in the right place.

Yup, pretty much. A trio of Spolsky/Atwood posts from 2007 worth reading:

http://www.codinghorror.com/blog/2007/06/whats-wrong-with-ap...

http://www.joelonsoftware.com/items/2007/06/12.html

http://www.codinghorror.com/blog/2007/06/font-rendering-resp...


They should all be using Verdana, as per HN's CSS. I have the font installed in each OS so it should be a fair fight unless I screwed something different up.


The font in the Ubuntu image is not Verdana.

Ubuntu does not install Microsoft fonts by default. It will fallback to Ubuntu's default font.


I always have msttcorefonts installed which includes Verdana. It's part of the script that is the first thing I run on a new install...

(Like, a half hour ago, I checked that Verdana was installed and then recreated the screenshot from the original post and it's identical as far as I can tell.


The fonts are similar, but you can see the numeral "3" is different. They're not the same font.

Right-click the text and choose "Inspect element". In the right-hand column, make sure "Computed" is selected at the top, then look to see what font-family is being rendered. (If you click "Rules" at the top, you can see which rules are active.)


In my experience, this doesn't necessarily give the correct font. Some distros have font aliases in fontconfig. I've found that `fc-match` can easily find the true font being used for a given font name/pattern, e.g. fc-match monospace might give DejaVu Mono


Yeah, it says Verdana: http://i.imgur.com/50Sx6c3.png

The '3' doesn't look any more different than other chars due to rendering difference, to me.

And KDE's font manager's take on Verdana: http://i.imgur.com/4c5cSe3.png

And Firefox on my system, just as a reference: http://i.imgur.com/a2yZ7UQ.png


Thanks for double-checking. The 'a' looks very different on the Windows 7 sample!


Your right, my mistake. I verified with my ubuntu install. My Verdana looks the same as yours.

There are differences with how the text is rendered. Maybe it has to do with kerning and subpixel optimizations.


I find Windows 7 the most appealing (and sharpest).

The others are just way too blurry.


Windows has distorted the font here hasn't it? If you're rating fonts on sharpness, Windows would win here, but by any other criteria (distortion, kerning, adequate aliasing, legibility), it fails. The Windows rendering almost looks like a monospaced font. You're throwing a lot out in order to get things sharper at small sizes, and for many people, that matters far more than perceived sharpness.


> legibility

Seriously? I could agree that it may not fully represent the intended font, but the entire point is that it's more legible when it sacrifices that, and I find it hard to believe that you find Windows's text to be less legible than Mac's/Ubuntu's.

i.e. I think Windows sacrifices the fontmaker's intent in order to please the reader, who couldn't care less about the fontmaker's intentions rather than the actual output (unless the reader is the fontmaker himself).

Do you really think it's failing in that too?


Kerning, character spacing and character shape are all designed to help legibility, and I think frankly that the Windows approach is a naive attempt to optimise one aspect of legibility at the expense of all others. So yes, I'm afraid I do disagree that it is more legible, I think it sacrifices too much, as these screenshots make clear the font is deformed so much it looks like a different font, spacing is all off, and glyphs are uneven.

This is somewhat subjective, and you might have a different opinion, but there is more than one variable in play when it comes to legibility, it doesn't just come down to how sharp the text is.


I know, I didn't mean to imply sharpness is the only factor. It's just one of several important factors.

But I couldn't care less about the font being deformed, as long as it looked better than it used to. The fact that you seem to care so much about the deformation into a different font seems to imply to me that your goal is to preserve the original font, rather than to make it look nice on the screen.

If you have the time, would you mind taking the pictures in the comment below and making a smaller bitmap that shows exactly which character(s) you think are not kerned well, and which Linux or Mac kerns better? I'm really curious what I'm not seeing.


Kerning: Look at the a in was, or the e in difference, or OS X - all of these have too much space and the difference is obvious. Distortion: IMHO Fonts carry meaning and affect legibility, they are not just there to make text look nice on screen. Deforming a font subtracts meaning, and in some cases will make it less legible, particular an automated deformation like this.


I agree with you. I don't care what the fonts were designed to look like. I only care about readability. The default font settings on Ubuntu hurt my eyes. Thankfully this is easy to fix by switching to full hinting and enabling subpixel rendering.


For anyone wanting the Linux font rendering on Windows - check out MacType (https://code.google.com/p/mactype/). Works best on high-dpi monitors, and it's a matter of taste on low-dpi (little blurrier, but the fonts are more authentic).


It's been my experience that Ubuntu's default font rendering is good--but this seems to be because Ubuntu is using fonts which have been explicitly designed to render well in the Linux font stack. I find that using mainstream TTF and OTF fonts, with their custom hinting and ligatures, works less well.

Soon this will be a non-issue, though. Font engines differ only in how they hint and subpixel render at low resolutions. Once every display is "retina," there will be very little difference, except perhaps in gamma correction, advanced kerning and layout algorithms, where I've found OS X has always produced superior results.


I really don't know much about font rendering, but I thought that was the case too so I installed the Ubuntu fonts on my Arch Linux system, and they looked terrible. According to the Arch wiki, Ubuntu applies their own patches and "extra configurations" for freetype2, cairo, etc. I was able to achieve a similar, but not quite as pleasing result by installing freetype2-infinality on Arch.


Now that font rendering technology on displays has reached that of print thanks to "retina" class displays, how can we improve readability even further? We're no longer constrained by the limitations of the printing press.

What if every vowel in a word were rendered in light grey, and every consonant in black? Or every letter were mapped to one of n subtle (near black) color hues? Or both? Such crazy schemes might further improve word recognition and reduce load on the visual cortex. Perhaps the Kindle, Readability, or iBooks could implement something like this as an experiment. I'd definitely try it.


You can support the development and maintenance of this project by donating here: http://pledgie.com/campaigns/18808.


The rendering of curved lines appears much better, but vertical and horizontal lines are very poorly rendered. You can see this clearly in the Chinese character "中" - the first character inside the parentheses on the first line.


Is it true that iOS uses a different font renderer than Mac OS? I thought that the fonts on an iPhone looked pretty good actually. Perhaps they are referring to apps that decide to use the FreeType renderer?


Unless you're looking at a Retina MacBook Pro, it's not really a fair comparison. Fonts look better on an iPhone simply because the pixel density is much higher than on a typical Mac screen.


> Is it true that iOS uses a different font renderer than Mac OS?

Yes, iOS uses (parts of) FreeType. Imagine the shitstorm if they shipped their fuzzy, washed-out default rendering! The issue is that most people buying smartphones are not die-hard Apple fans like the buyers of their other offerings, so the font rentering would be pretty hard to sell.

> I thought that the fonts on an iPhone looked pretty good actually.

That's because FreeType (with the right patches and settings) is already pretty much the best font renderer (with a few exceptions).


Fuzziness is subjective. iOS uses a similar font rendering method to OS X, without subpixel rendering. See: http://www.smashingmagazine.com/2012/04/24/a-closer-look-at-...


Agreed. OSX's font rendering in my opinion is superior to Ubuntu and other Linux distros. It is subjective though - after all, some people claim to prefer ClearType.


So FreeType font hinting functionality was disabled for years because software patents held by Apple, and now Apple is using FreeType on iOS. Amazing.

I live in the EU and I've been using freetype-freeworld package for years before the patents expired. but still... amazing :)

EDIT: patents have expired


So, since you are clearly a very technically deep and insightful person with lots and lots of industry experience, you are stating with great authority that OS X does not use FreeType to rasterize fonts. Interesting. :)


> Yes, iOS uses (parts of) FreeType.

Do you have a reference for this rather surprising claim?


I only see it mentioned on FreeType’s website, with no details:

“Some products which use FreeType for rendering fonts on screen or on paper, either exclusively or partially: [...] iOS, Apple's mobile operating system for iPhones and iPads”

http://www.freetype.org/

iOS (née iPones OS) never used subpixel rendering, and since the introduction of HiDPI it isn’t needed anymore either. I can imagine that using parts of Freetype instead of using the whole of OS X’s Quartz would’ve made the code for iOS more compact.

http://bjango.com/articles/subpixeltext/

Given that all of the iPhone models and many of the iPad models have HiDPI screens nowadays, I doubt Apple will be using Adobe’s extension, since it’s mostly a problem with low resolution displays.


There is a marked difference between letter shapes rendered with FreeType and with Quartz.

Judging by the letter shapes, I would say it's highly likely iOS uses the same renderer as OS X, at least for common fonts like Helvetica Neue.

However, I don't know if I've seen any CFF fonts. Perhaps this is where FreeType would come in?


Adobe’s solution is mostly interesting for OpenType/CFF and PostScript fonts. iOS’ system fonts are TrueType, so this would only come into play in websites, third party apps, and PDFs that use embedded fonts. Besides, iOS doesn’t use hinting embedded in fonts.

http://blogs.adobe.com/typblography/2010/12/the-benefits-of-...

http://blogs.adobe.com/typblography/2011/09/postscript-comes...

“There is a marked difference between letter shapes rendered with FreeType and with Quartz.”

Oh, definitely. FreeType has always looked like crap (to me) and iOS never did, so I don’t believe iOS’ font renderer is 100% FreeType.


From what I've experienced, I find iOS and Android font rendering is equal in quality, and Android uses freetype so I wouldn't be surprised at iOS using the same.


But finding the right patches and settings is hard.


Doesn't Ubuntu and other out-of-the-box desktop friendly distros come with good font settings from the get go?

I use Arch Linux but even here it's not much of a hassle given that there is a very informative wiki page not to mention packages with good configuration presets (infinality).


> Doesn't Ubuntu and other out-of-the-box desktop friendly distros come with good font settings from the get go?

Yes, exactly!


Try using Infinality (http://www.infinality.net/blog/). I am using it on Fedora 18 and loving it!


The good thing is that it only has to be figured out once, then the information can be spread almost freely ... there is something called “the internet” which excels at this.


"the internet" also excels at spreading misinformation or retaining information that once was correct but no longer is for extended periods of time.


A good start would be to replace fontconfig and its ridiculous XML files.


I hope this brings more consistency to font rendering across OS environments. That would be a great accomplishment and wonderful for web designers!


Is it just me who finds all of them horrible?


I would love to try this out and even went to the distance of downloading the tarball for the beta of '.12. However, it's not clear where the property needs to be set, as there are a few places in the library where FT_Init... is called. On top of that, I am not sure from re-reading this that it helps at all for TT fonts, which is most of what I end up using.


So, does this mean that text on web-pages is going to have inconsistent rasterisation depending on whether the font happens to represent its glyphs with TrueType, PostScript, or CFF outlines?


This is not any different than today (in terms of this problem) as far as I can tell. One part of creating the whole system is creating a unified font catalog in one font format.


How about Google spend some time fixing font rendering in Chrome on Windows? Firefox has nailed it but Chrome hasn't. Some web fonts are unreadable.


so, does it mean freetype and fontconfig will render fonts pretty well without patching them with infinality for example?


Anyone want to host a PPA for Raring with the patched freetype?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: