=========================
Secret Features of xxdiff
=========================

:Author: Martin Blais <blais@furius.ca>
:Date: 2004-01-21
:Abstract:

   A short expos of some of the least-known or non-obvious features of xxdiff.

.. contents:: Table of Contents

Introduction
------------

xxdiff has grown a number of little cool features that are not necessarily
obvious from its user interface.  This documents aims at presenting some of them
together outside of the general documentation.  (All these features are also
documented in the user's manual.)


Checking for Strict Equality
----------------------------

When comparing a large number of files for merge review, we want to minimize the
amount of time we spend on useless changes, and you will most likely enable the
"ignore whitespace" features. Sometimes some automated scripts that will launch
xxdiff will be lauching it on two files which have no non-whitespace
differences.  It is then impossible to "see" if the files are exactly the same
or not (I mean, byte-for-byte the same or not).

.. figure:: equals.png

Sometimes it is important to know that, for example, before committing changes
to a revision control system.  For this purpose, you can check out the label
over the overview area which will contain an equal sign ``(=)`` if there are no
differences at all, not even whitespace differences.  If you can see no visible
differences and this marker is not present, this indicates that the files do
differ, probably just in whitespace.


Number of Remaining Hunks
-------------------------

That little number of the overview area is the number of diff hunks that are
unselected. You can save a merged result when all the hunks are selected, so
this indicates the number of remaining hunks to resolve before you can save.


Selecting Text
--------------

In the context of merge reviewing, it is often useful to make comments on the
code that is visible from xxdiff.  You can use the ``Control`` key and mouse
button 1 to select an arbitrary set of lines in either file, and that text is
put into the clipboard.  You can then cut-n-paste it in a text editor where you
make your comments.

A red line appears to display the selection of text stored in the clipboard.

.. figure:: select.png

How the line is formatted can be configured with the resources to include the
line numbers and some other things.

--------------------------------------------------------------------------------

(FIXME finish documenting the other features here)
