# HG changeset patch # User Richard M. Stallman # Date 754386739 0 # Node ID 1f14aa44c7865b8b9ac3ebd98b9732877badc684 # Parent c684276af9f26bb3121bfd08072740d774dde75a (mouse-set-font): Update nonstandard faces that are supposed to use a modification of the frame's font. diff -r c684276af9f2 -r 1f14aa44c786 lisp/mouse.el --- a/lisp/mouse.el Sat Nov 27 06:37:16 1993 +0000 +++ b/lisp/mouse.el Sat Nov 27 07:52:19 1993 +0000 @@ -1279,7 +1279,24 @@ (set-face-font 'italic nil (selected-frame)) (make-face-italic 'italic (selected-frame) t) (set-face-font 'bold-italic nil (selected-frame)) - (make-face-bold-italic 'bold-italic (selected-frame) t)))) + (make-face-bold-italic 'bold-italic (selected-frame) t) + ;; Update any nonstandard faces whose definition is + ;; "a bold/italic/bold&italic version of the frame's font". + (let ((rest global-face-data)) + (while rest + (condition-case nil + (if (listp (face-font (cdr (car rest)))) + (let ((bold (memq 'bold (face-font (cdr (car rest))))) + (italic (memq 'italic (face-font (cdr (car rest)))))) + (if (and bold italic) + (make-face-bold-italic (car (car rest)) (selected-frame)) + (if bold + (make-face-bold (car (car rest)) (selected-frame)) + (if italic + (make-face-italic (car (car rest)) (selected-frame))))))) + (error nil)) + (setq rest (cdr rest)))) + ))) ;;; Bindings for mouse commands.