<sect1 id="sect-files-openimport">
  <title>Opening and Importing Files</title>
    
  <para>
    There are several ways to open an existing file to be used in
    <application>Gnumeric</application>. Usually, a given file can be
    opened in <application>Gnumeric</application> if
    <application>Gnumeric</application> also allows the file to be
    saved in the same format. Other file formats may be imported into
    <application>Gnumeric</application> (see <xref
    linkend="file-format" /> for a list of supported formats).
  </para>



  <sect2 id="sect-files-opening">
    <title>Opening Files</title>
    <para>The Open File Dialog can be invoked several ways. It is
      available in the Menubar from the 
      <guimenu><accel>F</accel>ile</guimenu>/
      <guimenuitem><accel>O</accel>pen..</guimenuitem> menuitem
	 (see <xref linkend="File-Menu" />). There
      is also a toolbar <guibutton>Open</guibutton> (see <xref
      linkend="std-toolbar" />).  All these methods are equivalent.
    </para>

      <variablelist>
	<title>Opening a file</title>
      <varlistentry>
	  <term>Menubar</term>
	  <listitem>
	    <para> 
	      <guimenu><accel>F</accel>ile</guimenu>/
	      <guimenuitem><accel>O</accel>pen..</guimenuitem>
	    </para>
	  </listitem>
	</varlistentry>
	<varlistentry>
	  <term>
	    Standard Toolbar
	  </term>
	  <listitem>
	    <para>
	      <guiicon>
		<inlinemediaobject>
            <imageobject>
              <imagedata fileref="figures/button-open.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the open file button.</phrase>
            </textobject>
           </inlinemediaobject>
		Open
	      </guiicon>
	    </para>
	  </listitem>
	</varlistentry>
	<varlistentry>
	  <term>
	    Keyboard Shortcut
	  </term>
	  <listitem>
	    <para>
		<keysym>F3</keysym>
	    </para>
	  </listitem>
	</varlistentry>
      </variablelist>
  </sect2>




  <sect2 id="sect-files-importing">
    <title>Importing Files</title>
    <para>The Import File Dialog can be invoked in the Menubar from the 
      <guimenu><accel>F</accel>ile</guimenu>/
      <guimenuitem><accel>I</accel>mport..</guimenuitem> menuitem
	 (see <xref linkend="File-Menu" />). 
    </para>
    
      <variablelist>
	<title>Importing a file</title>
	<varlistentry>
	  <term>Menubar</term>
	  <listitem>
	    <para> 
	      <guimenu><accel>F</accel>ile</guimenu>/
	      <guimenuitem>S<accel>a</accel>ve as...</guimenuitem>
	    </para>
	  </listitem>
	</varlistentry>
      </variablelist>
  </sect2>




  <sect2 id="file-format">
    <title>File Formats</title>

    <para> In the <guimenuitem>Save as..</guimenuitem> dialog you can choose between
    various file formats. (see <xref linkend="fileformatdialog" />)</para>
    <figure  id="fileformatdialog">
    <title>File Format Selector</title>
    <screenshot id="fileformatdialog-shot">
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-formats-list.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the list of supported file types.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
    </figure>
    <para> Similarly, in the <guimenuitem>Import..</guimenuitem> dialog you can also choose between
    various file formats. (see <xref linkend="fileformatimportdialog" />)</para>
    <figure  id="fileformatimportdialog">
    <title>File Format Selector</title>
    <screenshot id="fileformatimportdialog-shot">
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/file-formats-import-list.png" 
                  format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the supported importing file formats.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
    </figure>

  <para>
    Most of these formats are provided by plug-ins. If they don't
    appear on your list of available plug-ins use the
    <guimenuitem>Tools Plug-ins...</guimenuitem> menu item to verify
    that the appropriate plug-in has been loaded.</para>
    
  <sect3 id="file-format-default">
  <title><application>Gnumeric</application> XML File Format</title>
    <para>The default file format and <application>Gnumeric</application>'s 
      native format is an xml
      based file.  The file format is a ascii text based xml
      format. It is however, typically written and read in a gzip
      compressed form.
    </para>
    <para>The uncompressed format is human readable and designed to be
      easily parsed. It is very extensible.
    </para>
  </sect3>


    <sect3 id="file-format-dif">
      <title>Data Interchange Format</title>

      <para>
        This format is supported by the <quote>Data Interchange Format
        (DIF) module</quote> plug-in.
      </para>

      <note>
        <para>
          This format is available when saving or importing files.
        </para>
      </note>
    </sect3>


  <sect3 id="file-format-dvi">
  <title>DVI TeX Format</title>
  <para>This format is supported by the <quote>HTML &amp; TeX</quote> plug-in.</para>
  <note><para>This format is only available when saving files.</para></note>
  <para>Creation of a dvi file with <application>Gnumeric</application> requires 
  that <command>groff</command> has 
  been installed. If a complete TeX installation is available it is probably advisable 
  to use the <application>LaTeX</application> format 
  (<xref linkend="file-format-latex" />) instead, since the
  created <application>LaTeX</application> file can be extensively customized 
  before creating the dvi file from it.</para>

   <figure id="file-format-dvi-ex1">
    <title><application>Gnumeric</application> Sample Screenshot</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-xml-example.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of currency data in Gnumeric .</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>
