Around 9 o'clock on Aug 12, Brian Stell wrote:

> You have hit a very important issue here: how to tell what is
> happening on a user's system when the bug-fixer/developer cannot
> reproduce the problem.

Yeah, that's why I left all of the diagnostic tracing messages in 
fontconfig and Xft.  None of it is documented, but with source in hand, 
you can trace what a particular request goes through in rather fine detail.

One of the pieces that can be displayed is the pattern after the default 
substitutions have been applied; that includes the language as provide by 
the application or extracted from the environment.

> Any thoughts on what would be a good fallback if the document does
> not specify a language group and the document encoding does not
> give a hint (eg: Unicode)?

I always fall back to the first available font from the generic alias.
Because the aliases aren't per-language in fontconfig, there's only one 
place to set this.  Essentially, the algorithm is:

        Prefer a strong family match
        Prefer a language match
        Prefer a weak family match

Strong/weak is the binding as specified by the application or 
configuration, the default for application bindings is strong while the 
default for configuration bindings is weak.

Two fonts both matching language get sorted according to the order of the
family names provided by the application and edited by the configuration.

The idea is to permit one lengthy generic alias and have the first element 
with matching language used for each request.  This gives greater 
consistency to the selection when using multiple languages; each fonts
in the list will be used across their supported languages automatically, 
except where fonts earlier in the list have support.  Place 'Arial Unicode 
MS' first in the generic alias and you'll have a uniform (if displeasing) 
appearance across almost all text.

One explicit goal is to permit a global configuration which is generally 
usable by everyone without change; any local customizations neeed to the 
global configuration file should be considered bugs.

Keith Packard        XFree86 Core Team        HP Cambridge Research Lab


_______________________________________________
Fonts mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/fonts

Reply via email to