MathewWi / freetype-gl

Automatically exported from code.google.com/p/freetype-gl
Other
0 stars 0 forks source link

Support for substitute fonts / unicode strings? #4

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Do you plan to support font substitution, so that when a font doesn't supply a 
needed glyph, it is loaded from another automatically? That would be nice for 
general unicode support, since very few fonts support the full unicode range. 
You already seem to use fontconfig, so that shouldn't introduce new 
dependencies.

Original issue reported on code.google.com by chr....@gmx.net on 4 Sep 2011 at 10:39

GoogleCodeExporter commented 9 years ago
I would need the name of the default font to be used on every platform and I'm 
not sure of the result since the look & feel would be quite different.

Original comment by Nicolas.Rougier@gmail.com on 12 Sep 2011 at 6:16

GoogleCodeExporter commented 9 years ago
I'm not sure why you'd need the default font. What I meant was to take a 
substitute font from fontconfig, when the given font doesn't have the needed 
glyph. Or maybe, since fontconfig might only be set up properly on Linux 
systems, to be able to manually construct font sets from which substitute fonts 
are taken.

Original comment by chr....@gmx.net on 16 Sep 2011 at 1:22

GoogleCodeExporter commented 9 years ago
Ok, but I'mnot sure how to find a substitute font from fontconfig. Let's say I 
requested 'Arial' and see that I miss some glyphs, what is the font to be 
requested to get the missing glyph ?

Original comment by Nicolas.Rougier@gmail.com on 19 Sep 2011 at 12:09

GoogleCodeExporter commented 9 years ago
I have to admit that I don't know how fontconfig works on the developer side. 
As a user, I can e.g. put

        <alias>
                <family>PT Serif</family>
                <prefer>
                        <family>PT Serif</family>
                        <family>Sazanami Mincho</family>
                </prefer>
        </alias>

in my configuration, then when selecting PT Serif in an application and showing 
Japanese text, Sazanami Mincho will be used.

Original comment by chr....@gmx.net on 19 Sep 2011 at 3:12

GoogleCodeExporter commented 9 years ago
Well, me neither and it would request a lot of work I fear.
If someone comes with a nice solution, I will include it.

Original comment by Nicolas.Rougier@gmail.com on 22 Sep 2011 at 6:42