<example id="file-format-dvi-example">
  <title>Saving as DVI TeX</title>

  <para>
   The screenshot <xref linkend="file-format-dvi-ex1" /> shows an
   example <application>Gnumeric</application> file. If we save this
   file in DVI TeX format and open it using <command>xdvi</command> we
   obtain <xref linkend="file-format-dvi-ex2" />.
     </para>
 </example>
  <figure id="file-format-dvi-ex2">
    <title><command>xdvi</command> Screenshot of DVI TeX File</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-dvi-example.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of DVI ouput from
              <application>Gnumeric</application>.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>
  </sect3>

  <sect3 id="file-format-xl">
  <title>MS Excel (tm) File Formats</title>
  <para>This format is supported by the <quote>MS Excel (tm) File Formats</quote> 
  plug-in.</para>
  <para><application>Gnumeric</application> can open files from most recent 
  versions of MS Excel (tm). It can 
  also save files in MS Excel (tm) 95 format.</para>
  </sect3>

  <sect3 id="file-format-efs">
  <title>Experimental Bonobo EFS Format</title>
  <para>This format is supported by the <quote>EXPERIMENTAL SAX based XML</quote> 
  plug-in.</para>
  <note><para>This format is available when importing or saving files.</para></note>
  </sect3>

  <sect3 id="file-format-po">
  <title>Gnome Glossary PO File Format</title>
  <para>This format is supported by the <quote>Gnome Glossary</quote> plug-in.</para>
  <note><para>This format is only available when saving files.</para></note>
  </sect3>

  <sect3 id="file-format-html">
  <title>HTML File Formats</title>
  <para>These formats are supported by the <quote>HTML &amp; TeX</quote> plug-in.</para>
  <sect4 id="file-format-html-gnumeric">
  <title>HTML generated by <application>Gnumeric</application></title>
  <note><para>This format is only available when importing or opening files.</para></note>
  <para>Very simple and well structured HTML tables can be opened by 
  <application>Gnumeric</application> into an appropriate 
  spreadsheet. In this process, <application>Gnumeric</application> will lose information 
  on merged cells and most other 
  formatting, but the main cell values should be preserved.</para>
  </sect4>
  <sect4 id="file-format-html32">
  <title>HTML 3.2 File Format</title>
  <note><para>This format is only available when saving files.</para></note>
  <para><application>Gnumeric</application> can create HTML 3.2 files. All sheets of the 
  current workbook are exported. 
  The tables in the HTML 3.2 file contain all cells, whether visible or not, including merged
  cells and spans. Horizontal as well as vertical alignment is preserved, as are font colors 
  and some font characteristics (italic, bold). These files also include an appropriate 
  preamble.</para>
  <example id="file-format-html32-example">
  <title>Saving as HTML 3.2</title>
     <para>The screenshot <xref linkend="file-format-dvi-ex1" /> shows an example 
     <application>Gnumeric</application> file. If we save this file in HTML 3.2 
     format and open it using 
     <application>Mozilla 0.95</application> we obtain <xref
     linkend="file-format-html32-ex1" />.
     </para>
  </example>
  <figure id="file-format-html32-ex1">
    <title><application>Mozilla</application> Screenshot of HTML 3.2 File</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-html32-example.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of html output.</phrase>
            </textobject>
           </mediaobject>

    </screenshot>
  </figure>
  </sect4>
  <sect4 id="file-format-html40">
  <title>HTML 4.0 File Format</title>

  <note><para>This format is only available when saving files.</para></note>

  <para>
    <application>Gnumeric</application> can create HTML 4.0 files. All
    sheets of the current workbook are exported.  The tables in the
    HTML 4.0 file contain all cells, whether visible or not, including
    merged cells and spans. Horizontal as well as vertical alignment
    is preserved, as are some font characteristics (italic, bold) and
    cell background colors. These files also include an appropriate
    preamble.</para>
  
  <example id="file-format-html40-example">
    <title>Saving as HTML 4.0</title>
      <para>
        The screenshot <xref linkend="file-format-dvi-ex1" /> shows an
        example <application>Gnumeric</application> file. If we save
        this file in HTML 4.0 format and open it using
        <application>Mozilla 0.95</application> we obtain <xref
        linkend="file-format-html40-ex1" />.
     </para>
  </example>

  <figure id="file-format-html40-ex1">
    <title><application>Mozilla</application> Screenshot of HTML 4.0 File</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-html40-example.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the html4.0 export format.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>
  </sect4>
  <sect4 id="file-format-html40f">
  <title>HTML Fragment Format</title>

  <note>
    <para>This format is only available when saving files.
    </para>
  </note>

  <para>
    <application>Gnumeric</application> can create HTML fragments. All
    sheets of the current workbook are exported.  The tables in such a
    fragment file contain all cells, whether visible or not, including
    merged cells and spans. Horizontal as well as vertical alignment
    is preserved, as are some font characteristics (italic, bold) as
    well as cell background and font colors. These files do
    <emphasis>not</emphasis> contain any preamble. Note that each tag
    used in these files is valid in some HTML version, the combination
    of these tags in a <application>Gnumeric</application> generated
    HTML fragment may not be. </para>
  <example id="file-format-html-example">
  <title>Saving as HTML fragment</title>

     <para>
       The screenshot <xref linkend="file-format-dvi-ex1" /> shows an
       example <application>Gnumeric</application> file. If we save
       this file as an HTML fragment and open it using
       <application>Mozilla 0.95</application> we obtain <xref
       linkend="file-format-html-ex1" />.
     </para>
  </example>
  <figure id="file-format-html-ex1">
    <title><application>Mozilla</application> Screenshot of HTML Fragment</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata  fileref="figures/files-html-example.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of an html table.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>
  </sect4>
  </sect3>

  <sect3 id="file-format-latex">
  <title><application>LaTeX</application> 2e Format</title> <para>This
  format is supported by the <quote>HTML &amp; TeX</quote>
  plug-in.</para> <note><para>This format is only available when
  saving files.</para></note> <para>Only the top sheet of the current
  workbook is exported.</para> <para>The created
  <application>LaTeX</application> file can either be input into
  another <application>LaTeX</application> file (see <xref
  linkend="file-format-latex-inclusion" />) or
  <command>latex</command>ed independently. See the content and <xref
  linkend="file-format-latex-customization" /> of the created file for
  various customization options. </para>
  <example id="file-format-latex-example">

  <title>Saving as <application>LaTeX</application> file</title>
     <para>The screenshot <xref linkend="file-format-dvi-ex1" /> shows an example 
     <application>Gnumeric</application> file. If we save this file as 
     <application>LaTeX</application> file, <command>tex</command> it using 
     <command>pdflatex</command> and open it using 
     <command>xpdf</command> we obtain <xref
     linkend="file-format-latex-ex1" />.
     </para>
  </example>
  <figure id="file-format-latex-ex1">
    <title><command>xpdf</command> Screenshot of <application>LaTeX</application> file</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-latex-example.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of a table rendered in LaTeX.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>

  <sect4 id="file-format-latex-inclusion">
  <title>Including Tables Into Other Documents</title>
  <para>
	To include an exported <application>Gnumeric</application> table into 
	another <application>LaTeX</application> document you need to
	use several packages</para>
      <screen>
        \usepackage{color}
        \usepackage{array}
        \usepackage{longtable}
        \usepackage{calc}
        \usepackage{multirow}
        \usepackage{hhline}
        \usepackage{ifthen}  
      </screen>
      <para>
	and to add the following lines to the preamble of your
	document:
      </para>
      <screen>
        \newlength{\gnumericTableWidth}
        \newlength{\gnumericTableWidthComplete}
  </screen>
  <para>When you have set up your main document in this way, include each table with:</para>
  <screen>
        \input{<replaceable>mygnumericfile.tex</replaceable>}  
  </screen>
  </sect4>
  <sect4 id="file-format-latex-customization">
  <title>Customizing The <application>LaTeX</application> Tables</title>
  <para>To switch from portrait to landscape for independently <command>latex</command>ed tables,
  uncomment the line:</para>
  <screen>
	                  %,landscape%
  </screen>
  <para>to obtain</para>
  <screen>
	\documentclass[12pt%
	                  ,landscape%
                    ]{report}
  </screen>
  <para>To change the column widths, look for the following section in the <application>LaTeX</application> file:</para>
  <screen>
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                                                  %%
%% The following are the widths of the various columns. We are      %%
%% defining them here because then they are easier to change.       %%
%% Depending on the cell formats we may use them more than once.    %%
%%                                                                  %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\def\gnumericColA{107pt*\gnumericScale}
\def\gnumericColB{89pt*\gnumericScale}
\def\gnumericColC{98pt*\gnumericScale}
\def\gnumericColD{89pt*\gnumericScale}
\def\gnumericColE{89pt*\gnumericScale}
  </screen>  
  <para>To change the second column (Column B) to a width of 0.75 inches, we would simply have to
  modify this code to:</para>
  <screen>
