Commit 25b1546d authored by Kenichi Handa's avatar Kenichi Handa
Browse files

(set_lface_from_font_name): Reject the default fontset.

(Finternal_set_lisp_face_attribute): Use signal_error for the
error of invalid fontset.
parent 75f8dd6a
......@@ -3220,8 +3220,14 @@ set_lface_from_font_name (f, lface, fontname, force_p, may_fail_p)
/* If FONTNAME is actually a fontset name, get ASCII font name of it. */
fontset = fs_query_fontset (fontname, 0);
if (fontset >= 0)
if (fontset > 0)
font_name = XSTRING (fontset_ascii (fontset))->data;
else if (fontset == 0)
if (may_fail_p)
return 0;
abort ();
/* Check if FONT_NAME is surely available on the system. Usually
FONT_NAME is already cached for the frame F and FS_LOAD_FONT
......@@ -4156,7 +4162,7 @@ FRAME 0 means change the face on all frames, and change the default
if (!NILP (tmp))
value = tmp;
else if (EQ (attr, QCfontset))
error ("Invalid fontset", XSTRING (value)->data);
signal_error ("Invalid fontset name", value);
if (EQ (attr, QCfont))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment