aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
authorMatthias Dahl2014-04-12 17:22:55 +0300
committerEli Zaretskii2014-04-12 17:22:55 +0300
commit5f91455c9d87502e96d4a6bc04da831fce4616fc (patch)
tree6fbb855e028a6f3a37858043d5b380e30f9e0c38 /lisp
parent180c8ce0c6a702bc21403e1f5a0b2781bb5f787c (diff)
downloademacs-5f91455c9d87502e96d4a6bc04da831fce4616fc.tar.gz
emacs-5f91455c9d87502e96d4a6bc04da831fce4616fc.zip
Deprecate optional argument of make-face.
lisp/faces.el (make-face): Deprecate optional argument as it is no longer needed/used since the conditional X resources handling has been pushed down to make-face-x-resource-internal itself. (make-empty-face): Don't pass optional argument to make-face.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog7
-rw-r--r--lisp/faces.el18
2 files changed, 19 insertions, 6 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 78865ed8c48..5fd81d00e2b 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,10 @@
12014-04-12 Matthias Dahl <matthias.dahl@binary-island.eu>
2
3 * faces.el (make-face): Deprecate optional argument as it is no
4 longer needed/used since the conditional X resources handling
5 has been pushed down to make-face-x-resource-internal itself.
6 (make-empty-face): Don't pass optional argument to make-face.
7
12014-04-12 Eli Zaretskii <eliz@gnu.org> 82014-04-12 Eli Zaretskii <eliz@gnu.org>
2 9
3 * international/characters.el <standard-case-table>: Add entries 10 * international/characters.el <standard-case-table>: Add entries
diff --git a/lisp/faces.el b/lisp/faces.el
index e4d8a35ac68..88b87486f7c 100644
--- a/lisp/faces.el
+++ b/lisp/faces.el
@@ -133,9 +133,11 @@ REGISTRY, ALTERNATIVE1, ALTERNATIVE2, and etc."
133 "Define a new face with name FACE, a symbol. 133 "Define a new face with name FACE, a symbol.
134Do not call this directly from Lisp code; use `defface' instead. 134Do not call this directly from Lisp code; use `defface' instead.
135 135
136If NO-INIT-FROM-RESOURCES is non-nil, don't initialize face 136If FACE is already known as a face, leave it unmodified. Return FACE.
137attributes from X resources. If FACE is already known as a face, 137
138leave it unmodified. Return FACE." 138NO-INIT-FROM-RESOURCES has been deprecated and is no longer used
139and will go away. Handling of conditional X resources application
140has been pushed down to make-x-resource-internal itself."
139 (interactive (list (read-from-minibuffer 141 (interactive (list (read-from-minibuffer
140 "Make face: " nil nil t 'face-name-history))) 142 "Make face: " nil nil t 'face-name-history)))
141 (unless (facep face) 143 (unless (facep face)
@@ -146,16 +148,20 @@ leave it unmodified. Return FACE."
146 (when (fboundp 'facemenu-add-new-face) 148 (when (fboundp 'facemenu-add-new-face)
147 (facemenu-add-new-face face)) 149 (facemenu-add-new-face face))
148 ;; Define frame-local faces for all frames from X resources. 150 ;; Define frame-local faces for all frames from X resources.
149 (unless no-init-from-resources 151 (make-face-x-resource-internal face))
150 (make-face-x-resource-internal face)))
151 face) 152 face)
152 153
154;; Handling of whether to apply X resources or not, has been pushed down
155;; to make-face-x-resource-internal itself, thus the optional arg is no
156;; longer evaluated at all and going away.
157(set-advertised-calling-convention 'make-face '(face) "24.4")
158
153(defun make-empty-face (face) 159(defun make-empty-face (face)
154 "Define a new, empty face with name FACE. 160 "Define a new, empty face with name FACE.
155Do not call this directly from Lisp code; use `defface' instead." 161Do not call this directly from Lisp code; use `defface' instead."
156 (interactive (list (read-from-minibuffer 162 (interactive (list (read-from-minibuffer
157 "Make empty face: " nil nil t 'face-name-history))) 163 "Make empty face: " nil nil t 'face-name-history)))
158 (make-face face 'no-init-from-resources)) 164 (make-face face))
159 165
160(defun copy-face (old-face new-face &optional frame new-frame) 166(defun copy-face (old-face new-face &optional frame new-frame)
161 "Define a face named NEW-FACE, which is a copy of OLD-FACE. 167 "Define a face named NEW-FACE, which is a copy of OLD-FACE.