[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#20487: 25.0.50; Format and behavior of *xref* buffer is non-standard

From: Dmitry Gutov
Subject: bug#20487: 25.0.50; Format and behavior of *xref* buffer is non-standard
Date: Sun, 3 May 2015 20:33:17 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.0

On 05/03/2015 07:39 PM, Vitalie Spinu wrote:

Not for me. Now I am using xref for what I would normally use grep
before - locate stuff around and familiarize myself with the code. So I
would like to keep it open.

It has different uses. I'd probably also prefer if xref-find-apropos and xref-find-references output buffers behaved like you're asking, though.

I never have problems with that. Emacs pops buffers in a variety of ways
but rarely hides them. I think people are used to manage their own
buffers as they see fit. I don't think xref should "help" them with

Helmut, thoughts?

I think if a new behavior is contentious the default should be
consistent with how other similar modes behave.

Considering we can translate Grep output into data xref expects, we could the latter the common UI. So, sooner or later, discussing better defaults might be worthwhile.

Are you questioning efficiency of *grep* displays?

Yes, obviously. Not to mention a lot of GUI applications, have you tried Ack or Ag? They both use the grouped output by default.

Repeated files have an advantage that you can immediately see which
symbol is in what file.

I don't have any problems moving my eyes by a line or two to read it.

No. My splits are horizontal.

That's odd. Assuming your files are 80 columns wide, and your windows are tuned to that width, if the file name is printed on every line, it would push the matched lines to the right, often leading to wrapping or truncation.

In certain environments (like Java, where file paths are long), this can be a bigger problem than in others.

Well. Xref already has broken a bunch of emacs UI standards. I think
this one is already one too many.

This one I'm feeling strongly about.

It's not like the handling of Grep output in Emacs was the result of some big design. I bet that it simply was the easiest (while still useful) one to implement in the command-line tool, and then when Emacs integration was done, it was simpler to add highlighting and clickability to it, instead of parsing and reformatting.

You can go against Emacs conventions but you cannot go against unix
world. You cannot change how grep outputs stuff in terminal. People are
used to standard displays and new mode better be considerate of that.

Well, like I said, the output can be customizable. I'm sure some people will appreciate if you implement the flat output.

What's the problem more concretely? You can still display hierarchical
information like this:

Yes, that doesn't look too bad. I somehow thought you'd want the method name to be mentioned on each line, too, but there's no real need for that. Good to know.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]