\def\gnumericColA{107pt*\gnumericScale}
\def\gnumericColB{0.75in}
\def\gnumericColC{98pt*\gnumericScale}
\def\gnumericColD{89pt*\gnumericScale}
\def\gnumericColE{89pt*\gnumericScale}
  </screen>  
  </sect4>
  </sect3>

  <sect3 id="file-format-mps">
  <title>Linear and Integer Program File Format</title>
  <para>This format is supported by the <quote>Linear and integer expression (MPS) format
  module</quote> plug-in.</para>
  <note><para>This format is only available when importing files.</para></note>
  </sect3>

  <sect3 id="file-format-planperfect">
  <title>Plan Perfect Format</title>
  <para>This format is supported by the <quote>Plan Perfect</quote> plug-in.</para>
  <note><para>This format is only available when importing files.</para></note>
  </sect3>

  <sect3 id="file-format-pdf">
  <title>PDF Format</title>
  <para>Currently, <application>Gnumeric</application> cannot save directly as a PDF file; 
  but, provided a standard 
  <command>tetex</command> installation is available, the <application>Gnumeric</application> 
  file can be saved as a 
  <application>LaTeX</application> file (see <xref
  linkend="file-format-latex" />), and 
  turned into a PDF file using 
  <command>pdflatex</command>.</para>
  <para> See <xref linkend="file-format-latex-ex1" /> for an example of a created PDF file.</para>
  </sect3>

  <sect3 id="file-format-sc">
  <title>SC/XSpread Format</title>
  <para>This format is supported by the <quote>SC/XSpread Format</quote> plug-in.</para>
  <note><para>This format is only available when importing files.</para></note>
  </sect3>

  <sect3 id="file-format-csv">
  <title>Text Format</title>
  <para>This format exports <application>Gnumeric</application> spreadsheets as straight 
  text or imports them 
  from straight text files. Both export (save as) as well as import can be highly customized.
  </para>
  <sect4 id="file-format-csv-export">
  <title>The Text Export Druid</title>
  <para>After specifying the <quote><guilabel>Text File Export</guilabel></quote> 
  Format and a file name in the 
  <quote><guilabel>Save as..</guilabel></quote> dialog, the text export 
  druid starts to guide you through the various options:</para>
  <orderedlist>
  <listitem>
  <para>Specify which sheets to export.</para>
  <figure id="file-format-csv-export-ex1">
    <title>Specifying which sheets to export</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-csv-export-ex1.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the first page of the text export
              druid.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>  
  </listitem>
  <listitem>

  <para>
    Choose the line terminator to use. You should select it based on
    the platform you want the created file to be used on. Choose one
    of several field separators and whether to quote all fields or
    only as needed. The defaults create the standard Unix
    <keycap>csv</keycap> format.
  </para>

  <figure id="file-format-csv-export-ex2">
    <title>Specifying line terminators</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-csv-export-ex2.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the second page of the text export druid.</phrase>
            </textobject>
           </mediaobject>

    </screenshot>
  </figure>  
  </listitem>

  <listitem>
    <para>
      Select <quote><guibutton>Finish</guibutton></quote> to finally
      export the selected sheets and create the text file. The
      standard <keycap>csv</keycap> output of <xref
      linkend="file-format-dvi-ex1" /> is shown in <xref
      linkend="file-format-csv-export-ex3" />.
    </para>
    <figure id="file-format-csv-export-ex3">
      <title><keycap>csv</keycap> File</title>
      <screen>
