From: Dmitry Gutov <dgutov@yandex.ru>
To: Juri Linkov <juri@linkov.net>, 61340@debbugs.gnu.org
Subject: bug#61340: 29.0.60; Extra space in xref buffer
Date: Wed, 8 Feb 2023 02:58:02 +0200 [thread overview]
Message-ID: <6a7e3db4-bc2b-2742-bc6c-ad9da8203b85@yandex.ru> (raw)
In-Reply-To: <868rh9zzws.fsf@mail.linkov.net>
Hi!
On 07/02/2023 09:40, Juri Linkov wrote:
> This is a small problem and I didn't notice it until now when
> there was an important distinction whether there is a space
> character at the beginning of the line, and it was misleading
> to see that xref wrongly says there is a leading space.
> This is because currently xref output differs from grep and occur
> where there is no space between colon and the text from file.
> Here is the fix:
>
> ```
> diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el
> index f01b8a1af18..6160f217afb 100644
> --- a/lisp/progmodes/xref.el
> +++ b/lisp/progmodes/xref.el
> @@ -1108,7 +1108,7 @@ xref--insert-xrefs
> maximize (xref-location-line
> (xref-item-location xref)))
> for line-format = (and max-line
> - (format "%%%dd: " (1+ (floor (log max-line 10)))))
> + (format "%%%dd:" (1+ (floor (log max-line 10)))))
> with item-text-props = (list 'mouse-face 'highlight
> 'keymap xref--button-map
> 'help-echo
> ```
This was originally an effort to give the outputted text some "breathing
room", and I think it looks a little better.
But if it can cause problems sometimes, I don't mind the proposed
change. After all, both Grep and Occur don't have this space, and
consistency is good.
next prev parent reply other threads:[~2023-02-08 0:58 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-07 7:40 bug#61340: 29.0.60; Extra space in xref buffer Juri Linkov
2023-02-08 0:58 ` Dmitry Gutov [this message]
2023-02-08 7:35 ` Juri Linkov
2023-02-08 15:14 ` Dmitry Gutov
2023-02-08 18:51 ` Juri Linkov
2023-02-08 22:37 ` Dmitry Gutov
2023-02-09 17:51 ` Juri Linkov
2023-02-09 19:58 ` Dmitry Gutov
2023-02-18 22:04 ` Dmitry Gutov
2023-02-19 6:20 ` Eli Zaretskii
2023-02-19 12:27 ` Dmitry Gutov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6a7e3db4-bc2b-2742-bc6c-ad9da8203b85@yandex.ru \
--to=dgutov@yandex.ru \
--cc=61340@debbugs.gnu.org \
--cc=juri@linkov.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.