From 4c5779ab90f6be7862604d700f4b1dee17ba10c4 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sun, 18 Mar 2012 22:18:01 +0800 Subject: [PATCH] * faces.el (face-spec-reset-face): Don't run display-graphic-p if undefined. --- lisp/ChangeLog | 5 +++++ lisp/faces.el | 5 ++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 06b273fa178..a6f5a5fd525 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2012-03-18 Chong Yidong + + * faces.el (face-spec-reset-face): Don't call display-graphic-p if + it is not yet defined (for temacs). + 2012-03-18 Leo Liu * net/rcirc.el (rcirc-cmd-quit): Allow quiting all servers with diff --git a/lisp/faces.el b/lisp/faces.el index bdac3a1bb6a..34fad66ce27 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -1521,7 +1521,10 @@ If SPEC is nil, return nil." (append '(:underline nil :overline nil :strike-through nil :box nil :inverse-video nil :stipple nil :inherit nil) - (unless (display-graphic-p frame) + ;; `display-graphic-p' is unavailable when running + ;; temacs, prior to loading frame.el. + (unless (and (fboundp 'display-graphic-p) + (display-graphic-p frame)) '(:family "default" :foundry "default" :width normal :height 1 :weight normal :slant normal :foreground "unspecified-fg" -- 2.39.5