,"Operating System",,,
,DOS,Linux,SCO,
January,"$1000.00 ","$900.00 ","$500.00 ",
February,"$900.00 ","$2500.00 ","$300.00 ",
March,"$800.00 ","$4100.00 ","$100.00 ",
April,"$700.00 ","$5700.00 ",($100.00),
May,"$600.00 ","$7300.00 ",($300.00),
June,"$500.00 ","$8900.00 ",($500.00),
July,"$400.00 ","$10500.00 ",($700.00),
August,"$300.00 ","$12100.00 ",($900.00),
September,"$200.00 ","$13700.00 ",($1100.00),
October,"$100.00 ","$15300.00 ",($1300.00),
November,"$0.00 ","$16900.00 ",($1500.00),
December,($100.00),"$18500.00 ",($1700.00),
,,,,
Totals:,"$5400.00 ","$116400.00 ",($7200.00),
,,,,
    </screen>
  </figure>
  </listitem>
</orderedlist>
  </sect4>


  <sect4 id="file-format-csv-import">
  <title>The Text Import Druid</title>

  <para>
    After specifying the <quote><guilabel>Text File
    Import</guilabel></quote> Format and a file name in the
    <quote><guilabel>Import..</guilabel></quote> dialog, the text
    import druid starts to guide you through the various
    options.</para> <para>On the first screen of the druid specify the
    basic format type (fixed width fields or fields separated by
    specific characters), as well as the line numbers of the lines to
    import.</para>
  <figure id="file-format-csv-import-ex1">
    <title>Selecting the basic format type</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-csv-import-ex1.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the first page of the text import
              druid.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>  
  <sect5>
  <title>The Text Import Druid for Separated Fields</title>
  <orderedlist>
  <listitem>
  <figure id="file-format-csv-import-ex2">
    <title>Separation Customization</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-csv-import-ex2.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the second page of the text import
              druid.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>  
  <para>Select the appropriate field separator(s) in the 
  <quote><guilabel>Separator</guilabel></quote> frame. Select the 
  <quote><guilabel>See two separators as one</guilabel></quote>option if any sequence of 
  separators are supposed to be considered a single separator. The 
  <quote><guilabel>Example</guilabel></quote> frame gives immediate feedback on your choices:</para>
  <figure id="file-format-csv-import-ex3">
    <title>Separation Customization With Correct Selection</title>
    <screenshot>
	<mediaobject>
           <imageobject>
             <imagedata fileref="figures/files-csv-import-ex3.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the second page of the text import
              druid with the comma separator seleced.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>  
  </listitem>
  <listitem>
  <para>Finally select the appropriate format for each input column:</para>
  <figure id="file-format-csv-import-ex4">
    <title>Selecting Formats</title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-csv-import-ex4.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the third page of the text import
              druid.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>  
