[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Comparing files in Word

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: Fri, 11 Jul 2008 21:03:21 +0200

Paul wrote:
> Hi, I was amazed to see that if you click on "Diff with previous
> version" of a Word doc, that it opens up the doc in Word and launches
> a comparison between the latest two version.
> This is a wonderful feature, specially when you're using Subversion
> for normal docs (not code).
> There is a glitch tho, the revision considere Old is the latest one
> and the one considered New is in fact the older revision. In other
> words, it's telling me that 3 has replaced 4 and not the other way
> round.
> Am I doing something wrong or is this a problem with the system?

Actually, if I'm not completely mistaken, the diff is correct.
Word just shows the diff 'wrong'. Ok, I admit that isn't a good
explanation :)

If you look at the 'merged' document Word shows you, you will see that
it looks exactly like the 'new' file, but lines which were added in the
new file are marked red as if they were removed, not added.

If you would make Word show the diff in reverse, it would actually show
the document as it was in the old version, not the new one.

You can test this yourself if you like. The file
C:\Program Files\TortoiseSVN\Diff-Scripts\diff-doc.js
it the one which calls the word diff. If you change the lines 44/45 from:

sBaseDoc = objArgs(0);
sNewDoc = objArgs(1);

to

sBaseDoc = objArgs(1);
sNewDoc = objArgs(0);

you will see what I mean if you repeat the diff.

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.net

Received on 2008-07-11 21:03:40 CEST

This is an archived mail posted to the TortoiseSVN Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.