|
From: | Dmitry Gutov |
Subject: | bug#47012: xref copies keymap properties to minibuffer |
Date: | Wed, 31 Mar 2021 18:47:30 +0300 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 |
On 30.03.2021 22:16, Juri Linkov wrote:
Using the same solution of 'diff-header' and 'diff-file-header' for 'xref-file-header' improves the readability significantly: #+begin_src diff diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index ea52befec5..f2aa8bfba4 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -513,7 +513,7 @@ xref-pop-to-location (defconst xref-buffer-name "*xref*" "The name of the buffer to show xrefs.")-(defface xref-file-header '((t :inherit compilation-info))+(defface xref-file-header '((t :background "grey90" :extend t)) "Face used to highlight file header in the xref buffer." :version "27.1") #+end_src
Hi Juri,I'm not sure I like the result. Simply applying your change to the face results in a color-less buffer with grey spots for both file headers and match highlights (at least, with my current theme).
It's less of a problem with diff-mode because its basic background is grey already.
I've also considered something like:(defface xref-file-header '((t :background "grey90" :extend t :inherit compilation-info))
"Face used to highlight file header in the xref buffer." :version "27.1")...but it makes the file names harder to read because of the reduced contrast.
Then I've tried to see what others do, for instance https://github.com/Wilfred/deadgrep, which I'd heard people praise usability of.
The only distinction it adds to file names is "bold :t". And diff-mode also does that, actually.
So... how do you like this simple change? (defface xref-file-header '((t :bold t :inherit compilation-info)) "Face used to highlight file header in the xref buffer." :version "27.1")
[Prev in Thread] | Current Thread | [Next in Thread] |