X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/70ccc86659c536faae2f554f3d551cbc132b71b7..2c3d59853173258cd84dab5b12c239705dd8fc02:/lisp/faces.el diff --git a/lisp/faces.el b/lisp/faces.el index c9da85b19c..4a7d951aea 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -149,7 +149,8 @@ If the optional FRAME argument is provided, change only in that frame; otherwise change each frame." (interactive (internal-face-interactive "font")) (if (stringp font) - (setq font (or (resolve-fontset-name font) + (setq font (or (and (not (eq window-system 'w32)) + (resolve-fontset-name font)) (x-resolve-font-name font 'default frame)))) (internal-set-face-1 face 'font font 3 frame) ;; Record that this face's font was set explicitly, not automatically, @@ -164,7 +165,8 @@ If the optional FRAME argument is provided, change only in that frame; otherwise change each frame." (interactive (internal-face-interactive "font")) (if (stringp font) - (setq font (or (resolve-fontset-name font) + (setq font (or (and (not (eq window-system 'w32)) + (resolve-fontset-name font)) (x-resolve-font-name font 'default frame)))) (internal-set-face-1 face 'font font 3 frame)) @@ -1136,7 +1138,8 @@ selected frame." (while (not (eobp)) (insert " ") (forward-line 1)))) - (goto-char (point-min)))) + (goto-char (point-min))) + (print-help-return-message)) ;; If the *Faces* buffer appears in a different frame, ;; copy all the face definitions from FRAME, ;; so that the display will reflect the frame that was selected. @@ -1166,7 +1169,8 @@ selected frame." (let ((doc (face-documentation face))) (if doc (princ doc) - (princ "not documented as a face."))))) + (princ "not documented as a face."))) + (print-help-return-message))) ;;; Setting a face based on a SPEC. @@ -1343,6 +1347,19 @@ If FRAME is nil, the current FRAME is used." ;; Put the geometry parameters at the end. ;; Copy default-frame-alist so that they go after it. (setq parameters (append parameters default-frame-alist parsed))))) + + (if default-enable-multibyte-characters + ;; If an ASCII font is specified in PARAMETERS, we try to create + ;; a fontset from it, and use it for the new frame. + (condition-case nil + (let ((font (cdr (assq 'font parameters)))) + (if (and font + (not (query-fontset font))) + (setq parameters + (cons (cons 'font (create-fontset-from-ascii-font font)) + parameters)))) + (error nil))) + (let (frame) (if (null global-face-data) (progn