From 940bb6e984e80a933af80984556bebb31d2cdfd3 Mon Sep 17 00:00:00 2001 From: Dmitry Gutov Date: Sat, 5 Dec 2020 02:52:39 +0200 Subject: [PATCH] Fontify the group and the line number * lisp/progmodes/xref.el (xref--show-defs-minibuffer): Fontify the group and the line number. --- lisp/progmodes/xref.el | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index e304a7beae2..a78fed282cf 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -951,8 +951,15 @@ local keymap that binds `RET' to `xref-quit-and-goto-xref'." (cl-loop for (xref . more2) on xrefs do (with-slots (summary location) xref (let* ((line (xref-location-line location)) - (line-fmt (if line (format "%s:" line) "")) - (group-fmt (substring group group-prefix-length)) + (line-fmt + (if line + (format #("%d:" 0 2 (face xref-line-number)) + line) + "")) + (group-fmt + (propertize + (substring group group-prefix-length) + 'face 'xref-file-header)) (candidate (if show-summary (format "%s:%s%s" group-fmt line-fmt summary) -- 2.39.5