# HG changeset patch # User Kenichi Handa # Date 1213616643 0 # Node ID c0401e586ca3d09cfb49a75e4f2e96a6804c5517 # Parent 8e1702dc030cfe5d9df2ac753326fadbdce575f9 (Ffont_get): Return a symbol for :weight, :slant, and :width. diff -r 8e1702dc030c -r c0401e586ca3 src/font.c --- a/src/font.c Mon Jun 16 11:26:22 2008 +0000 +++ b/src/font.c Mon Jun 16 11:44:03 2008 +0000 @@ -3627,7 +3627,11 @@ VALUE must be a non-negative integer or a floating point number specifying the font size. It specifies the font size in pixels (if VALUE is an integer), or in points (if VALUE is a float). -usage: (font-spec ARGS ...) */) +usage: (font-spec ARGS ...) + +`:name' + +VALUE must be a string of XLFD-style or fontconfig-style font name. */) (nargs, args) int nargs; Lisp_Object *args; @@ -3728,6 +3732,8 @@ CHECK_SYMBOL (key); idx = get_font_prop_index (key); + if (idx >= FONT_WEIGHT_INDEX && idx <= FONT_WIDTH_INDEX) + return font_style_symbolic (font, idx, 0); if (idx >= 0 && idx < FONT_EXTRA_INDEX) return AREF (font, idx); return Fcdr (Fassq (key, AREF (font, FONT_EXTRA_INDEX)));