From: Kenichi Handa Date: Fri, 10 Jan 2003 07:22:03 +0000 (+0000) Subject: (x_new_fontset): Change the arg FONTSETNAME to Lisp X-Git-Tag: emacs-pretest-23.0.90~8295^2~1864^2~113 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=77dabd3b55fe1e46565270b58f0690b161c302cc;p=emacs.git (x_new_fontset): Change the arg FONTSETNAME to Lisp string. Use new_fontset_from_font_name to create a fontset from a font name. --- diff --git a/src/xterm.c b/src/xterm.c index 893a09db885..fdfc21338ac 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -12321,9 +12321,9 @@ x_new_font (f, fontname) Lisp_Object x_new_fontset (f, fontsetname) struct frame *f; - char *fontsetname; + Lisp_Object fontsetname; { - int fontset = fs_query_fontset (build_string (fontsetname), 0); + int fontset = fs_query_fontset (fontsetname, 0); Lisp_Object result; if (fontset > 0 && f->output_data.x->fontset == fontset) @@ -12337,24 +12337,15 @@ x_new_fontset (f, fontsetname) if (fontset >= 0) result = x_new_font (f, (XSTRING (fontset_ascii (fontset))->data)); else - result = x_new_font (f, fontsetname); + result = x_new_font (f, XSTRING (fontsetname)->data); if (!STRINGP (result)) /* Can't load ASCII font. */ return Qnil; + fontset = fs_query_fontset (result, 0); if (fontset < 0) - { - Lisp_Object func; - - func = intern ("create-fontset-from-ascii-font"); - if (! NILP (Ffboundp (func))) - result = call2 (func, result, result); - else - Fnew_fontset (result, - Fcons (Fcons (Qascii, Fcons (result, Qnil)), Qnil)); - fontset = fs_query_fontset (result, 0); - } + fontset = new_fontset_from_font_name (result); /* Since x_new_font doesn't update any fontset information, do it now. */ f->output_data.x->fontset = fontset;