<para>After selecting a column on the left select the appropriate format on the right. In the preview section at the bottom of the dialog, you can immediately see the effect of selecting that format. The following types of formats are available:</para>
  <variablelist>
    <varlistentry>
      <term>
      General
      </term>
      <listitem>
      <para>This format will guess for each field value whether it is text, 
      a number, a date, etc.</para>
      </listitem>
    </varlistentry>
    <varlistentry>
      <term>
      Numbers
      </term>
      <listitem>
      <para>You can choose between various number formats. The following list presents 
      just a short selection of those formats:</para>
  <figure id="file-format-numberformats">
    <title>Some Number Formats</title>
    <screen>
0
0.00
#,##0
#,##0_);(#,##0)
#,##0.00_);[Red](#,##0.00)
    </screen>
  </figure>
  <para>There are also formats facilitating the use of scientific notation, 
  see <xref linkend="file-format-scientificformats" />.</para>
      </listitem>
    </varlistentry>
    <varlistentry>
      <term>
      Currency Amounts
      </term>
      <listitem>
     <para> You can choose between various currency formats. The following list presents 
     just a short selection of those formats:</para>
  <figure id="file-format-currenyformats">
    <title>Some Currency Formats</title>
    <screen>
"$"#,##0
"$"#,##0_);(#,##0)
"$"#,##0.00_);[Red](#,##0.00)
    </screen>
  </figure>
      </listitem>
    </varlistentry>
    <varlistentry>
      <term>
      Dates and Times
      </term>
      <listitem>
      <para>You can choose between various date and time formats. Some of these formats will 
      recognize combined date/time entries. The following list presents just a short 
      selection of those formats:</para>
  <figure id="file-format-dateformats">
    <title>Some Date and Time Formats</title>
    <screen>
