diff options
| -rw-r--r-- | lisp/faces.el | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/lisp/faces.el b/lisp/faces.el index f721ac0a7e8..028ea671bd7 100644 --- a/lisp/faces.el +++ b/lisp/faces.el | |||
| @@ -1669,15 +1669,17 @@ Value is the new frame created." | |||
| 1669 | (defun face-set-after-frame-default (frame) | 1669 | (defun face-set-after-frame-default (frame) |
| 1670 | "Set frame-local faces of FRAME from face specs and resources. | 1670 | "Set frame-local faces of FRAME from face specs and resources. |
| 1671 | Initialize colors of certain faces from frame parameters." | 1671 | Initialize colors of certain faces from frame parameters." |
| 1672 | ;; Don't let frame creation fail because of an invalid face spec. | ||
| 1672 | (dolist (face (face-list)) | 1673 | (dolist (face (face-list)) |
| 1673 | (when (not (equal face 'default)) | 1674 | (condition-case () |
| 1674 | (face-spec-set face (face-user-default-spec face) frame) | 1675 | (when (not (equal face 'default)) |
| 1675 | (internal-merge-in-global-face face frame) | 1676 | (face-spec-set face (face-user-default-spec face) frame) |
| 1676 | (when (and (memq window-system '(x w32 mac)) | 1677 | (internal-merge-in-global-face face frame) |
| 1677 | (or (not (boundp 'inhibit-default-face-x-resources)) | 1678 | (when (and (memq window-system '(x w32 mac)) |
| 1678 | (not (eq face 'default)))) | 1679 | (or (not (boundp 'inhibit-default-face-x-resources)) |
| 1679 | (make-face-x-resource-internal face frame)))) | 1680 | (not (eq face 'default)))) |
| 1680 | 1681 | (make-face-x-resource-internal face frame))) | |
| 1682 | (error nil))) | ||
| 1681 | ;; Initialize attributes from frame parameters. | 1683 | ;; Initialize attributes from frame parameters. |
| 1682 | (let ((params '((foreground-color default :foreground) | 1684 | (let ((params '((foreground-color default :foreground) |
| 1683 | (background-color default :background) | 1685 | (background-color default :background) |