Mercurial > emacs
changeset 101025:18e1be1514e1
(face-valid-attribute-values): Use string as value for :family
attribute. Now, font-family-list returns a list of strings.
(x-font-family-list): Obsolete compatibility version of function
from xfaces.c.
author | Chong Yidong <cyd@stupidchicken.com> |
---|---|
date | Fri, 09 Jan 2009 14:11:12 +0000 |
parents | cc2605b07baa |
children | 3a728ce08dd6 |
files | lisp/faces.el |
diffstat | 1 files changed, 13 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/faces.el Fri Jan 09 14:10:46 2009 +0000 +++ b/lisp/faces.el Fri Jan 09 14:11:12 2009 +0000 @@ -988,7 +988,7 @@ (case attribute (:family (if (window-system frame) - (mapcar #'(lambda (x) (cons (symbol-name x) x)) + (mapcar (lambda (x) (cons x x)) (font-family-list)) ;; Only one font on TTYs. (list (cons "default" "default")))) @@ -2681,6 +2681,18 @@ (internal-frob-font-slant font "i"))) (make-obsolete 'x-make-font-bold-italic 'make-face-bold-italic "21.1") +(defun x-font-family-list (&optional frame) + "Return a list of available font families on FRAME. +If FRAME is omitted or nil, use the selected frame. +Value is a list of conses (FAMILY . FIXED-P) where FAMILY +is a font family, and FIXED-P is non-nil if fonts of that family +are fixed-pitch." + (if (fboundp 'font-family-list) + (mapcar (lambda (family) (cons family nil)) + (font-family-list)) + '(("default" . t)))) +(make-obsolete 'x-font-family-list 'font-family-list "23.1") + (provide 'faces) ;; arch-tag: 19a4759f-2963-445f-b004-425b9aadd7d6