[Bug 517789] Droid Sans overrides default Japanese desktop font

bugzilla at redhat.com bugzilla at redhat.com
Mon Sep 7 02:41:39 UTC 2009


Please do not reply directly to this email. All additional
comments should be made in the comments box of this bug.


https://bugzilla.redhat.com/show_bug.cgi?id=517789





--- Comment #11 from Behdad Esfahbod <besfahbo at redhat.com>  2009-09-06 22:41:38 EDT ---
This is what I wrote to Nicolas in email:

Hey,

Ok, lets see.  A few issues:

1. Why the seemingly random numbers for the conf files?

2. Should I add Droid fonts to default fontconfig config?  At least just the
aliasing to/from generics?

3. You should also alias back "Droid Sans Japanese" and "Droid Sans Fallback"
to "Droid Sans" now that we are renaming those.

4. You use "prefer", while you really should use "accept".  That's perhaps why
the default Japanese font is affected.

5. Lets understand what target="scan" is: It is applied to patterns scanned
from the font (that is, what fc-query returns), and can modify it.  So any lang
you match there is the languages found in the font, not the user-specified
language.

6. The renaming is easy.  The reordering harder, since now we have three fonts
all named "Droid Sans" and we don't have any way to address them separately. I
checked the coverages, Fallback and Sans overlap a bit.  If we could just
delete the lang="ja" from Fallback's coverage, we were mostly done.  But that's
currently not possible for a stupid reason.  I filed a bug about that.

In the mean time, this is the solution I came up with: we force a fixed order
on the three, by modifying their version tag.  So, Japanese gets the highest
version number, 3, and Sans gets 2, finally Fallback gets 1.  This means, when
Fontconfig is matching Droid Sans, it tries Japanese first, if the language
coverage is enough (ie, we are looking for Japanese), it's matched, otherwise
Sans is tried, and finally Fallback.  Voila.  Attached config file for that. A
bit hacky to override the version tag, but I can't think of a better solution
right now.

7. Given this scheme, and for RPM font tagging to work correctly (that is, to
tag with "Droid Sans" instead of "Droid Sans Japanese"), we need to switch the
RPM hook from calling fc-query to call fc-scan instead.  The arguments are the
same, the latter also applies the configuration rules.  That should do it,
except for a but that I just fixed, so next fontconfig release will have it.
Can you communicate the change with Panu?

Cheers,
behdad

-- 
Configure bugmail: https://bugzilla.redhat.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.




More information about the Fedora-fonts-bugs-list mailing list