emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/faces.el


From: Richard M . Stallman
Subject: [Emacs-diffs] Changes to emacs/lisp/faces.el
Date: Sun, 23 Oct 2005 20:08:36 -0400

Index: emacs/lisp/faces.el
diff -c emacs/lisp/faces.el:1.338 emacs/lisp/faces.el:1.339
*** emacs/lisp/faces.el:1.338   Sun Oct 23 19:12:50 2005
--- emacs/lisp/faces.el Mon Oct 24 00:08:36 2005
***************
*** 33,39 ****
    (autoload 'xw-defined-colors "x-win"))
  
  (defvar help-xref-stack-item)
- 
  
  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  ;;; Font selection.
--- 33,38 ----
***************
*** 547,552 ****
--- 546,554 ----
  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  
  
+ (defvar inhibit-face-set-after-frame-default nil
+   "If non-nil, that tells `face-set-after-frame-default' to do nothing.")
+ 
  (defun set-face-attribute (face frame &rest args)
    "Set attributes of FACE on FRAME from ARGS.
  
***************
*** 677,685 ****
      (if (memq where '(0 t))
        (put (or (get face 'face-alias) face) 'face-modified t))
      (while args
!       (internal-set-lisp-face-attribute face (car args)
!                                       (purecopy (cadr args))
!                                       where)
        (setq args (cdr (cdr args))))))
  
  
--- 679,690 ----
      (if (memq where '(0 t))
        (put (or (get face 'face-alias) face) 'face-modified t))
      (while args
!       ;; Don't recursively set the attributes from the frame's font param
!       ;; when we update the frame's font param fro the attributes.
!       (let ((inhibit-face-set-after-frame-default t))
!       (internal-set-lisp-face-attribute face (car args)
!                                         (purecopy (cadr args))
!                                         where))
        (setq args (cdr (cdr args))))))
  
  
***************
*** 1730,1752 ****
        (delete-frame frame)))
      frame))
  
- 
  (defun face-set-after-frame-default (frame)
    "Set frame-local faces of FRAME from face specs and resources.
  Initialize colors of certain faces from frame parameters."
!   (if (face-attribute 'default :font t)
!       (set-face-attribute 'default frame :font
!                         (face-attribute 'default :font t))
!     (set-face-attribute 'default frame :family
!                       (face-attribute 'default :family t))
!     (set-face-attribute 'default frame :height
!                       (face-attribute 'default :height t))
!     (set-face-attribute 'default frame :slant
!                       (face-attribute 'default :slant t))
!     (set-face-attribute 'default frame :weight
!                       (face-attribute 'default :weight t))
!     (set-face-attribute 'default frame :width
!                       (face-attribute 'default :width t)))
    (dolist (face (face-list))
      ;; Don't let frame creation fail because of an invalid face spec.
      (condition-case ()
--- 1735,1757 ----
        (delete-frame frame)))
      frame))
  
  (defun face-set-after-frame-default (frame)
    "Set frame-local faces of FRAME from face specs and resources.
  Initialize colors of certain faces from frame parameters."
!   (unless inhibit-face-set-after-frame-default
!     (if (face-attribute 'default :font t)
!       (set-face-attribute 'default frame :font
!                           (face-attribute 'default :font t))
!       (set-face-attribute 'default frame :family
!                         (face-attribute 'default :family t))
!       (set-face-attribute 'default frame :height
!                         (face-attribute 'default :height t))
!       (set-face-attribute 'default frame :slant
!                         (face-attribute 'default :slant t))
!       (set-face-attribute 'default frame :weight
!                         (face-attribute 'default :weight t))
!       (set-face-attribute 'default frame :width
!                         (face-attribute 'default :width t))))
    (dolist (face (face-list))
      ;; Don't let frame creation fail because of an invalid face spec.
      (condition-case ()




reply via email to

[Prev in Thread] Current Thread [Next in Thread]