<page xmlns="http://projectmallard.org/1.0/"
      type="topic" style="task"
      id="files-sort">

  <info>
    <revision pkgversion="0.0.1" version="0.0.3" date="2015-01-28" status="draft"/>

    <link type="guide" xref="files"/>
    <desc>Arrange files by name, size, type, or when they were changed.</desc>

    <credit type="author">
      <name>Mate Documentation Team</name>
      <years>2015</years>
    </credit>

    <credit type="author">
      <name>Phil Bull</name>
      <email>philbull@gmail.com</email>
    </credit>
    <license>
      <p>Creative Commons Share Alike 3.0</p>
    </license>

    <include href="legal.xml" xmlns="http://www.w3.org/2001/XInclude"/>
  </info>

<title>Sort files and folders</title>

<p>You can sort files in different ways in a folder, for example by sorting them in order of date or file size. See <link xref="#ways"/> below for a list of common ways to sort files.</p>

<p>The way that you can sort files depends on the <em>folder view</em> that you are using.
You can change the current view using the <gui>View</gui> menu.</p>

<p>When you change how items are sorted in a folder, it only affects that folder. The file
manager will remember your sorting choice for that folder, but use the default sort order
for other folders. See <link xref="caja-views"/> for information on how to change the
default sort order.</p>

<section id="icon-view">
 <title>Icon view</title>
 <p>To sort files in a different order, right-click a blank space in the folder and choose an option from the <gui>Arrange Items</gui> menu. Alternatively, use the <guiseq><gui>View</gui><gui>Arrange Items</gui></guiseq> menu.</p>
 <p>As an example, if you select <gui>Sort by Name</gui> from the <gui>Arrange Items</gui> menu, the files will be sorted by their names, in alphabetical order. See <link xref="#ways"/> for other options.</p>
 <p>You can sort in the reverse order by selecting <gui>Reversed Order</gui>  from the <gui>Arrange Items</gui> menu.</p>
 <p>For complete control over the order and position of files in the folder, right-click a blank space in the folder and select <guiseq><gui>Arrange Items</gui><gui>Manually</gui></guiseq>. You can then rearrange the files by dragging them around in the folder. Manual sorting only works in icon view.</p>
 <p>The <gui>Compact Layout</gui> option in the <gui>Arrange Items</gui> menu arranges the files so they take up as little space as possible. This is useful if you want to have lots of files visible at once in a folder.</p>
</section>

<section id="list-view">
 <title>List view</title>
 <p>To sort files in a different order, click one of the column headings in the file manager. For example, click <gui>Type</gui> to sort by file type. Click the column heading again to sort in the reverse order.</p>
 <p>In list view, you can show columns with more attributes and sort on those columns. Click <guiseq><gui>View</gui><gui>Visible Columns</gui></guiseq> and select the columns that you want to be visible. You will then be able to sort by those columns. See <link xref="caja-list"/> for descriptions of available columns.</p>
</section>

<section id="compact-view">
 <title>Compact view</title>
 <p>You can sort files in Compact view in the same way that you can sort them in the Icon view. The only difference is that you can't manually position the files anywhere you want; they are always organized as a list in this view.</p>
</section>

<section id="ways">
 <title>Ways of sorting files</title>
 <terms>
  <item>
   <title>By Name</title>
   <p>Sorts alphabetically by the name of the file.</p>
  </item>
  <item>
   <title>By Size</title>
   <p>Sorts by the size of the file (how much disk space it takes up). Sorts from smallest to largest by default.</p>
  </item>
  <item>
   <title>By Type</title>
   <p>Sorts alphabetically by the file type. Files of the same type are grouped together, then sorted by name.</p>
  </item>
  <item>
   <title>By Modification Date</title>
   <p>Sorts by the date and time that a file was last changed. Sorts from oldest to newest by default.</p>
  </item>
 </terms>
</section>

</page>
