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

Re: [Prcs-list] [Prcs-cvs-list] Diff/Comparison of file formats others than ASCII/source code?

From: Donovan Baarda <abo_at_minkirri.apana.org.au>
Date: 2002-08-09 05:08:37 CEST

On Thu, Aug 08, 2002 at 09:31:51AM +0200, Alessandro Bottoni wrote:
> I'm still writing my review regarding a few SCMS and from time to
> time a new question arise...
>
> This time the questions regard the file diff/comparison window that most SCMS
> offer to the user as a support for the manual fixing of the collisions in the
> source code base at the moment of a merge or a commit operation.
>
> 1) what if I want to diff/compare a RTF or a Word file?
>
> I mean: suppose you are developing a large documentation set for your company
> and you are using AbiWord or MS Word as a WYSIWYG editor (in RTF or DOC mode,
> respectivley).
>
> Can you bind AbiWord or Word to the SCMS (via CORBA/DCOP or COM/Automation,
> respectively) in order to present to the user the file comparison window in a
> "RTF/DOC aware" WYSIWYG mode?

Not with PRCS. For RTF yes... to some degree because RTF is text. Collisions
are marked in text files and must be manually resolved using an editor of
your choice.

For Word documents... man, what kind of crazy person bothers to bind word to
anything. You would have to re-bind it every time MS changed word, and you
would be a MSerf for the rest of your existance because reverse engineering
word formats is an excercise in futility. Even simple document templates
with VB scripting in them end up being abandoned when the next iteration of
MSWord consumes the office.

I think being able to bind to OpenOffice would be nice and possible, given
that it uses XML for all its file-format.

In any case, what is required to support this is a file-format specific
diff3 program.

> 2) what if I want to diff/compare a HTML or XML file at the representation
> level, not at the code level?
>
> I mean: suppose you are developing a large web site in HTML+CSS+Javascript
> and you are using Mozilla Composer as a WYSIWYG editor.
>
> Can you bind the Mozilla Gecko rendering engine to the SCMS in order to
> present to the user the file comparison window in a "HTML aware" WYSIWYG mode?
>
> I both cases, I'm sure that most SCMS will be able to manage the RTF, DOC,
> XML and HTML files at the ASCII line or character level. Unfortunately, I'm
> also almost sure that the rendering of the file in the comparison window
> would be only at the "source code" (ASCII) level, not at the human-readable,
> WYSIWYG level. Most likely, the same can be said of every file format other
> than ASCII source code.
>
> Is there any way to create such a "HTML aware "or "RTF aware" file comparison
> mode?

all you need is a HTML/RTF/XML aware diff3.

> Is there any way to adapt the SCMS to file formats others than ASCII C/C++
> source code (for example by using an external editor via CORBA, DCOP or
> COM/Automation)?

Any merge/diff3 operation must be file-format aware to get it right. Text is
a nice common denominator that the existing unix diff3 can handle. Something
like a HTML/XML/RTF aware diff3 could be relatively easily implemented as a
postprocessing stage to merges produced by the standard diff3 because they
use text as their underlying format. For a fee I could write something like
this in a week or so (my rates are in cheap Australian $$$, and I'm looking
for work :-).

MSWord... forgetaboutit. Save all your MSWord documents as RTF, or better
still, change to OpenOffice.

-- 
----------------------------------------------------------------------
ABO: finger abo@minkirri.apana.org.au for more info, including pgp key
----------------------------------------------------------------------
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Aug 9 05:21:07 2002

This is an archived mail posted to the Subversion Dev mailing list.

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