On Sat, 18 Oct 2003, Per Olofsson wrote:
> On Fri, 17 Oct 2003, Mika Fischer wrote:
>
> > ioncore/ioncore.c:275
> > ----snip---
> > #ifdef CF_UTF8
> > static bool test_fallback_font(Display *dpy)
> > {
> > XFontStruct *fnt=XLoadQueryFont(dpy, CF_FALLBACK_FONT_NAME);
> >
> > if(fnt==NULL){
> > warn("Failed to load fallback font \"%s\"", CF_FALLBACK_FONT_NAME);
> > return FALSE;
> > }
> > ----snip---
> >
> > Why do you test using XLoadQueryFont when you later on in
> >
> > de/fonts.c:42
> > ----snip----
> > if(xfnt==NULL && strcmp(fontname, CF_FALLBACK_FONT_NAME)!=0){
> > warn("Could not load font \"%s\", trying \"%s\"",
> > fontname, CF_FALLBACK_FONT_NAME);
> > #ifdef CF_UTF8
> > xfnt=XCreateFontSet(wglobal.dpy, CF_FALLBACK_FONT_NAME,
> > &dummy_missing,
> > &dummy_missing_n,
> > &dummy_def);
> > ----snip----
> >
> > load it using the XCreateFontSet function?
> >
> > Is there a reason to this and if yes what is it?
>
> Isn't it that in the first case, it checks whether the locale settings
> work, and in the second case, it is used as a fallback font in case the
> specified font doesn't load? It's two different things.
Oops... I misunderstood you. Sorry. Please disregard my previous message
:)