Grumpy wizards

Oxygen Font Example

Oxygen Font Example

In Plasma, we have traditionally relied on the font settings dictated by the distribution we run on. This means that we’ll take whatever “Sans” font the distro has set up (or has left to something else), and worked with that. The results of that were sub-optimal at least, as it meant we had almost no control how things are going to look like for end users. Fonts matter a lot, since they determine how readable the UI is, but also what impression it gives. They also have effect on sizing, and even more so in Plasma Next.

Many widgets’ size in a UI depend on the font: Will this message actually fit into the allowed space for it? (And then: What about a translated version of this message?) In Plasma Next, we’re relying even more on sensible font settings and metrics in order to improve our support for HighDPI displays (displays that have more than 150 dots per inch). To achieve balance in the UI sizing, and to make sizing based on what really matters (how much content fits in there?), we’ve put a much stronger emphasis on fontsize-as-rendered-on-a-given screen. I’ve explained the basic mechanics behind that in an earlier post, so I won’t go into too much detail about that. Suffice to say that the base unit for our sizing is the height of the letter M rendered on the screen. This gives us a good base metric that takes into account the DPI of the screen, but also the preference of the font as set up by the user. In essence, this means that we design UIs to fit a certain number of columns and rows of text (approximately, and with ample dynamic spacing, so also longer translations fit well). It also means that the size of UI elements is not expressed in pixels anymore, and also not relative to the screen resolution, but that you get roughly the same physical size on different displays. This seems to work rather well, and we have gotten little complaints about sizing being off.

Relying on font metrics for low-level sizing units also means that we need the font to actually tell us the truth about its sizing. We need to know for example, how many pixels a given font on a given screen with a given pointsize will take, and we need this font to actually align with these values. This sounds quite logical, but there are fonts out there who don’t do a really good job in telling their metrics. This can lead to over- or undersizes UIs, alignment and margins being off, and a whole bunch of other visual and usability problems. It also looks bad. I find it personally quite frustrating when I see UIs that I or somebody else has spent quite some time on “getting it juuuuuust right”, and then seeing it completely misaligned and wrongly sized, just because some distro didn’t pay enough attention to choose a well-working (by our standards, of course ;)) font.

Oxygen Font in Kickoff Launcher

Oxygen Font in Kickoff Launcher rendered at 180DPI

So, to mitigate these cases, we’ve chosen to be a bit more bold about font selection in Plasma Next. We are now including the Oxygen font and setting it up as default on new installs. This means that we know the defaults work, and they work well across a range of displays and systems. We’re also defaulting to certain renderer settings, so the fonts look as smooth as possible on most machines. This fixes a slew of possible technical issues, but it also has a huge impact on esthetics. By setting a default font, we provide a clearer idea of “with this setup, we feel it’s going to look just right”.

For this, we’ve chosen the Oxygen font, which has been created by Vernon Adams, is released under the SIL Open Font License and has been created under the Google webfonts project. It’s a really beautifully done, modern, simple and clean typeface. It is optimized for rendering with Freetype, and it mainly targets web browsers, desktops, laptops and mobile devices. Vern has created this font for Oxygen and in collaboration with some of the Oxygen designers. The font has actually been around for a while already, but we feel it’s now ready for prime-time, so limelight it is.

As it happens with Free software, this has been a long-lasting itch to scratch for me. One of the first thing I had to do with every install of Plasma (or previously, KDE 3 even), was to change the fonts to something bearable. Imagine finishing the installer, and being greeted with Helvetica — Barf. (And Helvetica isn’t even that bad a font, I’ve seen much worse.) I’m glad we could fix this now in Plasma Next, and I’m confident that this will help many users having a nicer looking desktop without changing anything.

Apart from the technicalities, there will always be users who have a strong preference for a certain font, or setting. For those, we have the font selection in our systemsettings, so you can always set up your personally preferred font. We’re just changing the default.