m/d/yy
d-mmm-yyyy
d-mm
mmm/d
mmm/ddd/yyyy
mmmm-yyyy
m/d/yyyy h:mm
yyyy
h:mm:ss AM/PM
[h]:mm:ss
    </screen>
  </figure>
      </listitem>
    </varlistentry>
    <varlistentry>
      <term>
      Percentages
      </term>
      <listitem>
      <para>You can choose between various formats that recognize percentages. 
      The following list presents just a short 
      selection of those formats:</para>
  <figure id="file-format-percentageformats">
    <title>Some Percentage Formats</title>
    <screen>
0%
0.00%
    </screen>
  </figure>
      </listitem>
    </varlistentry>
    <varlistentry>
      <term>
      Fractions
      </term>
      <listitem>
      <para>You can choose between a few formats that recognize fractions. 
      The following list presents just a short 
      selection of those formats:</para>
  <figure id="file-format-fractionformats">
    <title>Some Fraction Formats</title>
    <screen>
# ?/?
# ??/??
    </screen>
  </figure>
      </listitem>
    </varlistentry>
    <varlistentry>
      <term>
      Scientific Notation
      </term>
      <listitem>
      <para>You can choose between a few formats that recognize numbers in scientific notation.. 
      The following list presents just a short 
      selection of those formats:</para>
  <figure id="file-format-scientificformats">
    <title>Some Scientific Formats</title>
    <screen>
0.00E+00
##0.0E+0
    </screen>
  </figure>
      </listitem>
    </varlistentry>
    <varlistentry>
      <term>
      Text
      </term>
      <listitem>
      <para>If you want the importer to simply read the field value as text without 
      attempting to interpret it in any way, use the following text format:</para>
  <figure id="file-format-textformat">
    <title>The Text Format</title>
    <screen>
