Skip to content

Improve compare defaults #3776

Closed

Description

@iloveeclipse

There are few default compare in Eclipse which I always change in every workspace since years.
#3775 reminded me about them.

I believe the defaults can be improved.

  1. Show structural changes in the Outline (feature introduced via https://bugs.eclipse.org/bugs/show_bug.cgi?id=45247).
    By default is is off, which wastes almost 1/3 of the compare editor. That is exact the reason why it makes sense to enable the feature, so the space is not wasted.

Default:

Image

Proposed:

Image
  1. Connect ranges with single line. This is very old, it seem that the option was introduced at 2.1 Eclipse via https://bugs.eclipse.org/bugs/show_bug.cgi?id=31357 and just no one cared to enable it by default. Single line is harder to see, so the "line ranges" (no idea how that is officially named) is visually more appealing and helps better identify flow of the changes.

Default:

Image

Proposed:

Image
  1. Change default diff panes order to follow "usual" diff order - left is base/original, right is local/modified.
    Default in Eclipse is the opposite, I believe from the CVS times where there were no new/old but local/server, and someone arbitrary decided that local should be left. That was probably OK at that time, but now where everyone uses git it is awkward to see diff panes shown in "wrong" order by default in Eclipse, where rest of the world does the opposite. See for example https://www.jetbrains.com/help/idea/comparing-file-versions.html.
    The possibility to change the order was introduced via https://bugs.eclipse.org/bugs/show_bug.cgi?id=213780). The request to change the default is https://bugs.eclipse.org/bugs/show_bug.cgi?id=501752, but there were some test fixes needed, no time and no one continued the work. I believe now we should finally do that change.

Default:

Image

Proposed:

Image

All together

Default:

Image

Proposed:

Image

Activity

  1. BeckerWdf commented on Mar 13, 2026

    @BeckerWdf
    Member

    All of your proposals make a lot of sense for me. Let's go for it.

  2. HeikoKlare commented on Mar 13, 2026

    @HeikoKlare
    Contributor

    I also like all of the proposals and would be in favor of changing those defaults. I wasn't even aware of some of the options or their effects.

  3. iloveeclipse commented on Mar 13, 2026

    @iloveeclipse
    MemberAuthor

    I wasn't even aware of some of the options or their effects.

    :-) That is also my impression while pair coding with other developers.

  4. merks commented on Mar 13, 2026

    @merks
    Contributor

    Of course changing defaults can be controversial and surprising, but I too did not know about all these settings. (And I always have Oomph so I can change any default I don't like once and for all everywhere.)

  5. vogella commented on Mar 13, 2026

    @vogella
    Contributor

    +1 for the change

  6. 26 remaining items

  7. merks commented on May 5, 2026

    @merks
    Contributor

    I think that only the mirroring is catching people off guard. The new style is quite nice and with the improvements we did for supporting the inline-merge buttons in the new style, I don't think that's so controversial. The outline just seems like a good thing. Seeing the opposite of what one expects to see is really disconcerting (for me).

  8. iloveeclipse commented on May 5, 2026

    @iloveeclipse
    MemberAuthor

    Here is the poll: #3967

  9. stephan-herrmann commented on May 5, 2026

    @stephan-herrmann
    Contributor

    I think that only the mirroring is catching people off guard.

    Back in 2016 there seemed to be some agreement that swapping is good IFF the user is clearly notified about this change, see bug 501752 comment 10, comment 12, comment 15. Has this been considered in the recent effort?

    Have different uses within the SDK be checked for effects? I'm chiefly thinking of Team Compare, Refactoring Preview and JUnit Test Result (Expected | Actual). In particular if the latter is flipped to (Actual | Expected) that would seem bad to me.

  10. stephan-herrmann commented on May 5, 2026

    @stephan-herrmann
    Contributor

    I also have problems identifying what is what. But I think that might be more due to the poor labels / display of the label. A clearly identifiable label might help.

    Would eclipse-egit/egit#178 help?

  11. HeikoKlare commented on May 6, 2026

    @HeikoKlare
    Contributor

    Have different uses within the SDK be checked for effects? I'm chiefly thinking of Team Compare, Refactoring Preview and JUnit Test Result (Expected | Actual). In particular if the latter is flipped to (Actual | Expected) that would seem bad to me.

    In my understanding, it was the primary concern that inverting the default may be fine for some use cases but not for others and an investigation of different uses cases did not happen so far. Doing an analysis of different use cases before applying such a change is what I also proposed in #3776 (comment).

  12. iloveeclipse commented on May 6, 2026

    @iloveeclipse
    MemberAuthor

    Have different uses within the SDK be checked for effects?

    I hope people who use milestones and nightly builds do that and report the inconsistencies if they encounter some.

    I'm chiefly thinking of Team Compare,

    This is the main one, so it should work

    Refactoring Preview

    This was actually the trigger for the whole story here, and yes, it is fixed, see #3777

    and JUnit Test Result (Expected | Actual). In particular if the latter is flipped to (Actual | Expected) that would seem bad to me.

    Now you mentioned that one, I've pushed the fix, very similar to #3777 it was always inconsistent for exact same reason :-)

  13. iloveeclipse commented on May 18, 2026

    @iloveeclipse
    MemberAuthor

    I am always advocating polls (e.g. #2199 ) for such cases so we can really what majority thinks.

    The results (as of today) from #3967 are:

    Image

    I've pushed PR for N&N changes : eclipse-platform/www.eclipse.org-eclipse#549

    With that, I consider that we can keep proposed changes in 4.40 and close this ticket.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions