aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Kangas2023-08-09 03:30:56 +0200
committerStefan Kangas2023-08-09 03:30:56 +0200
commit08c5cba2e4637cfe79a0ebf1bf2a07a304c277b6 (patch)
tree87087de6f7e32afdf0169c7e8d1af9b66eb86a59
parent6f2e48bc52d85a3914d4b9e919dedf609289bdf5 (diff)
downloademacs-08c5cba2e4637cfe79a0ebf1bf2a07a304c277b6.tar.gz
emacs-08c5cba2e4637cfe79a0ebf1bf2a07a304c277b6.zip
Add calling convention to face-attr-construct
* lisp/faces.el (face-attr-construct): Add advertised-calling-convention declaration.
-rw-r--r--lisp/cus-edit.el2
-rw-r--r--lisp/faces.el7
2 files changed, 3 insertions, 6 deletions
diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el
index f5143bdb53f..9b73a72b238 100644
--- a/lisp/cus-edit.el
+++ b/lisp/cus-edit.el
@@ -3751,7 +3751,7 @@ WIDGET should be a `custom-face' widget."
3751 ;; If the user has changed this face in some other way, 3751 ;; If the user has changed this face in some other way,
3752 ;; edit it as the user has specified it. 3752 ;; edit it as the user has specified it.
3753 (if (not (face-spec-match-p face spec (selected-frame))) 3753 (if (not (face-spec-match-p face spec (selected-frame)))
3754 (setq spec `((t ,(face-attr-construct face (selected-frame)))))) 3754 (setq spec `((t ,(face-attr-construct face)))))
3755 spec)) 3755 spec))
3756 3756
3757(defun custom-face-get-current-spec (face) 3757(defun custom-face-get-current-spec (face)
diff --git a/lisp/faces.el b/lisp/faces.el
index 8017f5fa65e..1a446aacacd 100644
--- a/lisp/faces.el
+++ b/lisp/faces.el
@@ -1540,15 +1540,12 @@ argument, prompt for a regular expression using `read-regexp'."
1540;;; Face specifications (defface). 1540;;; Face specifications (defface).
1541;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 1541;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
1542 1542
1543;; Parameter FRAME Is kept for call compatibility to with previous
1544;; face implementation.
1545
1546(defun face-attr-construct (face &optional _frame) 1543(defun face-attr-construct (face &optional _frame)
1547 "Return a `defface'-style attribute list for FACE. 1544 "Return a `defface'-style attribute list for FACE.
1548Value is a property list of pairs ATTRIBUTE VALUE for all specified 1545Value is a property list of pairs ATTRIBUTE VALUE for all specified
1549face attributes of FACE where ATTRIBUTE is the attribute name and 1546face attributes of FACE where ATTRIBUTE is the attribute name and
1550VALUE is the specified value of that attribute. 1547VALUE is the specified value of that attribute."
1551Argument FRAME is ignored and retained for compatibility." 1548 (declare (advertised-calling-convention (face) "30.1"))
1552 (let (result) 1549 (let (result)
1553 (dolist (entry face-attribute-name-alist result) 1550 (dolist (entry face-attribute-name-alist result)
1554 (let* ((attribute (car entry)) 1551 (let* ((attribute (car entry))