23 Responses to “Grumpy wizards”

  1. Jos Poortvliet says:

    Really, you don’t want to support my favorite comic sans font? No more KDE for me, I move to GNOME which actually listens to users!

    • sebas says:

      Ow, we totally do. Just setting Comic Sans as default didn’t seem to be a good idea. (It’s not Free by our standards. :P)

    • mgraesslin says:

      I think that’s a valid request. Can we add a check for username == “jos”?

  2. Stephen Boddy says:

    The “m” character in the paragraph at the bottom of the example image looks like it may be badly hinted or something. The middle stem looks too far left, unbalancing the negative spaces. Yet when I go to the Google Fonts page it looks OK. Possibly something on your system when you took the grab?

    • sebas says:

      Well, the image shown is resized, that might well be the reason. Also, what’s rendered on my display might look different on yours.

  3. hwti says:

    With my settings (full hinting, no subpixel AA), this fonts looks a lot more blurry than Liberation Sans (1.07) and DejaVu Sans.
    Perhaps it looks better on HighDPI displays, but IMHO it’s worse at 96 DPI due to insufficient hinting.

  4. Dar says:

    I think the Oxygen font is a great choice. I personally hated the ubuntu font that was the default on Kubuntu, and switched to Oxygen font last year. Before that I was using DejaVu Sans.

  5. D.R.P. Charbonneau says:

    I think using the Ubuntu font by default, which is also freely available and distributed on Google Fonts, makes a better bet than Oxygen; not that Oxygen is a bad font, Ubuntu just looks cleaner.

    • sebas says:

      The Ubuntu font is exactly that: a mark that is part of Ubuntu’s trademark. We don’t want to step onto anyone’s toes, and I think we’ve seen the occasional going wild of their branding people. I’d also consider it bad style, whether I like the font or not. (Truth be told: I’m not super fond (hah!) of it, but that’s purely personal preference.)

  6. Mantas says:

    Ah, about time. Default font is an important part of a desktop environment; GNOME has Cantarell, and KDE 4 always looked kinda ugly with the stock default DejaVu Sans. (Not that KDE 4 looked really nice any font — it seems like there have been many improvements in version 5 — but still.)

    …that said, when I saw the post’s title, I kind of expected it to be talking about how some design choice has pissed off a bunch of Unixbeards Who Have Used KDE Since Day One. I wonder what the reaction to a new default font will be.

  7. joncr says:

    Opting for a default font is fine. Opting for a design that breaks when someone chooses another font or font size is not so good.

    • sebas says:

      Well, users can break their user experience in so many ways, using a font that sucks is only one of them. ;)

      We don’t rely specifically on Oxygen, we just know that this font works reasonably well (as do many others, but not all of them).

  8. DanaKil says:

    Speaking about fonts and UI, each time I’m reading something on your blog, I’m wondering why I have to horizontally scroll the display to be able to read the article (my laptop is on 1366×768)

    ;-)

    And thank you for your role on KDE btw

  9. Zipristin says:

    My only worry is:

    -Do you really choose Oxygen font because is really the best font for plasma-next/kf5 or only because it’s called “Oxygen font”? Would you have choosen the same font if it was called for example, “Adwaita font” or “Vista font”?

    Don’t get me wrong, I know that is only the default font and can be replaced. It’s only I think there are objectively better fonts: Droid, Liberation, Deja Vu, Noto, Open Sans… In my opinion Oxygen fonts are too blurred and not very well rendered, especially monospaced. But it can be my eyes or my config, I’m not expert and it’s only my opinion.

    Thanks anyway, nice article.

    • sebas says:

      No, we have chosen it because it matches our concepts wel, and because its creator is participating in the development. We are not just picking some third party thing because it had a suitable name.

  10. Eike Hein says:

    On the topic of font settings: A personal pet peeve of mine is that we won’t let you configure the priority of fonts used in glyph substitution, i.e. what fonts will be used as fallbacks to render letters when the primary font doesn’t have them — in fact, I know of no free desktop environments that do. This is something I’d like to address for the second release of Plasma Next, as it would greatly help users who mix writing systems that are rarely covered by a single font family.

    My current thinking is to have our System Settings module do what I do manually – write out aliases for active fonts into fontconfig – but if you’re more clueful about the font stack than me and would like to weigh in (or help out!) to have this be as good as it can be, please get in touch at lastname@kde.org.

  11. Anonymous says:

    So I went and looked on the Google Fonts thing, and this font has no glyph for “%”. Is that just an oversight or some problem with Google Fonts? Additionally there seem to be some weird gaps: For example the font has a ŝ (small s caret), but not Ŝ (capital S caret). (Not that I particularly care about those characters, but it seems to indicate a certain lack of attention to detail.)

  12. sinma says:

    Hi, I really like Ubuntu font but is a bit too curvy in my opinion, don’t look well on some websites that mix fonts and Ubuntu Mono with full hinting have one-pixel-wide pixels and m rendering is awful. So now I’m using DejaVu Sans or Ubuntu and DejaVu Mono because it’s the only font I really like at 96dpi and full hinting.

    I like Oxygen Sans because I found it more pleasant than DejaVu Sans, and it made a difference between capital i and minuscule l, which really great because many fonts doesn’t and it’s a pain in the ass to discover what letters it really is.

    The only problem i have with Oxygen is that it’s really ugly at 96dpi in my opinion.

    • anonymity is great says:

      Try setting the hinting style to “Slight” (either in the System Settings or directly in .config/fontconfig/fonts.conf) or use the version of the Oxygen font provided in the ttf-oxygen-font-family package in Kubuntu 14.04 instead of the version from git.

      • sinma says:

        It looks better, but I don’t really like slight hinting, because all the characters looks blurry. And I’m using Arch Linux and ttf-oxygen package.

  13. Eric says:

    What happened to Comme?

    • sebas says:

      Comme has a few alignment problems in our interfaces which we’re working out, still. It will likely take Oxygen’s place later on.

  14. anonymity is great says:

    I am totally in favor of having a default font in Plasma which is developed by KDE. It looks great and it is certainly a decent font to be the default in Plasma. I particularly like the fact that I, i, l and 1 are easily distinguishable.