Mercurial > emacs
comparison src/xterm.c @ 3639:70a688f0cdae
* xterm.c (x_new_font): If font_names is zero, that's all the
indication we get that no matches were found.
author | Jim Blandy <jimb@redhat.com> |
---|---|
date | Fri, 11 Jun 1993 07:02:36 +0000 |
parents | 507f64624555 |
children | fd4187a96445 |
comparison
equal
deleted
inserted
replaced
3638:45169f86d3a4 | 3639:70a688f0cdae |
---|---|
3933 have a list of matching fonts, we compare them against the fonts | 3933 have a list of matching fonts, we compare them against the fonts |
3934 we already have by comparing font ids. */ | 3934 we already have by comparing font ids. */ |
3935 font_names = (char **) XListFontsWithInfo (x_current_display, fontname, | 3935 font_names = (char **) XListFontsWithInfo (x_current_display, fontname, |
3936 1024, &n_matching_fonts, | 3936 1024, &n_matching_fonts, |
3937 &font_info); | 3937 &font_info); |
3938 /* Apparently it doesn't set n_matching_fonts to zero when it can't | |
3939 find any matches; font_names == 0 is the only clue. */ | |
3940 if (! font_names) | |
3941 n_matching_fonts = 0; | |
3942 | |
3938 /* Don't just give up if n_matching_fonts is 0. | 3943 /* Don't just give up if n_matching_fonts is 0. |
3939 Apparently there's a bug on Suns: XListFontsWithInfo can | 3944 Apparently there's a bug on Suns: XListFontsWithInfo can |
3940 fail to find a font, but XLoadQueryFont may still find it. */ | 3945 fail to find a font, but XLoadQueryFont may still find it. */ |
3941 | 3946 |
3942 /* See if we've already loaded a matching font. */ | 3947 /* See if we've already loaded a matching font. */ |