summaryrefslogtreecommitdiffstats
path: root/gnome2-system-admin-guide/C/mimetypes.xml
diff options
context:
space:
mode:
Diffstat (limited to 'gnome2-system-admin-guide/C/mimetypes.xml')
-rw-r--r--gnome2-system-admin-guide/C/mimetypes.xml292
1 files changed, 146 insertions, 146 deletions
diff --git a/gnome2-system-admin-guide/C/mimetypes.xml b/gnome2-system-admin-guide/C/mimetypes.xml
index ac3ff2f..759a681 100644
--- a/gnome2-system-admin-guide/C/mimetypes.xml
+++ b/gnome2-system-admin-guide/C/mimetypes.xml
@@ -1,12 +1,11 @@
-<?xml version="1.0" encoding="utf-8"?>
<chapter id="mimetypes-0">
<title>MIME Types</title>
<highlights>
<para>This chapter describes how applications detect MIME types,
-how to register MIME types, and how to add applications to the GNOME desktop.</para>
+how to register MIME types, and how to add applications to the desktop environment.</para>
</highlights>
<sect1 id="mimetypes-1">
- <title>Introduction</title>
+ <title>Introduction to MIME Types</title>
<indexterm>
<primary>MIME types</primary>
<secondary>introduction</secondary>
@@ -17,9 +16,9 @@ to read the file. Applications such as Internet browsers and email applications
use the MIME type to handle files of different types. For example, an email
application can use the MIME type to detect what type of file is in a file
attached to an email.</para>
- <para>In the GNOME desktop, the <application>Nautilus</application> file manager
-uses MIME types to identify the type of a file. The file manager needs to
-know the MIME type of a file to perform the following tasks:</para>
+ <para>The <application>Nautilus</application> file manager uses MIME types
+to identify the type of a file. The file manager needs to know the MIME type
+of a file to perform the following tasks:</para>
<itemizedlist>
<listitem>
<para>Open the file in an appropriate application.</para>
@@ -51,7 +50,8 @@ the procedure that you must follow to add a new application.</para>
<indexterm>
<primary>detecting MIME types</primary>
</indexterm>
- <para>Applications can detect the MIME type of a file as follows:</para>
+ <para>Applications
+can detect the MIME type of a file as follows:</para>
<orderedlist>
<listitem>
<para>The application uses <firstterm>file content sniffers</firstterm>
@@ -162,141 +162,141 @@ this entry.</para>
</tbody>
</tgroup>
</table>
- <sect3 id="mimetypes-12">
- <title>Pattern Masks</title>
- <indexterm>
- <primary>MIME types</primary>
- <secondary>pattern mask</secondary>
- </indexterm>
- <indexterm>
- <primary>pattern mask</primary>
- </indexterm>
- <para>A
+ </sect2>
+ <sect2 id="mimetypes-12">
+ <title>Pattern Masks</title>
+ <indexterm>
+ <primary>MIME types</primary>
+ <secondary>pattern mask</secondary>
+ </indexterm>
+ <indexterm>
+ <primary>pattern mask</primary>
+ </indexterm>
+ <para>A
pattern mask identifies bits in the pattern to ignore when searching for a
pattern in a file. The following is an example of a file content sniffer with
a pattern mask:</para>
- <literallayout>0 string BMxxxx\000\000 &amp;0xffff00000000ffff image/bmp</literallayout>
- <para>The pattern and mask in the example are as follows:</para>
- <informaltable frame="none">
- <tgroup cols="9" colsep="0" rowsep="0">
- <colspec colwidth="16.54*"/>
- <colspec colwidth="10.21*"/>
- <colspec colwidth="10.41*"/>
- <colspec colwidth="10.21*"/>
- <colspec colwidth="10.41*"/>
- <colspec colwidth="10.21*"/>
- <colspec colwidth="10.41*"/>
- <colspec colwidth="10.21*"/>
- <colspec colwidth="10.41*"/>
- <tbody>
- <row>
- <entry valign="top">
- <para>Pattern</para>
- </entry>
- <entry valign="top">
- <para>
- <literal>B</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>M</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>x</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>x</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>x</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>x</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>\000</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>\000</literal>
- </para>
- </entry>
- </row>
- <row>
- <entry valign="top">
- <para>Mask</para>
- </entry>
- <entry valign="top">
- <para>
- <literal>ff</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>ff</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>00</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>00</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>00</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>00</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>ff</literal>
- </para>
- </entry>
- <entry valign="top">
- <para>
- <literal>ff</literal>
- </para>
- </entry>
- </row>
- </tbody>
- </tgroup>
- </informaltable>
- <para>The pattern and mask specify a file with the following characteristics:</para>
- <orderedlist>
- <listitem>
- <para>The file begins with <literal>BM</literal>.</para>
- </listitem>
- <listitem>
- <para><literal>BM</literal> is followed by four bytes with any values.</para>
- </listitem>
- <listitem>
- <para>The four bytes are followed by <literal>\000\000</literal>.</para>
- </listitem>
- </orderedlist>
- <para>The file content sniffer specifies that the MIME type of files that
+ <literallayout>0 string BMxxxx\000\000 &amp;0xffff00000000ffff image/bmp</literallayout>
+ <para>The pattern and mask in the example are as follows:</para>
+ <informaltable frame="none">
+ <tgroup cols="9" colsep="0" rowsep="0">
+ <colspec colwidth="16.54*"/>
+ <colspec colwidth="10.21*"/>
+ <colspec colwidth="10.41*"/>
+ <colspec colwidth="10.21*"/>
+ <colspec colwidth="10.41*"/>
+ <colspec colwidth="10.21*"/>
+ <colspec colwidth="10.41*"/>
+ <colspec colwidth="10.21*"/>
+ <colspec colwidth="10.41*"/>
+ <tbody>
+ <row>
+ <entry valign="top">
+ <para>Pattern</para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>B</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>M</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>x</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>x</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>x</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>x</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>\000</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>\000</literal>
+ </para>
+ </entry>
+ </row>
+ <row>
+ <entry valign="top">
+ <para>Mask</para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>ff</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>ff</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>00</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>00</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>00</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>00</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>ff</literal>
+ </para>
+ </entry>
+ <entry valign="top">
+ <para>
+ <literal>ff</literal>
+ </para>
+ </entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </informaltable>
+ <para>The pattern and mask specify a file with the following characteristics:</para>
+ <orderedlist>
+ <listitem>
+ <para>The file begins with <literal>BM</literal>.</para>
+ </listitem>
+ <listitem>
+ <para><literal>BM</literal> is followed by four bytes with any values.</para>
+ </listitem>
+ <listitem>
+ <para>The four bytes are followed by <literal>\000\000</literal>.</para>
+ </listitem>
+ </orderedlist>
+ <para>The file content sniffer specifies that the MIME type of files that
match the pattern and mask is <literal>image/bmp</literal>.</para>
- </sect3>
</sect2>
<sect2 id="mimetypes-4">
<title>MIME Type Registry</title>
@@ -368,9 +368,9 @@ is the MIME type of the file.</para>
<para>In MIME information files, the filename pattern to search for is written
as a regular expression.</para>
<para>The format of MIME type entries in MIME information files is as follows:</para>
- <literallayout><replaceable>MIME_type</replaceable>
- ext[,priority]: <replaceable>list_of_extensions</replaceable>
- regex[,priority]: <replaceable>list_of_regular_expressions</replaceable></literallayout>
+ <literallayout><replaceable>MIME-type</replaceable>
+ ext[,priority]: <replaceable>list-of-extensions</replaceable>
+ regex[,priority]: <replaceable>list-of-regular-expressions</replaceable></literallayout>
<para>You can specify a priority value for the filename extension and the
regular expression. You can use the priority value to differentiate composite
filenames. For example, you can assign a priority of <literal>1</literal>
@@ -670,7 +670,7 @@ use.</para>
</table>
</sect1>
<sect1 id="mimetypes-9">
- <title>Adding an Application to the GNOME Desktop</title>
+ <title>Adding an Application to the Desktop Environment</title>
<indexterm>
<primary>MIME types</primary>
<secondary>adding applications</secondary>
@@ -679,15 +679,15 @@ use.</para>
<primary>applications</primary>
<secondary>adding</secondary>
</indexterm>
- <para>To add an application to the GNOME desktop, perform the
-following steps:</para>
+ <para>To add an application to the desktop environment, perform
+the following steps:</para>
<orderedlist>
<listitem>
<para>Add a menu item for the application. For more information
on how to add an item to a menu, see <xref linkend="menustructure-0"/>.</para>
</listitem>
<listitem>
- <para>Add an icon for the application to <filename>/usr/gnome/share/icons/<replaceable>theme_name</replaceable>/<replaceable>icon_size</replaceable>/apps</filename>.
+ <para>Add an icon for the application to <filename>/usr/gnome/share/icons/<replaceable>theme-name</replaceable>/<replaceable>icon-size</replaceable>/apps</filename>.
For more information on icons and themes, see <citetitle>Installing Themes</citetitle>. </para>
</listitem>
<listitem>
@@ -706,7 +706,7 @@ registry. For more information on MIME keys files, see <xref linkend="mimetypes-
</listitem>
<listitem>
<para>If the application uses a new MIME type, add an icon for the
-MIME type to <filename>/usr/gnome/share/icons/<replaceable>theme_name</replaceable>/<replaceable>icon_size</replaceable>/mimetypes</filename>. For more information on icons
+MIME type to <filename>/usr/gnome/share/icons/<replaceable>theme-name</replaceable>/<replaceable>icon-size</replaceable>/mimetypes</filename>. For more information on icons
and themes, see <citetitle>Installing Themes</citetitle>. </para>
</listitem>
<listitem>