Subject: bug#58092: 29.0.50; [PATCH] Add log-edit-summary-separator face

From: Protesilaos Stavrou <[email-masked]>
Date: Mon, 26 Sep 2022 15:44:50 +0300

Dear maintainers,

The attached patch replaces some hardcoded face properties in log-edit
buffers with a named face.

The named face allows users/themes to customise how this line is styled.

What do you think?

All the best,
Protesilaos (or simply "Prot")

-- 
Protesilaos Stavrou
https://protesilaos.com
>From ea287b3d918c6a2cf6181c5671187143b3774bd5 Mon Sep 17 00:00:00 2001
Message-Id: <[email-masked]>
From: Protesilaos Stavrou <[email-masked]>
Date: Mon, 26 Sep 2022 15:41:18 +0300
Subject: [PATCH] Add log-edit-summary-separator face

* etc/NEWS: Report on it.
* lisp/vc/log-edit.el (log-edit-summary-separator): Add new face.
(log-edit-font-lock-keywords): Replace hardcoded face attributes with
named face.
---
 etc/NEWS            | 5 +++++
 lisp/vc/log-edit.el | 6 +++++-
 2 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/etc/NEWS b/etc/NEWS
index 0a5b7bc29c..ced4ece35d 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -1766,6 +1766,11 @@ Writing shorter summary lines avoids truncation in contexts in which
 Git commands display summary lines.  See the two new user options
 'vc-git-log-edit-summary-target-len' and 'vc-git-log-edit-summary-max-len'.
 
+---
+*** New 'log-edit-summary-separator' face
+Styles the line that separates the log-edit headers from the log-edit
+summary.
+
 ** Message
 
 ---
diff --git a/lisp/vc/log-edit.el b/lisp/vc/log-edit.el
index 5290616302..25b47a75af 100644
--- a/lisp/vc/log-edit.el
+++ b/lisp/vc/log-edit.el
@@ -325,6 +325,10 @@ ;;; Actual code
 (defface log-edit-summary '((t :inherit font-lock-function-name-face))
   "Face for the summary in `log-edit-mode' buffers.")
 
+(defface log-edit-summary-separator '((t :height 0.1 :inverse-video t :extend t))
+  "Face for the summary separator line in `log-edit-mode' buffers."
+  :version "29.1")
+
 (defface log-edit-header '((t :inherit font-lock-keyword-face))
   "Face for the headers in `log-edit-mode' buffers.")
 
@@ -393,7 +397,7 @@ (defvar log-edit-font-lock-keywords
          nil lax))
      ("^\n"
       (progn (goto-char (match-end 0)) (1+ (match-end 0))) nil
-      (0 '(face (:height 0.1 :inverse-video t :extend t)
+      (0 '(face log-edit-summary-separator
            display-line-numbers-disable t rear-nonsticky t))))
     (log-edit--match-first-line (0 'log-edit-summary))))
 
-- 
2.37.3