diff options
author | Karl Heuer <kwzh@gnu.org> | 1994-09-14 03:22:57 +0000 |
---|---|---|
committer | Karl Heuer <kwzh@gnu.org> | 1994-09-14 03:22:57 +0000 |
commit | 233a8755ea9b179113d0aa29b0b756014328e2f8 (patch) | |
tree | 75cf66e018932c817a85fae39576c1e3f67b4af2 /lisp/faces.el | |
parent | 8aceb1d242cfa642642c47f7059e82e35f8a447e (diff) | |
download | emacs-233a8755ea9b179113d0aa29b0b756014328e2f8.tar.gz |
(make-face-unbold, make-face-unitalic, make-face-bold, make-face-italic,
make-face-bold-italic): Don't try to frob font if it's nil.
Diffstat (limited to 'lisp/faces.el')
-rw-r--r-- | lisp/faces.el | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lisp/faces.el b/lisp/faces.el index 9af2a9a9371..a058292ab39 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -544,7 +544,7 @@ If NOERROR is non-nil, return nil on failure." (setq font (or font (face-font 'default frame) (cdr (assq 'font (frame-parameters frame))))) - (make-face-bold-internal face frame font)) + (and font (make-face-bold-internal face frame font))) (or (not (equal ofont (face-font face))) (and (not noerror) (error "No bold version of %S" font)))))) @@ -582,7 +582,7 @@ If NOERROR is non-nil, return nil on failure." (setq font (or font (face-font 'default frame) (cdr (assq 'font (frame-parameters frame))))) - (make-face-italic-internal face frame font)) + (and font (make-face-italic-internal face frame font))) (or (not (equal ofont (face-font face))) (and (not noerror) (error "No italic version of %S" font)))))) @@ -618,7 +618,7 @@ If NOERROR is non-nil, return nil on failure." (setq font (or font (face-font 'default frame) (cdr (assq 'font (frame-parameters frame))))) - (make-face-bold-italic-internal face frame font)) + (and font (make-face-bold-italic-internal face frame font))) (or (not (equal ofont (face-font face))) (and (not noerror) (error "No bold italic version of %S" font)))))) @@ -672,7 +672,7 @@ If NOERROR is non-nil, return nil on failure." (setq font1 (or font1 (face-font 'default frame) (cdr (assq 'font (frame-parameters frame))))) - (setq font (x-make-font-unbold font1)) + (setq font (and font1 (x-make-font-unbold font1))) (if font (internal-try-face-font face font frame))) (or (not (equal ofont (face-font face))) (and (not noerror) @@ -704,7 +704,7 @@ If NOERROR is non-nil, return nil on failure." (setq font1 (or font1 (face-font 'default frame) (cdr (assq 'font (frame-parameters frame))))) - (setq font (x-make-font-unitalic font1)) + (setq font (and font1 (x-make-font-unitalic font1))) (if font (internal-try-face-font face font frame))) (or (not (equal ofont (face-font face))) (and (not noerror) |