Font lookup ranges [was Re: Notes on Pango Xft backend]



[ splitting up my reply a bit ]

> > The fundamental font operation in the Pango XFT backend (or any Pango
> > backend) is to map from a unicode codepoint and a PangoFontDescription
> > (family, style, weight, stretch, variant) to a particular PangoXftFont.
> 
> Are you thinking of doing sequences of codepoints at some point to avoid 
> ransom note results?

I've considered it; not something I've tackled yet for various reasons:

 a) Not sure how big segments of text to use; anything smaller than
    paragraphs probably a) doesn't solve the problem b) presents
    an unclear model to the user. But doing paragraphs at a time
    really breaks the Pango shaping model. 

    (What do you do with Roman A/Greek/Roman B, where Roman B forces a
    different font....)

    And even paragraphs at a time can give problems with short
    headings; single sentences.

 b) If your roman fonts are reasonably complete, then things won't
    be bad, since other than that typically fonts are complete
    for a given script.

 c) Stability issues probably mean that for editing, character granularity
    is best; so it would have to be  controllable in the Pango API.
    dependent on how the text is being used.

The one place where a fix is urgently needed is for Japanese
vs. Traditional Chinese vs. Simplified Chinese; things look pretty
awful there at the moment; but what I want to do first in that area
is make font selection locale/language-tag sensitive.

Regards,
                                        Owen



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]