Aaron James Young - Salem, Oregon

Website Design and Development

Sans-serif

Posted on Mar 21 2011 | Posted in Web/Tech | No Comments

Chris Coyier’s post at CSS-Tricks on the sans-serif CSS font stack got me thinking. When I see things like this, I usually think, “That’s a cool hack, but how will it work on the many different platforms?” Especially Linux, since I’m a Linux user.

For quick reference, here’s what he says:

font-family: sans-serif; /* don't specify Helvetica or Arial */
  • Macintosh PC’s get Helvetica by default, which is awesome
  • Windows PC’s get Arial by default, which is good because Helvetica doesn’t look good on Windows
  • All others get the browser’s default sans-serif font by default

Well, Linux is in the “all others” category and there are issues:

  • Ubuntu (the most used distro) uses the Ubuntu font by default. It’s a nice font but has a different character, and more importantly, different metrics from Helvetica/Arial
  • Many other distros use DejaVu Sans by default. Also nice (and more generic than Ubuntu), but it also has different metrics than Helvetica/Arial

I personally like Liberation Sans quite a bit. It’s a great sans-serif font that is metrically equivalent to Helvetica and I find it nicer than Arial. It’s installed on many Linux distros by default, so here’s a simple modification that will make things just a little more uniform for many (not all) Linux users:

font-family: 'Liberation Sans', sans-serif;

While I haven’t tested Liberation Sans on a Mac or Windows machine, MOST Mac and Windows users aren’t likely to have it installed and, like I say, I prefer it over Arial, so it’s OK if they do.

This still doesn’t address mobile devices much, especially if they use Droid Sans by default (which I find characteristically a little closer to Trebuchet MS than Helvetica).

Last note: I’d personally only do this for body text, where different fonts aren’t likely to break your layout. Menus, headlines, etc – be more specific about your font choice.

Anyway, those are my thoughts. Cheers.

Aaron James Young is a Salem, Oregon Web Designer and crazy runner / cyclist. He is husband to Evelyn and father to Hanna.

Did you enjoy this post? If so, please comment or check out the whole category of related posts: Web/Tech

Have your say!

From my portfolio...

Selection_008 full Hundini Screenshot Sunset XC Screenshot

Recent Blog Posts

Latest Twitter Updates

Want to tweet with me? Follow me on Twitter!

  • @KayBee1970 yes. awkward.
  • Did I just miss a flyby over South Salem?
  • Just got three wrong number texts in a row from the same person. Thinking of texting back to let them know.
  • I used to think the grammar disaster on chopsticks packages was sort of funny. Now I'm pretty sure it's just a marketing ploy, right?
  • @robmcguire sorry if I'm stepping on your toes there

Latest Delicious Bookmarks

Here's the stuff I found interesting recently. Follow me on Delicious!