comparison src/objects-tty.c @ 4353:4143b78d0df0

Merge an old patch of Ben's, involving font instantiation and charsets. 2007-12-23 Aidan Kehoe <kehoea@parhasard.net> * objects-tty.c (tty_find_charset_font): * objects-msw.c (mswindows_font_spec_matches_charset_stage_2): * objects-msw.c (mswindows_font_spec_matches_charset_stage_1): * objects-xlike-inc.c (x_font_spec_matches_charset): * objects-xlike-inc.c (gtk_font_spec_matches_charset): If the charset is not specified when calling the font_spec_matches_charset device method, its value is Qnil, not Qunbound. See http://mid.gmane.org/E1EfbmW-00029r-5G@iwi191.iwi.uni-sb.de and Ben Wing's patch of http://mid.gmane.org/439FA06B.3090007@xemacs.org.
author Aidan Kehoe <kehoea@parhasard.net>
date Sun, 23 Dec 2007 15:29:17 +0100
parents 77138fc618a9
children 3a87551bfeb5
comparison
equal deleted inserted replaced
4352:d2f4dd8611d9 4353:4143b78d0df0
345 if (!the_nonreloc) 345 if (!the_nonreloc)
346 the_nonreloc = XSTRING_DATA (reloc); 346 the_nonreloc = XSTRING_DATA (reloc);
347 fixup_internal_substring (nonreloc, reloc, offset, &length); 347 fixup_internal_substring (nonreloc, reloc, offset, &length);
348 the_nonreloc += offset; 348 the_nonreloc += offset;
349 349
350 if (UNBOUNDP (charset)) 350 if (NILP (charset))
351 return !memchr (the_nonreloc, '/', length); 351 return !memchr (the_nonreloc, '/', length);
352 the_nonreloc = (const Ibyte *) memchr (the_nonreloc, '/', length); 352 the_nonreloc = (const Ibyte *) memchr (the_nonreloc, '/', length);
353 if (!the_nonreloc) 353 if (!the_nonreloc)
354 return 0; 354 return 0;
355 the_nonreloc++; 355 the_nonreloc++;
377 font, 0, -1, initial)) 377 font, 0, -1, initial))
378 return font; 378 return font;
379 return Qnil; 379 return Qnil;
380 } 380 }
381 381
382 if (UNBOUNDP (charset)) 382 if (NILP (charset))
383 return font; 383 return font;
384 384
385 return concat3 (font, build_string ("/"), 385 return concat3 (font, build_string ("/"),
386 Fsymbol_name (XCHARSET_NAME (charset))); 386 Fsymbol_name (XCHARSET_NAME (charset)));
387 } 387 }