@
    </screen>
  </figure>
      </listitem>
    </varlistentry>
  </variablelist>
  <para>More details on the various formats can be found in 
    <xref linkend="file-format" />.</para>
  </listitem>
  <listitem><para>
  Click the <quote><guibutton>Finish</guibutton></quote> button 
  to complete importing the file.</para>
  </listitem>
  </orderedlist>
  </sect5>
  <sect5>
  <title>The Text Import Druid for Fixed Width Fields</title>
  <orderedlist>
  <listitem>
  <para>If you selected fixed width fields you are asked to specify the widths for
  each field. Click the <quote><guibutton>Auto Column Discovery</guibutton></quote> button
  to have <application>Gnumeric</application> try to determine the fields widths automatically.</para>
  <figure id="file-format-csv-import-ex5">
    <title></title>
    <screenshot>
	<mediaobject>
            <imageobject>
              <imagedata fileref="figures/files-csv-import-ex5.png" format="PNG" />
            </imageobject>
            <textobject>
              <phrase>An image of the third page of the text import
              druid with fixed width customization.</phrase>
            </textobject>
           </mediaobject>
    </screenshot>
  </figure>  
  </listitem>
  <listitem>
  <para>Finally select the appropriate format for each input column as in 
  <xref linkend="file-format-csv-import-ex4" />.</para>
  </listitem>
  <listitem><para>
  Click the <quote><guibutton>Finish</guibutton></quote> button 
  to complete importing the file.</para>
  </listitem>
  </orderedlist>
  </sect5>
  </sect4>
  </sect3>

  <sect3 id="file-format-troff">
  <title><command>TROFF</command> Format</title>
  <para>This format is supported by the <quote>HTML &amp; TeX</quote> plug-in.</para>
  <note><para>This format is only available when saving files.</para></note>
  <para>Files in this format are useful because they can be converted with the 
  <command>groff</command> or <command>troff</command> commands 
  into various other common formats. For example, given a <command>TROFF</command> file 
  <replaceable>myfile.me</replaceable>, the command</para>
  <screen>
  groff -me -t -Tps <replaceable>myfile.me</replaceable> ><replaceable>myfile.ps</replaceable>
  </screen>
  <para>will create a postscript file of the corresponding table.</para>
  <para>Similarly, the command</para>
  <screen>
groff -me -t -Tascii <replaceable>myfile.me</replaceable> ><replaceable>myfile.ascii</replaceable>
  </screen>
  <para>creates an <keycap>ascii</keycap> (straight text) file.</para>
  <example>
  <title>Creating an <keycap>ASCII</keycap> File</title>
  <para>If we save <xref linkend="file-format-dvi-ex1" /> as a <command>troff</command> file 
  <replaceable>hypothetical-sales.me</replaceable> and then execute the command</para>
  <screen>
groff -me -t -Tascii <replaceable>hypothetical-sales.me</replaceable> ><replaceable>hypothetical-sales.ascii</replaceable>
  </screen>
  <para>then the file <replaceable>hypothetical-sales.ascii</replaceable> contains:</para>
  <screen>







Sheet 0


+----------+------------------+-------------+------------+---+
|          | Operating System |             |            |   |
+----------+------------------+-------------+------------+---+
|          |       DOS        |    Linux    |    SCO     |   |
+----------+------------------+-------------+------------+---+
|  January | $1000.00         | $900.00     | $500.00    |   |
+----------+------------------+-------------+------------+---+
| February | $900.00          | $2500.00    | $300.00    |   |
+----------+------------------+-------------+------------+---+
|    March | $800.00          | $4100.00    | $100.00    |   |
+----------+------------------+-------------+------------+---+
|    April | $700.00          | $5700.00    | ($100.00)  |   |
+----------+------------------+-------------+------------+---+
|      May | $600.00          | $7300.00    | ($300.00)  |   |
+----------+------------------+-------------+------------+---+
|     June | $500.00          | $8900.00    | ($500.00)  |   |
+----------+------------------+-------------+------------+---+
|     July | $400.00          | $10500.00   | ($700.00)  |   |
+----------+------------------+-------------+------------+---+
|   August | $300.00          | $12100.00   | ($900.00)  |   |
+----------+------------------+-------------+------------+---+
|September | $200.00          | $13700.00   | ($1100.00) |   |
+----------+------------------+-------------+------------+---+
|  October | $100.00          | $15300.00   | ($1300.00) |   |
+----------+------------------+-------------+------------+---+
| November | $0.00            | $16900.00   | ($1500.00) |   |
+----------+------------------+-------------+------------+---+
| December | ($100.00)        | $18500.00   | ($1700.00) |   |
+----------+------------------+-------------+------------+---+
|          |                  |             |            |   |
+----------+------------------+-------------+------------+---+
|  Totals: | $5400.00         | $116400.00  | ($7200.00) |   |
+----------+------------------+-------------+------------+---+
|          |                  |             |            |   |
+----------+------------------+-------------+------------+---+

















                              1



      </screen>
      </example>
    </sect3>
  </sect2><!-- File Formats -->


</sect1>

       
