<?xml version="1.0" encoding="utf-8"?>
<section id="GuideImageSearchFindingDuplicates">
  <title id="titleGuideImageSearchFindingDuplicates">Finding Duplicates</title>
  <para>Geeqie provides a utility to find images that have similar attributes or content.</para>
  <para>
    To display a new Find Duplicates Window select
    <menuchoice>
      <guimenu>File</guimenu>
      <guimenuitem>Find duplicates</guimenuitem>
    </menuchoice>
    .
  </para>
  <section id="Addingfilestobecompared">
    <title>Adding files to be compared</title>
    <para>Add files to be compared using drag and drop. Drop files or folders onto the Find Duplicates window to add them to the list of files to compare. When one or more folders are dropped onto the window a menu will appear allowing you to choose the desired action:</para>
    <variablelist>
      <varlistentry>
        <term>
          <guilabel>Add contents</guilabel>
        </term>
        <listitem>The contents of dropped folders will added to the window.</listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Add contents recursive</guilabel>
        </term>
        <listitem>The contents of dropped folders and all sub folders will be added to the window.</listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Skip folders</guilabel>
        </term>
        <listitem>
          Ignore folders contained in the drop list.
          <para />
          When files are added to the window, the comparison is restarted to include the new files.
        </listitem>
      </varlistentry>
    </variablelist>
    <para>
      <note>
        <para>Symbolic links to folders will be followed, but symbolic links to files will be ignored. Only actual files will be tested.</para>
      </note>
    </para>
  </section>
  <section id="Comparisonmethods">
    <title>Comparison methods</title>
    <para>
      The attribute to use for two images to match can be selected with the
      <emphasis role="bold">Compare by:</emphasis>
      drop down menu. Each method is explained below:
    </para>
    <variablelist>
      <varlistentry>
        <term>
          <guilabel>Name</guilabel>
        </term>
        <listitem>
          <para>The file name.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Name case-insensitive</guilabel>
        </term>
        <listitem>
          <para>The file name but ignoring case.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Size</guilabel>
        </term>
        <listitem>
          <para>The file size.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Date</guilabel>
        </term>
        <listitem>
          <para>The file date.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Dimensions</guilabel>
        </term>
        <listitem>
          <para>The image dimensions.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Checksum</guilabel>
        </term>
        <listitem>
          <para>The MD5 file checksum.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Path</guilabel>
        </term>
        <listitem>
          <para>The complete path to file.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Similarity (high)</guilabel>
        </term>
        <listitem>
          <para>Very similar image content. Preset to 95%.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Similarity</guilabel>
        </term>
        <listitem>
          <para>Similar image content. Preset to 90%.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Similarity (low)</guilabel>
        </term>
        <listitem>
          <para>Slightly similar image content. Preset to 85%.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Similarity (custom)</guilabel>
        </term>
        <listitem>
          <para>
            The percentage value to used to consider two images a match is configured in the spin box at the bottom of the window. Setting a value to less than 85 is not likely to be useful.
          </para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Name ≠ Content</guilabel>
        </term>
        <listitem>
          <para>
            Show images with the same name but different content.
            <note>
              <para>Because pairs of files are being compared, when there are multiple hits care should be taken when analyzing the results.</para>
            </note>
          </para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Name case-insensitive ≠ Content</guilabel>
        </term>
        <listitem>
          <para>
            Show images with the same name, ignoring case, but different content.
            <note>
              <para>Because pairs of files are being compared, when there are multiple hits care should be taken when analyzing the results.</para>
            </note>
          </para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>
          <guilabel>Show all</guilabel>
        </term>
        <listitem>
          <para>
            Do not compare. Show all images.
          </para>
        </listitem>
      </varlistentry>
    </variablelist>
  </section>
  <section id="Resultslist">
    <title>Results list</title>
    <para>Files that match with the selected comparison method will appear in the list. Matching files are grouped in alternating color.</para>
    <para>The order of the result list can be changed by clicking on the column header. This will re-order the images within each set. When comparing by image content similarity, the matching sets will be sorted by order of rank starting with the files that are most similar.</para>
    <para>
      A
      <emphasis role="strong">context menu</emphasis>
      is available for the result list by right clicking the mouse or pressing the Menu key when a row has the focus.
    </para>
    <para>
      Groups in the results list may be selected by using the keyboard. Refer to the <emphasis>Find Duplicates Window</emphasis> section of
       <link linkend="DuplicatesKeyboardShortcuts" >Keyboard Shortcuts</link>
      .
    </para>
    <para>
      The
      <emphasis role="strong">selection</emphasis>
      can be changed using the keyboard and mouse the same as in a
      <link linkend="GuideMainWindowFilePane">file pane</link>
      of the main window.
    </para>
    <para>The image Dimensions column of the result list will only contain dimension information when comparing by dimensions, or when the data is easily available from memory or has been read from the cache.</para>
  </section>
  <section id="Statusbar">
    <title>Status bar</title>
    <para>Along the bottom of the Find Duplicates window is an area that displays the count of files contained in the window, and the number of files in the result list.</para>
    <para>The status bar will also display the status of an active compare operation using the progress bar. A compare operation involves 2 or 3 stages, depending on the type of comparison. These are the stages in order:</para>
    <orderedlist>
      <listitem>
        <para>If necessary, extra data is read into memory for the comparison stage and the progress bar will indicate this stage with text such as “Reading dimensions...”, “Reading checksums...”, or “Reading similarity data...”.</para>
      </listitem>
      <listitem>The images are compared using the selected method, the progress bar will indicate this stage with the text “Comparing...”.</listitem>
      <listitem>
        <para>The results are sorted for display, the progress bar will indicate this stage with the text “Sorting...”.</para>
        <para>Stage 1 is only used for the Dimensions, Checksum, and Similarity compare methods.</para>
        <para>If the time to complete a stage will be significant, an estimated time to completion will also be displayed in the progress bar. The estimated time only refers to the current stage, other stages are not included in the estimate. The time estimate is displayed using the format MINUTES:SECONDS.</para>
      </listitem>
    </orderedlist>
  </section>
  <section id="Thumbnails">
    <title>Thumbnails</title>
    <para>Thumbnails can be displayed beside each image in the result list by enabling the Thumbnails check box.</para>
  </section>
  <section id="Orientation">
    <title>Ignore Orientation</title>
    <para>When selected and a similarity compare is being used, the images are checked against 4 rotations: 0°, 90°, 180°, 270°, plus flip and mirror.</para>
  </section>
  <section id="Sort">
    <title>Sort</title>
    <para>
      The normal sort order is for groups (in the case of Similarity checks) with the highest number of near-100% matches to be at the top of the list.
      <para />
      If this box is checked, groups with the lowest number of matches are placed at the top of the list.
    </para>
  </section>
  <section id="Comparetwofilesets">
    <title>Compare two file sets</title>
    <para>Sometimes it is useful to compare one group of files to another, different group of files. Enable this check box to compare two groups of files. When enabled, a second list will appear and files can be added to this list using the same methods for the main list.</para>
    <para>When comparing two file sets the results list will display matches between the two lists. For each match group, the first file is always from the main group, and the remaining files are always from the second group.</para>
  </section>
  <section id="DragandDrop">
    <title>Drag and Drop</title>
    <para>Drag and drop can be initiated with the primary or middle mouse buttons. Dragging a file that is selected will include all selected files in the drag. Dragging a file that is not selected will first change the selection to the dragged file, and clear the previous selection.</para>
  </section>
  <section id="ImageDataWindow">
    <title>Image Data Window</title>
    <para>
      <code>Ctrl+Shift+Right Mouse click</code>
      : Use this to display a dialog containing the data stored for the clicked image file. This is usually only useful for debugging purposes.
    </para>
    <para />
  </section>
</section>
