blob: 4bef3c707c1af1437b9bdb288d768dec0d239ba7 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><html lang="en">
<HEAD>
<meta name="copyright" content="Copyright (c) IBM Corporation and others 2000, 2013. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
<LINK REL="STYLESHEET" HREF="../book.css" CHARSET="ISO-8859-1" TYPE="text/css">
<title>Working with the comparison</title>
</HEAD>
<BODY BGCOLOR="#ffffff">
<h1>Working with the comparison</h1>
<p CLASS="Head">Comparing file1.txt and file2.txt resulted in the following compare
editor. This section demonstrates how to use the compare editor to resolve the
differences between the two files.</p>
<p>
<img src="../images/Image80_compare_editor.png" alt="Compare editor" border="0" ></p>
<p>There are two parts to the compare editor's local toolbar. Move between changes
and differences using the right group of local toolbar buttons.</p>
<blockquote>
<p>
<img src="../images/next_diff_nav.svg" alt="Compare editor next difference button" border="0">
<img src="../images/prev_diff_nav.svg" alt="Compare editor next difference button" border="0">
<img src="../images/next_change_nav.svg" alt="Compare editor next difference button" border="0">
<img src="../images/prev_change_nav.svg" alt="Compare editor next change button" border="0">
</p>
</blockquote>
<ol>
<li>
<p CLASS="Para">Click the <b>Select Next Difference</b> button <img
src="../images/next_diff_nav.svg" alt="Compare editor next difference button"
border="0">. Observe how it selects the next difference.
</p></li>
<li>
<p CLASS="Para">
Click the <b>Select Next Change</b> button <img
src="../images/next_change_nav.svg"
alt="Compare editor next difference button" border="0">.
Observe how it selects the first change in this difference.
</p></li>
<li>
<p CLASS="Para">Click the <b>Select Next Change</b> button again <img
src="../images/next_change_nav.svg"
alt="Compare editor next change button" border="0">. Observe
how it selects the next difference.
</p>
</li>
<li>
<p CLASS="Para">Click the <b>Select Previous Change</b> button <img
src="../images/prev_change_nav.svg"
alt="Compare editor next change button" border="0">. Observe
how it selects the last change in a previous difference.
</p></li>
<li>
<p CLASS="Para">
Click the <b>Select Previous Difference</b> button <img
src="../images/prev_diff_nav.svg"
alt="Compare editor next difference button" border="0">.
Observe how it selects the previous difference.
</p></li>
</ol>
<p>To merge changes from the left file to the right file and vice versa use the
left group of local toolbar buttons.</p>
<blockquote>
<p>
<img src="../images/copy_r_co.svg" alt="Image of the 'Copy All from Left to Right' button">
<img src="../images/copy_l_co.svg" alt="Image of the 'Copy All Non-Conflicting Changes from Right to Left' button">
<img src="../images/copycont_r_co.svg" alt="Image of the 'Copy Current Change from Left to Right' button">
<img src="../images/copycont_l_co.svg" alt="Image of the 'Copy Current Change from Right to Left' button">
</p>
</blockquote>
<p>There are four types of merges that can
be performed:</p>
<ul>
<li>Copy whole document from left to right.</li>
<li>Copy whole document from right to left.</li>
<li>Copy current change from left to right.</li>
<li>Copy current change from right to left.</li>
</ul>
<p> Typically the copy whole document actions are used when the entire file on
either the left or right can just be replaced by the contents of the other file.</p>
<p> The Copy current change buttons allow a single change to be merged.</p>
<ol>
<li>
<p CLASS="Para">Ensure that the second difference is selected (as shown
below):</p>
<p CLASS="Para">
<img src="../images/Image80_compare_change2.png" alt="Compare editor" border="0" ></p>
</li>
<li>
<p CLASS="Para">Click&nbsp;<strong>Copy Current Change from Right to Left
</strong><img src="../images/copycont_l_co.svg" alt="Compare editor right to left button" border="0">.
Observe that the selected text from the right file is copied to the left
file.</p>
<p CLASS="Para"><img src="../images/Image80_compare_after.png" alt="Compare editor" border="0" ></p>
</li>
<li>
<p CLASS="Para">Close the compare editor and choose <b>Yes</b> to save the
changes. Alternatively, save the changes by choosing <b>File &gt; Save</b>
(Ctrl+S).</p>
</li>
</ol>
</BODY>
</HTML>