bad default aliasing for 'arial'

Bug #203824 reported by puntium
24
This bug affects 2 people
Affects Status Importance Assigned to Milestone
fontconfig (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

I suspect there are many users using "Subpixel" and "Full hinting" as their font setting.

On a hardy system (install from Alpha 6, up to date 3/18/2008), the default fontconfig settings are set up so that 'Nimbuas Sans L" becomes the default alias for 'arial'. This can be confirmed by running:

fc-match 'arial'

on the command line.

Nimbus Sans L has no hinting support, so under the default font settings, it looks terrible. All web pages in firefox that specify 'arial' directly get rendered with this ugly font.

'arial' should probably get aliased to deja vu sans as in previous releases. This is one of the few fonts that look good with 'full' hinting settings.

Revision history for this message
puntium (puntium) wrote :

It looks like it's this file:

/etc/fonts/conf.d/30-metric-aliases.conf

That's causing the problems. If that file is removed, then everything goes back to the happy defaults from before (arial -> Deja Vu Sans, etc.)

I'm not sure what 30-metric-aliases.conf is trying to do, but it's definitely messing up the aliases and leading to a degraded out of the box experience.

Revision history for this message
Tobias Wolf (towolf) wrote :

The Nimbus fonts are PostScript fonts and normally the right replacement for the group Helvetica, Times, Courier, because those are Type1 fonts, too. Unfortunately Helvetica is then aliased to Arial, which would prefer Liberation Sans but that is not available, so Nimbus Sans gets aliased to it.

The reason for the aliases is that in some cases like Word processing metric-compatible font substitution is desirable. A line in Times New Roman should have the same length and height as in the substitution font. Otherwise you get garbage documents. Deja Vu is not metric compatible to the "classic" group.

Now for web browsing having identical metrics should not matter as much as hinting. Is the Liberation set better hinted? It's in Multiverse, but you could install it. You can also try if you like Nimbus better with the autohinter set to "slight".

Revision history for this message
puntium (puntium) wrote :

No, liberation sans is not hinted. The only good hinted fonts that are available by default are the DejaVu series and the Bitstream series (essentially the same font).

I know about all the hinting settings, but that's not the problem here. The problem here is that the default Gnome Desktop is set to 'full' hinting. This in combination with Nimbus Sans getting used for all kinds of websites gives an ugly result.

I'm don't think that having metric-compatible results should be preferred over having fonts that look good under the default settings. The difference in quality is quite striking. Given that OO and other programs have historically had problems with fonts, I don't think people have high expectations.. but if you make every site that specifies Arial look like crap, then you're going to get a lot more complaints, since there are a lot of them.

Can metric equivalent aliasing be made optional?

The real problem is that there different fonts have different levels of hinting, and there's no good default setting that optimizes all the different fonts.

Revision history for this message
Tobias Wolf (towolf) wrote :

I'm normally not a user of office programs, still I fired it up to see how Office is affected if 30-metric-aliases.conf is removed. The relative merit of "uncorrupted documents" vs "good looking hinting" has to be clear here.

So I made a series of tests:

reference: A line of WWW before page break, a line of MMM after page break, all in _Arial™_

1. Arial installed, Liberation installed
2. Arial removed, Liberation is aliased
3. Liberation removed, Nimbus Sans L is aliased
4. 30-metric-aliases.conf removed, DejaVu Sans is aliased.

Hang on, the results don't support your argument, but they show that 30-metric-aliases.conf does not do what it's supposed to achieve. Hence, it could be deactivated, unless Liberation is installed by default.

Revision history for this message
Tobias Wolf (towolf) wrote :

Arial: good

Revision history for this message
Tobias Wolf (towolf) wrote :

Liberation Sans: good (metric compatible, but not DFSG free, and not in main)

Revision history for this message
Tobias Wolf (towolf) wrote :

Nimbus Sans: broken layout

Liberation is not available, so Nimbus is aliased to Arial via the path Arial → Helvetica → Nimbus

n.b.: This is the default setup! metric compatibility is not given.

Revision history for this message
Tobias Wolf (towolf) wrote :

DejaVu Sans: broken layout

I unlinked /etc/fonts/conf.d/30-metric-aliases.conf. Same outcome, layout is not preserved since no metric compatible font for Arial is available.

In principle there's no difference wrt word processing unless Liberation is shipped by default. The same holds for TimesNewRoman→{LiberationSerif|Times→Nimbus Serif}.

BTW: fc-match <fontname> is useful for this.

Revision history for this message
puntium (puntium) wrote :

I'm actually not arguing it from a office app perspective. I rarely use Open Office, and that's not where I first noticed it. I noticed it looking at a page in Firefox.

Whether preserving layouts or having good looking fonts in web pages is more important is just a matter of opinion. I think it's not something worth trying to get to some consensus about since its just the two of us (so far) on this bug, and it's a lose-lose situation anyways.

But as if you say, in the default config, the goal of 30-metric-aliases.conf isn't realized anyways, then I would say then that having those aliases is not worth the cost of every web page specifying arial looking like crap.

Again, as I tried to mention before.. this also has to do with what hinting and subpixel rendering settings the users uses. Nimbus Sans actually can look OK if you use 'no' or 'slight' hinting with subpixel rendering enabled. The problem is that the default ubuntu setting is 'medium' hinting with 'grayscale' antialiasing, which makes nimbus sans look bad compared to the other fonts.

Revision history for this message
Philipp Kohlbecher (xt28) wrote :

I think this bug is a duplicate of bug #41411. Can you confirm this?

Revision history for this message
Tobias Wolf (towolf) wrote :

Yes, kind of. But over at bug #41411 they haven't realized yet that that 30-metric-aliases.conf leads to a /chain/ of aliases, which is the reason for Nimbus popping up everywhere.

Website==Arial → Helvetica → Nimbus Sans
Website==Times New Roman → Times → Nimbus Roman No9

Revision history for this message
kurt belgrave (trinikrono) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. We are sorry that we do not always have the capacity to look at all reported bugs in a timely manner.
There have been many changes in Ubuntu since that time you reported the bug and your problem may have been fixed with some of the updates. It would help us a lot if you could test the current Ubuntu development version (10.10). If you can test it, and it is still an issue, we would appreciate if you could upload updated logs by running apport-collect <bug #>, and any other logs that are relevant for this particular issue.

Changed in fontconfig (Ubuntu):
status: New → Incomplete
Revision history for this message
kurt belgrave (trinikrono) wrote :

We'd like to figure out what's causing this bug for you, but we haven't heard back from you in a while. Could you please provide the requested information? Thanks!

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for fontconfig (Ubuntu) because there has been no activity for 60 days.]

Changed in fontconfig (Ubuntu):
status: Incomplete → Expired
Revision history for this message
Marcin Kulik (sickill) wrote :

I can confirm that on Ubuntu 10.10 this problem still exists.
The easiest way to observe it is to open a page that uses Helvetica in Firefox 4.
Unlinking 30-metric-aliases.conf fixes the problem so I guess this is still exactly the same issue.

Changed in fontconfig (Ubuntu):
status: Expired → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.