Re: Refresh vs revert



On 1 November 2013 23:16, Ney André de Mello Zunino <neyzunino gmail com> wrote:
Hello.

I've just subscribed to the Meld Mailing List. Let me start by saying I feel
lucky for having bumped into Meld. It's not often that you try a software
tool which not only does its job well, but also looks and feels polished.
It's certainly a keeper. My sincere congratulations to the developers.

Now for the topic of the post: my first usage scenario for Meld has been to
compare a static, hand-made file with a respective generated version. As the
generator is modified, so is its output. Back in Meld, I thought I could
simply press F5 or CTRL-R to have it re-read the documents and update the
comparison. However, I found out that I must actually use the "Revert"
command under the "File" menu to achieve that. Why is there such a
distinction between refreshing and reverting? Isn't it reasonable to expect
that, if any of the files under comparison have been modified, that
"refreshing" should make those changes visible?

Thanks for bringing this up! This is a use of reloading that really
wasn't considered when some changes were made, and should have been.

While it's okay (ish) for VC and folder comparisons, in file
comparisons, the refresh command is actually pretty horrible. It just
re-runs the comparison itself, which is really only necessary because
the incremental updating comparison method that we use will sometimes
result in a different comparison than what you'd get if you just
re-ran the comparison.

Having said that, "Refresh" usually indicates a non-destructive
operation, and reloading from disk is most certainly (potentially)
destructive, so I don't agree that refresh should do this. However...
(more below)

P.S.: Before posting this, I decided to check out the help contents. I found
there is a shortcut for reloading the comparison (CTRL-SHIFT-R), but it
didn't work.

The help on the website is unfortunately a bit stale; I'll try to get
around to updating it some time.

Given that there are good reasons for keeping the distinction
between refreshing and reloading, it could just be a matter of re-enabling
the shortcut and having it displayed alongside the corresponding "Revert"
menu option.

The Reload command was renamed to Revert a little while ago to better
indicate what its purpose was; it wasn't immediately obvious that
Reload would actually discard changes, and other Gnome tools use
Revert for a similar action.

Unfortunately, when Reload was renamed, I guess I didn't think about
the case of just wanting to compare against an externally edited
version that was changing. The thing is that the correct thing to do
here is to have a notification that the file on disk has changed and
prompt for a reload (or even auto-reload), which I think would solve
your problem nicely?

There's an open bug for this somewhere, and it's not particularly
difficult, but it's a bit of work to get right.

cheers,
Kai


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