# HG changeset patch # User Kenichi Handa # Date 1147264597 0 # Node ID a0f76f94602554255e70c7c1f67458a6ea443110 # Parent 422d3b8bf63ee7bf37ce66b6c89fb9013f3c6f93 (realize_default_face): If the font chosen for the default face was different from the frame font, adjust the frame font. diff -r 422d3b8bf63e -r a0f76f946025 src/xfaces.c --- a/src/xfaces.c Wed May 10 08:25:29 2006 +0000 +++ b/src/xfaces.c Wed May 10 12:36:37 2006 +0000 @@ -7072,6 +7072,16 @@ check_lface (lface); bcopy (XVECTOR (lface)->contents, attrs, sizeof attrs); face = realize_face (c, attrs, 0, NULL, DEFAULT_FACE_ID); + +#ifdef HAVE_WINDOW_SYSTEM +#ifdef HAVE_X_WINDOWS + if (face->font != FRAME_FONT (f)) + /* As the font specified for the frame was not acceptable as a + font for the default face (perhaps because auto-scaled fonts + are rejected), we must adjust the frame font. */ + x_set_font (f, build_string (face->font_name), Qnil); +#endif /* HAVE_X_WINDOWS */ +#endif /* HAVE_WINDOW_SYSTEM */ return 1; }