From 3b5f8ab0d06f6c39aaa716b6279c2ceb4bfc5b14 Mon Sep 17 00:00:00 2001 From: Lars Ingebrigtsen Date: Wed, 11 Aug 2021 22:29:38 +0200 Subject: [PATCH] Allow using a single anonymous face in enriced-mode * lisp/format.el (format-annotate-single-property-change): Allow using a single anonymous face (bug#33682). --- lisp/format.el | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lisp/format.el b/lisp/format.el index 1e87d252844..71cf885d417 100644 --- a/lisp/format.el +++ b/lisp/format.el @@ -1013,6 +1013,12 @@ either strings, or lists of the form (PARAMETER VALUE)." prop-alist (car old) nil)) close) old (cdr old))) + ;; If the font is on the format (:background "red"), + ;; then we have a single face. We're assuming a list of + ;; faces, so transform. + (when (and (listp new) + (keywordp (car new))) + (setq new (list new))) (while new (setq open (append (cdr (format-annotate-atomic-property-change -- 2.39.5