[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bongo-patches] Add Emacs 21 compatibility wrappers `bongo-face-foregrou
From: |
Daniel Brockman |
Subject: |
[bongo-patches] Add Emacs 21 compatibility wrappers `bongo-face-foreground' and `bongo-face-background' |
Date: |
Fri, 29 Dec 2006 11:13:30 +0100 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
Wed Dec 27 11:40:11 CET 2006 Daniel Brockman <address@hidden>
* Add Emacs 21 compatibility wrappers
`bongo-face-foreground' and `bongo-face-background'.
diff -rN -u old-bongo/bongo.el new-bongo/bongo.el
--- old-bongo/bongo.el 2006-12-29 11:13:21.000000000 +0100
+++ new-bongo/bongo.el 2006-12-29 11:13:22.000000000 +0100
@@ -83,6 +83,10 @@
(if (<= emacs-major-version 21)
(require 'bongo-emacs21)
+ (defalias 'bongo-face-foreground
+ 'face-foreground)
+ (defalias 'bongo-face-background
+ 'face-background)
(eval-and-compile
(defalias 'bongo-define-obsolete-function-alias
'define-obsolete-function-alias)
@@ -847,7 +851,7 @@
:group 'bongo-mode-line)
(defcustom bongo-mode-line-icon-color
- (face-foreground 'mode-line nil 'default)
+ (bongo-face-foreground 'mode-line nil 'default)
"Color of Bongo mode line icons."
:type 'string
:group 'bongo-mode-line)
@@ -7347,8 +7351,8 @@
(defvar bongo-logo
(find-image
(list (list :type 'pbm :file "bongo-logo.pbm"
- :foreground (face-foreground 'bongo-comment nil t)
- :background (face-background 'bongo-comment nil t)))))
+ :foreground (bongo-face-foreground 'bongo-comment nil t)
+ :background (bongo-face-background 'bongo-comment nil t)))))
(defun bongo-insert-comment-text (text)
(let ((inhibit-read-only t))
diff -rN -u old-bongo/bongo-emacs21.el new-bongo/bongo-emacs21.el
--- old-bongo/bongo-emacs21.el 2006-12-29 11:13:21.000000000 +0100
+++ new-bongo/bongo-emacs21.el 2006-12-29 11:13:22.000000000 +0100
@@ -31,6 +31,16 @@
;;; Code:
+(defun bongo-face-foreground (face &optional frame inherit)
+ "Call `face-foreground' with FACE and FRAME.
+INHERIT is ignored, since it is not supported by Emacs 21."
+ (face-foreground face frame))
+
+(defun bongo-face-background (face &optional frame inherit)
+ "Call `face-background' with FACE and FRAME.
+INHERIT is ignored, since it is not supported by Emacs 21."
+ (face-background face frame))
+
;;; The following macros were copied from `byte-run.el'.
(defmacro bongo-define-obsolete-function-alias
--
Daniel Brockman <address@hidden>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [bongo-patches] Add Emacs 21 compatibility wrappers `bongo-face-foreground' and `bongo-face-background',
Daniel Brockman <=